One of the best technological advances brought by mobile devices is the accelerometer, which is a hardware mechanism that provides the capability of measuring the G-force acceleration on the x, y, and z coordinates.
This technology opened a wide field of new types of games and helped modernize some existing genres. We are going to utilize it to provide a new way to control the rabbit's movement.
In order to start receiving information from the accelerometer, we are going to import a new framework to our project. But first of all, let's open the initial project for this chapter, which is similar to the one that we left at the end of the previous chapter, by performing the following steps:
Unzip
7338_05_Resources.zip
, where you will findInsideTheHat_init.zip
. Unzip it too and open the project with Xcode.If you take a look to its contents, you will see that we are not using the
plist
file information anymore to load the door's distribution.
Now that we have the basis of...