From b864b846356b6b20d6e6def414456b5d44fe88c7 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Sun, 7 Dec 2014 19:03:06 +0100 Subject: ACCESS: Fix the end of the demo --- engines/access/amazon/amazon_game.cpp | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) (limited to 'engines/access') diff --git a/engines/access/amazon/amazon_game.cpp b/engines/access/amazon/amazon_game.cpp index 979fffe2d3..b425fe9e22 100644 --- a/engines/access/amazon/amazon_game.cpp +++ b/engines/access/amazon/amazon_game.cpp @@ -621,7 +621,11 @@ void AmazonEngine::dead(int deathId) { _screen->clearScreen(); _screen->setPanel(3); - if (deathId != 10) { + if ((deathId == 10) && !isDemo()) { + quitGame(); + _events->pollEvents(); + return; + } else { if (!isDemo()) _midi->newMusic(62, 0); _files->_setPaletteFlag = false; @@ -629,14 +633,16 @@ void AmazonEngine::dead(int deathId) { _files->_setPaletteFlag = true; _buffer2.copyFrom(*_screen); - for (int i = 0; i < 3; ++i) { - _sound->playSound(0); - _screen->forceFadeIn(); - _sound->playSound(0); - _screen->forceFadeOut(); + if (!isDemo() || deathId != 10) { + for (int i = 0; i < 3; ++i) { + _sound->playSound(0); + _screen->forceFadeIn(); + _sound->playSound(0); + _screen->forceFadeOut(); - if (shouldQuit()) - return; + if (shouldQuit()) + return; + } } if (!isDemo()) { @@ -708,9 +714,6 @@ void AmazonEngine::dead(int deathId) { warning("TODO: restart game"); quitGame(); _events->pollEvents(); - } else { - quitGame(); - _events->pollEvents(); } } -- cgit v1.2.3