The Final Challenge
As a final challenge to this project, why not try adding a HUD layer to this project yourself? Here's the specifications:
- There should be a line that shows your current number of lives.
- There should be a line that says "Exit:" with an arrow next to it. The arrow should point in the direction of the exit, relative ot the tank.
This should be a good review of working with multiple layers, passing data between layers, and working with some vector math functions. If you get stuck, you might want to review the How to Create a HUD Layer with Cocos2D tutorial... or you could always cheat by looking at the solution at the end of the article ;]
Happy hacking!
Where To Go From Here?
Here is an example project with all of the code from the above tutorial series (including the optional HUD challenge).
At this point, you have the basics of a pretty fun game! Feel free to add additional features, change out the artwork, and use it as a basis for an app of your own!
If you have any questions or comments on this tutorial, please join the forum discussion below!