Time for action – adding angry birds
At the moment, the stones are just launched from the air. Of course, if we move the stone's spawning point above the screen, we can imagine that there are some birds flying high and dropping the stones.
Note
In fact, we placed the launch point below the screen edge so that you can see them being launched.
However, wouldn't it be cooler to see your enemy, to look them in the eyes? Let's do this and add some birds that are dropping stones.
What we're going to do is to spawn a bird off the screen. The bird will carry a stone using a joint.
Note
Joints are constraints that used to simulate interaction between objects. For example, you can simulate one object tied with a rope to another one. It will become clear in a moment.
This bird will fly into the level and will drop the stone at the target point.
- To keep things organized, create a new Objective-C class in the
GameObjects
group. Name the classPhysicsBird
and make it a subclass of...