Commit 2a31393c authored by anotherguest's avatar anotherguest

Need to check if game is a valid pointer before resetting!

parent 0302767e
...@@ -820,8 +820,10 @@ int Level::load (char *fileName, unsigned char diff, bool checkpoint) { ...@@ -820,8 +820,10 @@ int Level::load (char *fileName, unsigned char diff, bool checkpoint) {
} else file->seek(4, false); } else file->seek(4, false);
// Set the players' initial values // Set the players' initial values
for (count = 0; count < nPlayers; count++) if(game) {
game->resetPlayer(players + count); for (count = 0; count < nPlayers; count++)
game->resetPlayer(players + count);
}
// Next level // Next level
x = file->loadChar(); x = file->loadChar();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment