I am trying to play through an animation using these files that I created with texture packer (footballAnim-hd.pvr.ccz) and (footballAnim.pv-hd.plist) but I have encountered a problem. Here is my code:
[[CCSpriteFrameCache sharedSpriteFrameCache] addSpriteFramesWithFile:@"footballAnim.pv.plist"];
CCSprite *football = [CCSprite spriteWithSpriteFrameName:@"Football59-hd.png"];
football.position = ccp(100, 100);
CCSprite *football2 = [CCSprite spriteWithSpriteFrameName:@"Football59-hd.png"];
football2.position = ccp(120, 100);
//This is the animation
id anim = [CCAnimate actionWithSpriteSequence:@"Football%d-hd.png"
numFrames:59
delay:0.01
restoreOriginalFrame:NO];
//This is the animation
id anim2 = [CCAnimate actionWithSpriteSequence:@"Football%d-hd.png"
numFrames:59
delay:0.01
restoreOriginalFrame:NO];
//This is the action
id repeat = [CCRepeatForever actionWithAction:anim];
//This is the action
id repeat2 = [CCRepeatForever actionWithAction:anim2];
CCSpriteBatchNode *batchNode=[CCSpriteBatchNode batchNodeWithFile:@"footballAnim.pvr.ccz"];
[self addChild:batchNode];
[batchNode addChild:football];
[batchNode addChild:football2];
[football runAction:repeat];
[football2 runAction:repeat2];
So My problem is I am using kobold2d which is using (cocos2d v1.1.0-beta2b) and when I try to play this animation it only plays through half of the frames, but then I tried this (EXACT) code in another cocos2d project which is using (cocos2d v1.0.0-rc) and it works like a charm. Is this a bug in cocos2d or am I not doing something right?