No more game crashing for xml errors
This commit is contained in:
parent
0c5e9241f1
commit
32c7208a18
|
@ -243,6 +243,7 @@ public:
|
|||
GameSettings *getGameSettings() {return &gameSettings;}
|
||||
void setGameSettings(GameSettings *settings) { gameSettings = *settings;}
|
||||
const GameSettings *getReadOnlyGameSettings() const {return &gameSettings;}
|
||||
void setQuitPendingIndicator() { quitPendingIndicator = true;}
|
||||
|
||||
const GameCamera *getGameCamera() const {return &gameCamera;}
|
||||
GameCamera *getGameCameraPtr() {return &gameCamera;}
|
||||
|
|
|
@ -706,6 +706,7 @@ void Program::setState(ProgramState *programStateNew, bool cleanupOldState) {
|
|||
try {
|
||||
Game *game = dynamic_cast<Game *>(programStateNew);
|
||||
Renderer &renderer= Renderer::getInstance();
|
||||
game->setQuitPendingIndicator();// by this the world is no more updated
|
||||
renderer.initGame(game,game->getGameCameraPtr());
|
||||
}
|
||||
catch(megaglest_runtime_error& ex2) {
|
||||
|
|
Loading…
Reference in New Issue