Chapter 6. Specialties of the Mobile Device – Touch and Tilt
In the previous chapter, we learned about Pathfinding and AI. We expanded our Tank Battle game to include enemy tanks. We created points for them to spawn at, and made them shoot at the player. Utilizing Unity's pathfinding system, we made the tanks chase the player. Also, the player was given the ability to destroy the tanks. Once destroyed, the player receives some points and a new enemy tank is spawned.
In this chapter, we start working on a new game as we explore some of the specialties of the mobile device. We will be creating a Space Fighter game. The player will take control of a space ship and blast enemy ships, mines, and asteroids for points. To steer their ship, the player will have to tilt the mobile device. To shoot, the player will touch the screen where they want their laser blast to hit.
In this chapter, we will be covering the following topics:
- Touch controls
- Tilt controls
We will be creating...