I have been working on this for few hours, can’t get anything to work.
I want to create an explosion effect, so I create the explosion animation, create the ccanimate and let a explosion sprite to run that ccanimate via runAction();
But when the Action is done, I should be able to detect and delete the sprite.
but CCAction~~>isDone doesn’t work at all.
When the animation is finished, CCAction~~>done() will still stay false.
@ cocos2d::CCSprite *sprite = (cocos2d::CCSprite*) children~~>objectAtIndex;
cocos2d::CCAction *action = NULL;
if) // can’t work!
I looked up the ccanimate manual, there is no callback function, no indicator function that tells the action is done.
what am i suppose to do?