O'Reilly logo

Beginning Android Tablet Games Programming by Jeremy Kerfs

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

Debugging Harbor Defender

With a simple approach to how the game looks, you’re ready to try it. Load it as you would any game, and you see boats slowly appear and cruise down toward the castle. If you wait long enough, they pass through the castle and off the screen.

If things don’t work this way, or you get an error like the one displayed in Figure 8-8, or the game closes at startup, then you have some work to do. This section is dedicated to fixing common problems in game development for Android. It doesn’t go into specific problems because there is no way to anticipate every error. It should be fairly obvious how to fix errors in your code if Eclipse catches them, but the runtime issues can be more difficult.

Here is the process to use:

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