I have decided to recreate 'Reaching for the Stars' in
FlashPunk (v1.7.2) ...
Just because it seems like a nice library & I'm curious about it.
It is very easy to get started with FlashPunk & FlashDevelop.
I talked about FlashDevelop in an earlier blog. So, go ahead & read that if you don't know how to set up the editor.
Next, just download the FP source code & copy the entire 'net' folder
inside the 'src' directory of your AS3 project. Done.
The API can be found in the 'documentation' section, and some tutorials to get started are available in the 'tutorials' section.
First observation :
FlashDevelop points out that there are some errors in the FP library (source code). Turns out some 'if statements' contain '=' (assignment) instead of '==' (comparison).
But, no big deal. And easy to fix.
Second observation :
FlashPunk has its own debug console (net/flashpunk/debug/Console.as). To activate it, include 'FP.console.enable();' inside the Main() function of the Main class (extends 'Engine'). When you are running your game in debug mode, you can activate the debug console by pressing '~'.
I have to say, that this did not work for me (AZERTY keyboard).
So, if this happens to you, just open the Console.as file, and find the line that says 'public var toggleKey:uint = 192;'. I changed the code to '8', which corresponds to the backspace key.
You can find the codes & corresponding keys in the file 'net/flashpunk/util/Key.as'.
Third observation :
Every FlashPunk project starts from the Main class (which extends the Engine class). The Main class is responsible for loading the scenes in your game (think : title screen, level 1, level 2 , etc.). All game objects are Entities (extend the class Entity).
Conclusion so far :
FlashPunk is very easy to work with (although I'm currently a bit stuck with my emitters). The library code seems to be very clean and well organized.
Negative points : not a lot of documentation or tutorials ... This brings up the question : how alive is the community ??? And should I even bother learning it ???