diff options
author | Paul Gilbert | 2018-02-24 15:42:58 -0500 |
---|---|---|
committer | Paul Gilbert | 2018-02-24 15:42:58 -0500 |
commit | 2fe8c9418020d3a36e31db85013de04734237e93 (patch) | |
tree | 28e4a9bdcd12edfd64e4ff9d4640fd2ae7a0abd8 /engines | |
parent | ad7206ea38c491ec7cca82d705a37bc19ad3aed0 (diff) | |
download | scummvm-rg350-2fe8c9418020d3a36e31db85013de04734237e93.tar.gz scummvm-rg350-2fe8c9418020d3a36e31db85013de04734237e93.tar.bz2 scummvm-rg350-2fe8c9418020d3a36e31db85013de04734237e93.zip |
XEEN: Implemented Swords of Xeen death screen
Diffstat (limited to 'engines')
-rw-r--r-- | engines/xeen/swordsofxeen/swordsofxeen.cpp | 46 |
1 files changed, 45 insertions, 1 deletions
diff --git a/engines/xeen/swordsofxeen/swordsofxeen.cpp b/engines/xeen/swordsofxeen/swordsofxeen.cpp index 671a1bce92..afd846736f 100644 --- a/engines/xeen/swordsofxeen/swordsofxeen.cpp +++ b/engines/xeen/swordsofxeen/swordsofxeen.cpp @@ -36,7 +36,51 @@ void SwordsOfXeenEngine::outerGameLoop() { } void SwordsOfXeenEngine::death() { - error("TODO: Swords of Xeen death screen"); + Windows &windows = *g_vm->_windows; + + _screen->loadBackground("blank.raw"); + windows[28].setBounds(Common::Rect(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT)); + _screen->fadeIn(0x81); + _screen->loadPalette("scr.pal"); + _screen->fadeIn(0x81); + + SpriteResource lose("lose.int"); + lose.draw(0, 0, Common::Point(0, 0)); + lose.draw(0, 1, Common::Point(160, 0)); + _sound->playSound("laff1.voc"); + + bool breakFlag = false; + for (int idx = 0, idx2 = 0; idx < (_files->_isDarkCc ? 10 : 23); ++idx) { + _events->updateGameCounter(); + + if (_files->_isDarkCc) { + breakFlag = _events->wait(2); + } else { + if (idx == 1 || idx == 11) + _sound->playFX(33); + breakFlag = _events->wait(2); + + if (idx == 15) + _sound->playFX(34); + } + + if ((_files->_isDarkCc ? 9 : 10) == idx) { + if ((_files->_isDarkCc ? 2 : 1) > idx2) { + // Restart loop + idx = -1; + ++idx2; + } + } + } + + // Wait for press + if (!breakFlag) + _events->waitForPress(); + + _screen->fadeOut(4); + _screen->loadBackground("blank.raw"); + _screen->loadPalette("dark.pal"); + _sound->stopAllAudio(); } void SwordsOfXeenEngine::dream() { |