Home > Articles > Programming > Games

  • Print
  • + Share This
This chapter is from the book


The Workshop is designed to help you anticipate possible questions, review what you've learned, and begin learning how to put your knowledge into practice. The answers to the quiz can be found in Appendix A, "Quiz Answers."


  1. What's the difference between a meteor, a meteorite, and a meteoroid?

  2. What is the purpose of the m_bOneCycle member variable in the Sprite class?

  3. How do you destroy a sprite and have it removed from the sprite list in the game engine?


  1. Modify the calculation of the score and difficulty level so that the Meteor Defense game lasts a little longer and allows you to attain higher scores.

  2. Modify the game so that you lose points and temporarily lose the ability to fire from one of the guns if the gun is hit by a meteor. You don't need to change the guns to sprites in order to add this feature—just use the position of the meteor when it is destroyed to determine if it hit one of the guns.

  • + Share This
  • 🔖 Save To Your Account