I've this problem: in my game, when I tap a sprite, an animation in called.开发者_运维问答 This animation is stored inside a singleton class (called Animation) that is inizialized in the didFinischLaunching method. When I need for an action i use this code:
[self runAction:[[Animation sharedAnimation] animationName]];
On the device when I tap the sprite for the first time, occurs the following issues (one and only at the first tap):
- There is a delay from the moment when I tap the sprite and the moment that the animation really starts;
- In this interval (delay) the frame count collapses to 10fps (in some case even to 6fps)
This issues there aren't when I tap the same sprite for a second, third, etc times.
Ideas ??
Thanks very much!
Do you alloc the spriteframes in your animation init method? If so, that's why.
Good luck!
精彩评论