Working with CCAction


Actions (Base Class CCAction) are one of the most powerful feature of Cocos2d. 
         
Actions can be performed on any CCNode for example Sprites.      


// create sprite from Image File
CCSprite *man = [CCSprite spriteWithFile:@"man.png"];

// add sprite to the layer
[self addChild:man];

// create a CCMoveTo action
CCMoveTo *moveAction = [CCMoveTo animationWithDuration: 2.3f position:CGPointMake(200,400)];

 // run the action on sprite
[man runAction:moveAction];

List of Actions in Cocos2d
         
Basic -> Move, Scale, Rotate, Beizer, Hide, Fade, etc.
Composition -> Sequence, Repeat, Spawn, RepeatForEver, etc.
Ease -> Ease, Ease Exponential, EaseBounce, etc.
Effectes -> Lens, Liquid, Ripple, Shaky, Twirl, Waves, etc.
Special -> CallFunc, Follow, etc.