Make It Your Own

At this point, you have an almost complete sprite-based game. This is a good point to stop and make some changes. Trying some experiments with the game will hone your skills and prepare you to bring some of your own game ideas to life. Here are a few ideas for changes you could make. Save a copy of your game before you start.

Make explosions drift.

Make the explosions drift. In a random direction, or down, or whatever you like. You need to give the Explosion class a move method and call that method on all the explosions.

Make explosions kill enemies.

Make the explosions collide with enemies, destroying the enemies if they are too close to the explosions. You need to test, just as you did with bullets and enemies, whether any of ...

Get Learn Game Programming with Ruby now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.