Public Member Functions | Static Public Member Functions

CCAnimationCache Class Reference

#import "CCAnimationCache.h"

List of all members.

Public Member Functions

(void) - addAnimation:name:
(CCAnimation *) - animationByName:
(void) - removeAnimationByName:

Static Public Member Functions

(void) + purgeSharedAnimationCache
(CCAnimationCache *) + sharedAnimationCache

Detailed Description

Singleton that manages the Animations. It saves in a cache the animations. You should use this class if you want to save your animations in a cache.

Before v0.99.5, the recommend way was to save them on the CCSprite. Since v0.99.5, you should use this class instead.

Since:
v0.99.5

Member Function Documentation

- (void) addAnimation: (CCAnimation *)  animation
name: (NSString *)  name 

Adds a CCAnimation with a name.

- (CCAnimation*) animationByName: (NSString *)  name  

Returns a CCAnimation that was previously added. If the name is not found it will return nil. You should retain the returned copy if you are going to use it.

+ (void) purgeSharedAnimationCache  

Purges the cache. It releases all the CCAnimation objects and the shared instance.

- (void) removeAnimationByName: (NSString *)  name  

Deletes a CCAnimation from the cache.

+ (CCAnimationCache *) sharedAnimationCache  

Retruns ths shared instance of the Animation cache


The documentation for this class was generated from the following file: