
Chapter 4. Game #3, CometCrusher
Asteroids was a classic arcade game in the 80s. You could find it in every arcade hall. You had to control a little spaceship and blast asteroids which were flying around into pieces. Sometimes an enemy spaceship flew by and you had to avoid its deadly shots and try to shoot it down for additional points. If you don't know about this game, then have a look at the following: http://en.wikipedia.org/wiki/Asteroids_%28video_game%29.
In the game, you are trapped inside a huge asteroid field, and you have to make sure that your little spaceship is not crushed by these huge rocks of heavy material. Three hits and your ship is gone! So blast your cannon at them and smash them into pieces. Once you are done, you can be sure that there is more work for you to do because space is full of rocks.
During this chapter, we make heavy use of a game framework called fantomEngine. We will do the following:
- Create, load, and display images via the fantomEngine game framework
- Save and load a high score list via SaveState
- Load and play sound effects
- Learn where to store the game resources
- Install Flex, and a command-line compiler to create FLASH games
Since almost every game stores at least a high score list, you will learn how to create a high score list, save it, and also load it back into the game the next time the game loads.
Besides the actual game code, we will learn how to export to FLASH.