O'Reilly logo

Learn SpriteBuilder for iOS Game Development by Steffen Itterheim

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter    5

Timelines & Triggers

One of SpriteBuilder’s major features is its ability to create Timeline animations using keyframes. It can even animate static physics bodies through keyframes while providing proper physics collisions, a feature that is unheard of in other 2D game engines.

This chapter explains how to create Timeline animations with SpriteBuilder and how to play such animations using CCBAnimationManager. At the end, you’ll have rotating physics gear and saw objects that can push the player forward.

You’ll also create a reusable trigger node that you can place in the level with a corresponding Trigger class. This allows you to run code when the player enters the trigger area—for instance, playing a Timeline animation on target ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required