Permalink
Browse files

SUPERNOVA: Implements death screen

  • Loading branch information...
Joefish committed Aug 4, 2017
1 parent 99ab5b8 commit 135f425b91504cd46adfaa7aa22dfbf57675d3ff
Showing with 24 additions and 0 deletions.
  1. +23 −0 engines/supernova/state.cpp
  2. +1 −0 engines/supernova/state.h
@@ -805,6 +805,29 @@ void GameManager::closeLocker(const Room *room, Object *obj, Object *lock, int s
}
}
void GameManager::death(const char *message) {
_vm->paletteFadeOut();
_guiEnabled = false;
_vm->renderImage(11, 0);
_vm->renderMessage(message);
_vm->playSound(kAudioDeath);
_vm->paletteFadeIn();
getInput();
_vm->paletteFadeOut();
_vm->removeMessage();
// TODO: Load screen
destroyRooms();
initRooms();
initState();
initGui();
_inventory.clear();
changeRoom(INTRO);
_vm->paletteFadeIn();
_guiEnabled = true;
}
int GameManager::invertSection(int section) {
if (section < 128)
section += 128;
@@ -180,6 +180,7 @@ class GameManager {
void handleInput();
void handleTime();
void setAnimationTimer(int ticks);
void death(const char *message);
};
}

0 comments on commit 135f425

Please sign in to comment.