Archive for February, 2007

Game Algorithms

I’m checking game algorithms these days. Found a lot funny things and some not good enough or fit with Flash. Most of traditional algorithms are run directly on OS so there’s no much limitations for the speed and CPU/memory usage, but Flash not the case. Though it’s interest to try different algorithms and I could also get some ideas from those.

Algorithms are mathematics involved. But it could be trade-off and not necessary for all details due to my time. Some time I will try to look on math equations but most time I will directly to code them in Actionscript 3 first and see whether I understand and comment directly.

I saw some code written in C as someone discussed it as much effective than regular ‘best practise’ C code. He said it’s because those codes got idea from Assembly actually. Of course if you code C with assembly method, you could check the machine code (read: mov, add, goto) and you know they’re effective or not. But for Flash, it’s a little bit more hard. Maybe if some day I found an algorithm if necessary to be optimized, I will try to read low level code (similar to read Assembly) with the decompiler provided by Adobe. Also have to have some experiential testing.

Squirrel Bubble Game AS3 – Beta

Current version: 0.2.0 (Beta)

Updates:

Game save/load supported. Score list available. Audio added. Message class added. Improved rules: 1. No chanllenges 2. Life points count, after 5 fails a new line of bubbles will be pushed in. (But you can get points back in some case). 3. Push double lines of bubbles. 4. No points reward so you have to finish your game.

If you find any bugs, please let me know. Thanks.

Next game suppose to be a FPS tank game in 3D. Big topic for me right now.

A part of source code available for download. It’s the method to load assets from external SWF files and use them dynamically in this game.