the situation is :
when we have 2 CCLayers
I Use CCDirector::sharedDirector()->pause() to pause the game , then the pause interface show up , there is a button on pauseSence , button : Main (go back to the menu)
`void PauseSenceFather::MainMenuCallBack( CCObject *pSender )
{
CocosDenshion::SimpleAudioEngine::sharedEngine()->playBackgroundMusic(CPlaySound::getInstance()->GetString("BGM").data(),true);
CGameManager::getInstance()->SetGameStatus(enGame_End);
CCDirector::sharedDirector()->resume(); // resume the game
CCScene * scene = LogoSence::scene();
CCDirector::sharedDirector()->replaceScene(CCTransitionFade::transitionWithDuration(5.0f,scene));
}`
when the LogoSence show up, I click [startgame] button again , and repeat last step (pause and return main menu) , there is the bug , when I try start game about 2 times or 3 times , crashed …
if we don’t use CCDirector::sharedDirector()->pause() , everything is ok , why ?
maybe I should use my pause function ?