Actionscript 3 game engine for the popular Platform Jump genre.
- The player is moved horizontally with mouse
- Bounce off the platforms to go higher
- Collect power ups for boost
- Don’t fall down
The pack contains:
- Documentation PDF file
- The source code for the engine with comments
- Two .fla files, compatible with Adobe Flash CS4 and CS5 with a working example
- FlashDevelop project file (PlatformJumper.as3proj) for use in FlashDevelop
- Sound assets used in the example
FlashDevelop users (without Flash IDE):
The documentation and implementation of the engine was created with Flash IDE in mind. It is, of course, possible to not use Flash IDE and only use free resources like Flex SDK and FlashDevelop to work with this engine. That is, however, only suitable for advanced users with at least moderate knowledge of Actionscript 3.
If you’re a coder, the engine class files are what you are looking for. The code is commented and also explained in the docs, so you might not actually need Flash IDE at all if you know what you’re doing. If you’re not really skilled in AS3, though, the Adobe Flash approach might be more suitable for you (it’s easier).
What you can easily edit:
The whole engine is created with customization in mind. You can delve deep into the code and extend functionality of the game, or you can tweak these values to change the gameplay to fit your preference:
- gameWidth – Width of the game screen.
- gameHeight – Height of the game screen.
- gravityAcceleration – How fast vertical velocity changes (round number).
- platformWidth – Width of the platform in pixels (remember to edit the graphic too).
- mouseSmooth – Smoothness of the horizontal movement. The bigger the number, the smoother the player moves. Don’t set to 1 or below.
- bounceStrength – How hard the player bounces off platforms.
- platformInterval – Distance between the platforms vertically.
- scoreDistance – How many pixels vertically are worth 1 point.
- boostStrength – How strong the boost power up is.
- boostDistance – Distance between power ups vertically.
- boostRadius – How close the player has to be to the powerup to pick it up.
- actualGroundHeight – Height of the unwalkable area in the ground graphic.
- cloudsTotal – How many clouds can there be on the screen at the same time.
- cloudMaxScale – How big can the clouds in percentages.
- cloudMinScale – How small can the clouds in percentages.
- cloudMinSpeed – How slow can the clouds go.
- cloudMaxSpeed – How fast can the clouds go.
- scrollHeight – Distance from top, which scrolls the game up if the player enters it. Usually around 1/3 of the game height.
- scoreLabel – Score label – what appears after the numeric score value (m, meters, km, feet, etc.).
- motionBlur – Motion blur on platforms – platforms get the nice vertical blur effect depending on velocity. Set to true or false.