Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

srinivas.be88

macrumors newbie
Original poster
Aug 10, 2010
24
0
hi ,
i created a menu and that contains "startgame","settings","about" and "exit". when i touch the startgame it loads a play screeen . i added a pause button on playscreen. when i touch a pause button game will show the menu screen.. menu and playscreen created in two scene.when i call the pause method that pause the all scene.
when i touch the pause button i called the pause method that contains
{
[[CCDirector shareddirector] pause];
}

but i need to display the menu screen again. how to implement this one.
the CCDirector pause the whole game.but i need to pause the playscreen only and call the another scene
 
In my game I didn't switch scenes at all when they hit the pause button. I paused the director and stopped animation, then unscheduled all running schedulers (so the score doesn't keep going up while it's paused). Then I recreated my CCMenu and background on top of everything in my game scene. This way it gives the illusion that the scene changed, or in my case the pause menu was overlaid on the game scene, but really it's just a menu drawn on top of the game scene. Then if they click resume I unpause the director, start animation, and reschedule all schedulers. It has worked out pretty well so far.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.