O'Reilly logo

Mastering Android Game Development by Raul Portales

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

Now our game is really playable, we can detect when the bullets touch the asteroids and destroy them; additionally, we have to be careful because our ship can be destroyed by them as well.

We have learned how to do simple collision detection with rectangular and circular bodies, adjusting the body for each particular sprite.

We also learned some optimization techniques for collision detection and implemented one that makes use of spatial partitioning.

The next step in our roadmap is to add some juiciness to the game. Didn't you notice that the asteroids are missing some explosions? In the next chapter, we are going to talk about how to create particle systems for effects.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required