Merge pull request #251 from klusark/fixscene

Fix crash when trying to change to the current scene. Fixes #245
This commit is contained in:
Giulio Camuffo 2011-06-24 05:42:05 -07:00
commit 1f3ce4a319

View File

@ -1477,6 +1477,8 @@ void GrimEngine::setScene(const char *name) {
}
void GrimEngine::setScene(Scene *scene) {
if (scene == _currScene)
return;
Scene *lastScene = _currScene;
_currScene = scene;
_currScene->setSoundParameters(20, 127);