Improve restart game

This commit is contained in:
pandamicro 2014-12-31 15:32:59 +08:00
parent 5755cc69e9
commit 677f7ca1d3
1 changed files with 3 additions and 0 deletions

View File

@ -1041,6 +1041,9 @@ void Director::restartDirector()
// Texture cache need to be reinitialized
initTextureCache();
// Reschedule for action manager
getScheduler()->scheduleUpdate(getActionManager(), Scheduler::PRIORITY_SYSTEM, false);
// release the objects
PoolManager::getInstance()->getCurrentPool()->clear();