Hey developers !
I am searching for how to un disable a scene ? I mean I have a GamePlay class in which the game is running. Then when you hit a button it goes to the menu with this code :
[[CCDirector sharedDirector] replaceScene:[CCSplitRowsTransition transitionWithDuration:1 scene:[HelloWorld node]]];
But the problem is that while I am on the menu the GamePlay scene continue running itself. Is it normal ? How to prevent that ?
And I have another problem : I have a character in my GamePlay view who can interact with objects. For example when the character interacts with the bag, the bag fadeout and scaleby 1.5. But there is also ennemies who can collide with objects and when an ennemy collide with an object, it does exactly the same thing for the object as when the character collides with this object. Sometimes, the character touches the object and before that the object finished its animation, the ennemy collides with this same object who is a CCSprite. So what happens is that my CCSprite run 2 times the same action. I want to prevent that by disabling to the object the ability to collide with the character or with the ennemies when the ennemy or the character touches for the first time the object. I hope you understood ? Remember that objects which can interract with the ennemies or the character are CCSprites.
Thanks in advance for your help,
Best regards