Hi,
How do I control the speed & flow of an AtlasAnimation?
I have the code below
AtlasAnimation* animation = [AtlasAnimation animationWithName:@"anim" delay:0.1];
[animation addFrameWithRect:CGRectMake(0, 0, 87, 87)];
[animation addFrameWithRect:CGRectMake(87, 0, 87, 87)];
[animation addFrameWithRect:CGRectMake(174, 0, 87, 87)];
[animation addFrameWithRect:CGRectMake(261, 0, 87, 87)];
[animation addFrameWithRect:CGRectMake(174, 0, 87, 87)];
[animation addFrameWithRect:CGRectMake(87, 0, 87, 87)];
[animation addFrameWithRect:CGRectMake(0, 0, 87, 87)];
id action = [Animate actionWithAnimation:animation];
id repeatAction = [Repeat actionWithAction:action times:2];
[self.animSprite runAction:repeatAction];
So basically the issue I am having is when it is times:1 and not times:2, the animation doesn't run.
Same thing when I try to change the delay from 0.1 to 0.01 to make it faster.
Thanks,
Tee