From 90f9bf37cdb0f89005206af37e1efbf3a871bb8a Mon Sep 17 00:00:00 2001 From: jianglong0156 Date: Tue, 23 Jun 2015 14:41:41 +0800 Subject: [PATCH] fix redmine issue #20277 RestartGameTest only used in native will crash --- cocos/base/CCDirector.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cocos/base/CCDirector.cpp b/cocos/base/CCDirector.cpp index 0be71ab673..7ef479424c 100644 --- a/cocos/base/CCDirector.cpp +++ b/cocos/base/CCDirector.cpp @@ -1007,6 +1007,9 @@ void Director::restartDirector() { reset(); + // RenderState need to be reinitialized + RenderState::initialize(); + // Texture cache need to be reinitialized initTextureCache();