Automatic Reference Counting (or ARC for short) makes memory management in your apps much easier.
ARC’s major benefit is freeing you from worrying about whether you cleaned up that sprite or image from your game. As you probably know, even a small memory leak can make your game behave unpredictably. And after all, nothing kills a great game experience like an application crash while in the heat of the action.
Another benefit of ARC is that since it takes care of memory management for you, it allows you to focus on game development. Every minute you have for development lets you get your app done faster! What’s not to like about that?
However, by default the Cocos2D templates do not have ARC enabled. So a common question is “how can I use ARC in a Cocos2D project?” This tutorial will show you how to do exactly that! :]
First you’ll build a simple ARC-enabled project from scratch. Then, it’s Return of the Ninjas Going Pew-Pew! You’ll take the classic raywenderlich.com game and learn how to update games made with Cocos2D 1.X to Cocos2D 2.X.
Ready to expand your ninja-skills? Keep reading to get started! (more…)