Web and Downloadable Game Engine Choices 2009
December 20th, 2009In my last post I complained about the lack of a perfect silver bullet game engine that would fit my needs as a small indie developer starting up a new game project. My three primary target platforms are Windows, Mac and the web, in roughly that order.
“But Karja, haven’t you heard? iPhone/XBox Live 360/Android/etc etc is the new indie platform of choice! This guy I read about made six billion dollars on his game there!”
I have a number of reasons why that is utter bull excrement:
- iPhone is flooded with games. Literally flooded, with thousands and thousands of games that make it hard to gain visibility. Also, iPhone relies on Apple’s SDK, objective-C (to some extent at the very least), touch screen, low-end hardware, etc etc – and all of these aspects have to be hand-crafted for the iPhone release without being reusable on other platforms.
- XBox 360 is good if you only intend to target Windows and XB360. But that would be incredibly stupid for me, since my target audience isn’t the XBox lads.
- Android is interesting. It would be neat to get in quickly just in case the market suddenly explodes รก la iPhone. But, and this is a big but, Android requires Java which is utterly incompatible with web deployment (Flash is the only viable option there).
After some consideration, I found that my options are as follows:
- Java – Windows and Mac deployment is possible, and I can deploy on Android as well, eventually. I also looked at Java-to-Actionscript converters, but…that feels desperate and unreliable. So, web deployment is a no-go for this one.
- BlitzMax – What, BlitzMax? That only supports Win/Mac! Yes, but I seriously considered trying to write a BMax->Actionscript converter since I already have a lot of BMax code and an abstraction layer API in place. (This means that I would have to write the APIs for drawing/sound in Actionscript from scratch, but convert the game logic at least.)
- C++ – Screw web deployment, and go for a full-fledged C++ engine! That would be the most fun to code in. But… No. 2010 is coming up and the web is the new black.
- HaXe – This would allow web deployment, and there’s a neat HaXe->C++ converter that can be used along with NME/NEASH, an SDL version of the flash API. Essentially, what this promises is that the same code could be used to make a Flash version and a compiled standalone downloadable (…as well as an iPhone version!). Alas, things aren’t as good as they sound. I did some quick tests and NME/NEASH lacks a lot of bitmap manipulation support. For example, BitmapData.colorTransform() support is missing – and this means that the alpha channel of bitmaps cannot be modified in the downloadable version. Things like this make HaXe seem way too shaky at the moment.
- PushButton Engine – If I’m considering pure Flash (well, Actionscript) engines, this is a strong candidate. It’s a well-designed library intended to be used for larger game projects. However…. After looking at the code a bit, I fail to see exactly what it will bring. The rendering, file-loading and game state management seems to be the biggest things that it provides but to be honest those aren’t all that tricky to write by yourself.
- flixel – Another Actionscript/Flash engine. This one seems very attractive at first, but the main problem with flixel is that it makes assumptions. “You only want to make a platformer style game, right? You’ll want to use pixelated effects, right? You want to embed all files since you’re deploy for the web only, right?” And so on.
- Actionscript/Flex – Finally, the last option is to go for pure Actionscript with Flex. No no no, I’m not trying to reinvent the wheel and have a NIH (Not Invented Here) mentality. But to be frank, writing the main framework that flixel or PBE would provide is…not that much work. Also, I have specific needs: for example, I need to target different platforms and handle files differently on the different platforms (embedded/external).
Nothing is decided at all, but I’m currently leaning towards using PBE, flixel or pure AS/Flex. My main beef with that is whether or not it’s fast enough to look good on the downloadable versions. HaXe seemed like an interesting choice for a long while, and I’m sure that it will be in the future, but I simply found too many flaws in it to provide any actual benefit at the moment. I’m (probably) going for a double-buffer approach with quite a few alpha effects on bitmaps (not in the least for the particles), so the current unstable alpha support in the SDL parts makes HaXe’s NME/NEASH solution for downloadables and iPhone pretty dubious.
In the end maybe I oughtn’t spend so much time investigating this, and just choose something and start developing instead. I guess all engines and choices have their flaws, so nothing’s going to be perfect.
