Earlier this year I stumbled upon this blog post titled, Haxe what’s in it for you by Philippe Elsass. The article is about Haxe and if you know nothing about Haxe it is well worth a read (you may also wish to read Why use Haxe). I found it very interesting. Haxe is something I had always heard about but didn’t really see the need in a new language to produce the same results, a SWF, however now the ability to compile to different targets was very appealing.
If a game was written in Haxe and then able to be deployed to multiple targets, this could save months of development. I am also interested in Unity3D for similar reasons (I am generally interested in its whole workflow too), but am a little put off by its Asset store, which to me encourages developers to sell their code rather than sharing it, great I guess for the said developers but something that I feel must hinder the community, sharing code was something that really helped the Flash community grow to be so great.
Anyway, before I committed to building anything in Haxe and NME (a library that mirrors the Flash API and allows you to target C++ and Mobile) I needed to see how well it performs. I quickly ported a version of my old colleague and friend Iain Lobb’s BunnyMark to benchmark its performance, I also asked one of my colleges György to write a native C++ version for comparison.
I can’t remember the exact results but using NME, I think I was getting something like 15,000 bunnies all jumping about with alphas etc on my PC and although Gyorgy managed to push a couple of thousand extra, there wasn’t really much difference, 15,000 bunnies is still 15,000 bunnies (which is quite a lot :)).
It is fair to say I am very impressed with Haxe, not only can it target multiple platforms but the language itself is very cool with lots of features that make developing faster and generally better. There seems to be so many possibilities with Haxe and NME, more test needed!
[EDIT: Philippe Elsass has since written posted his own more detailed result here: http://philippe.elsass.me/2011/11/nme-ready-for-the-show/]