Introducing the Astrocrash Game


The project for this chapter, the Astrocrash game, is my version of the classic arcade game Asteroids. In Astrocrash, the player controls a ship in a moving field of deadly asteroids. The ship can rotate and thrust forward—most importantly, though, it can fire missiles at the asteroids to destroy them. But the player has some work cut out for him or her as large and medium-sized asteroids break apart into two smaller asteroids when destroyed. And just when the player manages to obliterate all of the asteroids, a new, larger wave appears. The player's score increases with every asteroid he or she destroys, but once the player's ship collides with a floating space rock, the game is over. Figures 12.1 and 12.2 show the game in action.

click to expand
Figure 12.1: The player controls a spaceship and blasts asteroids to increase his or her score. (Nebula image is in the public domain. Credit— NASA, The Hubble Heritage Team - AURA/STScI)

click to expand
Figure 12.2: If an asteroid hits the player's ship, the game is over.




Python Programming for the Absolute Beginner
Python Programming for the Absolute Beginner, 3rd Edition
ISBN: 1435455002
EAN: 2147483647
Year: 2003
Pages: 194

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net