O'Reilly logo

Learning AndEngine by Martin Varga

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

Chapter 5. Basic Interactions

It's time to learn how to make the game interactive. In this chapter, we will first see how to create a basic animation that will allow us to move the character from one place to another. We will also learn the basics of collision detection.

Then, we will look into the different sensors that Android devices have, how to read them, and how to use those readings. More specifically, we are going to use the touchscreen and accelerometer, and we will use them to move the main character around the screen.

The second part of this chapter will cover the specifics of different threads used in AndEngine in detail. We will discuss the dangers of mixing threads and common mistakes made by beginners to AndEngine.

A simple animation ...

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