Re:Haxe: Cross-Platform Development's Best-Kept Secret
by cojo on Thursday June 07, 2018 @11:19AM
(#17256557)
We used Haxe for a while at my last company for a cross-platform engine that would actually run well on web (browsers couldn't yet handle "real" Unity WebGL builds at that time).
While it "worked" and the resulting engine / suite of games ended up net profitable, and I'm a fan of Haxe's features as a language (I am really missing the pattern matching and macros in Typescript these days), I must say the build pipeline and available tools for OpenFL / Haxe games was lacking at best.
On the plus side being able to fork and fix issues we ran into was a game changer over Unity IMO.
Not sure if the ecosystem has evolved / improved on the build and tooling fronts in the last 18 months since I last interacted with it directly, but that would be the one word of caution I'd offer to anyone after they read this article. Be prepared to roll up your sleeves and get a little dirtier than usual if you really intend to ship on both web and mobile.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by larsiusprime on Thursday June 07, 2018 @11:38AM
(#17256781)
OpenFL's matured a bit since then and I quite like it personally, though I should point out that OpenFL is simply one of many libraries, and the rest are worth checking out, too! OpenFL's probably the most well known but the ecosystem has a lot to offer beyond that.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by kevin_bloch on Thursday June 07, 2018 @11:37AM
(#17256763)
Not sure of the specifics in the last 18 months on straight OpenFL, but I know that some frameworks built on top of it had nice features like hot reloading. HaxeFlixel has an in-game debugger, too, for example. I guess it depends on the types of tooling you had in mind.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by pier25 on Thursday June 07, 2018 @12:28PM
(#17257362)
> I must say the build pipeline and available tools for OpenFL / Haxe games was lacking at best
That was my experience as well.
Too many moving pieces going in different directions. When it wasn't a Lime issue, it was Hxcpp, or OpenFL, or a combination of these. That was 3-4 years ago though.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by dgreensp on Thursday June 07, 2018 @10:40AM
(#17256126)
The biggest thing that interests me about Haxe is it is rare to find a high-level language with a sophisticated static type system and familiar syntax. This is why TypeScript is so much beloved, but Haxe has some awesome features TypeScript lacks, like a pattern-matching switch statement (with guards), and array comprehensions.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by Drakim on Thursday June 07, 2018 @10:46AM
(#17256184)
And don't forget the macro preprocessor, it's made life a lot easier for me in so many ways. Syntax sugar, automatic asset inclusion, compiling tasks, and much more.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by badsectoracula on Thursday June 07, 2018 @09:21PM
(#17261824)
I used Haxe years ago to make Flash games and tech demos [1] (probably only works with Chrome these days). At the time it was the only free way to create Flash games (at least using an actual programming language) but even when Adobe released some free tools, Haxe was still not only much faster as a compiler but it both produced faster code and provided tools for making things fast (e.g. `inline` wasn't just a hint, if the compiler couldn't inline a function it would error out - and inlining made a difference at the time).
Eventually i lost interest in Flash and moved on to other things. I thought about using Haxe for making HTML5 games (when those were new), but unlike Flash gaming that was huge, HTML5 gaming never took off and was almost entirely about mobile games that i never cared much about. Also Haxe's JavaScript output at the time had some significant overhead that i found it simpler to just write JS directly.
I've been subscribed to the Haxe mailing list for the last 10 or so years, mainly to take a peek at what is going on and sometimes try a new version (sadly it seems Haxe is sometimes breaking backwards compatibility and often found the code needing changes), but that ended recently with the mailing list shutting down. Since then i had no other contact with the language at all.
Although sometimes i see people writing "one-to-many" transpilers, thinking that this is a neat new idea, while i'm in my corner muttering something along the lines "Haxe did that a decade ago" :-P.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by jadbox on Thursday June 07, 2018 @11:41AM
(#17256811)
I've been using Haxe over a decade, and it's really a shame it doesn't get more attention. The language is amazingly productive for game development, although lacking the GUI tools of Unity.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by thosakwe on Thursday June 07, 2018 @10:20AM
(#17255938)
It might be time to try Haxe. I’ve always wondered why it doesn’t get a lot of buzz around it. It seems like a genuinely good way to achieve “write once, run anywhere.”
It’s always interesting how the chicken-and-egg problem applies to programming languages.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by giancarlostoro on Thursday June 07, 2018 @10:30AM
(#17256028)
Its a nice language though some of the output is weird. Like I did a PHP target as a test and I think I did a print statement and it added a lot of code in there when i was expecting a simple echo or something. So it can have its downsides depending on what you do. Definitely curious where it stands for Mobile though.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by kevin_bloch on Thursday June 07, 2018 @11:34AM
(#17256731)
I wonder, did you have the "dead code elimination" feature enabled? (Just throwing it out there. I haven't tried transpiling to PHP with it myself. :) )
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by heckanoobs on Thursday June 07, 2018 @11:38AM
(#17256788)
I used Haxe and NME years ago to build an Ouya (RIP) game. I was coming from actionscript and it was a delightful language. Glad to see it's still evolving. That game project was a blur of haxe, java, and c++ due to Ouya's infancy and haxe could handle it all. I was impressed
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by disqard on Thursday June 07, 2018 @03:17PM
(#17259219)
I'd like to chime in and add that I've had to rebuild an entire Visual Programming Language (think Scratch, but free of text) to migrate away from Flash.
I picked Haxe, and it has been a solid language+compiler for what I needed (transpile to JS, and now my code runs on any modern browser).
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by canada_dry on Thursday June 07, 2018 @12:19PM
(#17257256)
Like I did a few years ago, I quickly browsed through some of the sites and didn't find solid quick start stuff needed to get me (a haxe noob) to go further.
For a 'mature' platform looking to get more attention I would have liked an easy step-by-step demo 'hello world' for a haxe -> android target.
But, I couldn't even find much in the way of haxe-for-dummies that specifically address the android target.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by bendmorris on Thursday June 07, 2018 @01:05PM
(#17257806)
Haxe doesn't quite operate at that level, it's more compiler than build tool. You'd use Haxe to compile to Java or C++, but you'd use a framework such as OpenFL, which provides its own build toolchain, to actually build an Android app via Haxe.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by sp33der89 on Thursday June 07, 2018 @04:55PM
(#17260179)
I have the same problem! They have a manual and a cookbook, but nothing real entry stuff or something similiar like the Go Tour.
https://haxe.org/blog/haxe-online-training-courses-are-comin... <- this looked real promising not sure if they still gonna do it.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by andyonthewings on Thursday June 07, 2018 @11:17AM
(#17256527)
There are some people used it quite extensively for web development (both front and back-end). This year's Hong Kong Open Source Conference will feature two Haxe talks, both are web focused:
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by joneil on Thursday June 07, 2018 @11:13AM
(#17256477)
I’ve used it for web (my failed startup was in Haxe, my side projects still are mostly Haxe).
To be honest these days I mostly just use it as a “better JavaScript” because I’d prefer my backend to be NodeJS rather than PHP or Java or sone other Haxe target. But I really do prefer it to JavaScript, even with Babel and Flow and ES6 and all the things to modernise Js.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by disqard on Thursday June 07, 2018 @03:14PM
(#17259172)
Same here. It's a "better Javascript" for me as well.
My constraints force me to use JS for what I'm building, and Haxe does a great job of insulating me from having to write and maintain a large codebase in JS.
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by k_ on Thursday June 07, 2018 @11:40AM
(#17256808)
I've mostly used it for web (mainly react applications recently), for several companies.
The haxe->js community is growing these past years, but I still think Haxe isn't getting the love it deserves (compared to TypeScript, Flow typing for react, etc.)
Re:Haxe: Cross-Platform Development's Best-Kept Secret
by kevin_bloch on Thursday June 07, 2018 @11:16AM
(#17256517)
For sure--see the examples of FontStruct, TiVo, DAZN, Heidi, etc. in the article, along with the part just before the quick start section. :) (It's true, it does have a large gamedev following, but it's actually quite versatile.)
While it "worked" and the resulting engine / suite of games ended up net profitable, and I'm a fan of Haxe's features as a language (I am really missing the pattern matching and macros in Typescript these days), I must say the build pipeline and available tools for OpenFL / Haxe games was lacking at best.
On the plus side being able to fork and fix issues we ran into was a game changer over Unity IMO.
Not sure if the ecosystem has evolved / improved on the build and tooling fronts in the last 18 months since I last interacted with it directly, but that would be the one word of caution I'd offer to anyone after they read this article. Be prepared to roll up your sleeves and get a little dirtier than usual if you really intend to ship on both web and mobile.
That was my experience as well.
Too many moving pieces going in different directions. When it wasn't a Lime issue, it was Hxcpp, or OpenFL, or a combination of these. That was 3-4 years ago though.
Eventually i lost interest in Flash and moved on to other things. I thought about using Haxe for making HTML5 games (when those were new), but unlike Flash gaming that was huge, HTML5 gaming never took off and was almost entirely about mobile games that i never cared much about. Also Haxe's JavaScript output at the time had some significant overhead that i found it simpler to just write JS directly.
I've been subscribed to the Haxe mailing list for the last 10 or so years, mainly to take a peek at what is going on and sometimes try a new version (sadly it seems Haxe is sometimes breaking backwards compatibility and often found the code needing changes), but that ended recently with the mailing list shutting down. Since then i had no other contact with the language at all.
Although sometimes i see people writing "one-to-many" transpilers, thinking that this is a neat new idea, while i'm in my corner muttering something along the lines "Haxe did that a decade ago" :-P.
[1] http://runtimeterror.com/tech/demo/flashdemos.html
It’s always interesting how the chicken-and-egg problem applies to programming languages.
I'd agree though that it's a huge marketing win.
From what I've seen Haxe has a lot of great features for individual game developers to be expressive.
[1] http://ludumdare.com/compo/author/01010111/
For a 'mature' platform looking to get more attention I would have liked an easy step-by-step demo 'hello world' for a haxe -> android target.
But, I couldn't even find much in the way of haxe-for-dummies that specifically address the android target.
I guess it's not that multi-platform, after all.
* https://hkoscon.org/2018/topic/haxe-better-javascript-practi...
* https://hkoscon.org/2018/topic/type-safe-rest-api-haxe
I believe there will be live streams, or you can checkout the video that will be available shortly after.
(I'm a member of the Haxe Foundation, also the organizer of the HKOSCon Haxe track)
To be honest these days I mostly just use it as a “better JavaScript” because I’d prefer my backend to be NodeJS rather than PHP or Java or sone other Haxe target. But I really do prefer it to JavaScript, even with Babel and Flow and ES6 and all the things to modernise Js.
The haxe->js community is growing these past years, but I still think Haxe isn't getting the love it deserves (compared to TypeScript, Flow typing for react, etc.)