diff options
author | Florian Kagerer | 2009-06-07 13:07:16 +0000 |
---|---|---|
committer | Florian Kagerer | 2009-06-07 13:07:16 +0000 |
commit | 6d59856fe1c2302a5e163f3b4799c94a721e102d (patch) | |
tree | 8cc78507b3d1a6ada1135c2c7136031aa4ef7f8d /engines/kyra/script_lol.cpp | |
parent | de88db5f36ff666f9ae31cd0f4287d79fd25d22d (diff) | |
download | scummvm-rg350-6d59856fe1c2302a5e163f3b4799c94a721e102d.tar.gz scummvm-rg350-6d59856fe1c2302a5e163f3b4799c94a721e102d.tar.bz2 scummvm-rg350-6d59856fe1c2302a5e163f3b4799c94a721e102d.zip |
LOL: implemented two more opcodes for castle cimmeria
svn-id: r41336
Diffstat (limited to 'engines/kyra/script_lol.cpp')
-rw-r--r-- | engines/kyra/script_lol.cpp | 35 |
1 files changed, 33 insertions, 2 deletions
diff --git a/engines/kyra/script_lol.cpp b/engines/kyra/script_lol.cpp index 549b88773d..56cfb9110f 100644 --- a/engines/kyra/script_lol.cpp +++ b/engines/kyra/script_lol.cpp @@ -1280,6 +1280,13 @@ int LoLEngine::olol_getMonsterStat(EMCState *script) { return 0; } +int LoLEngine::olol_releaseMonsterShapes(EMCState *script) { + debugC(3, kDebugLevelScriptFuncs, "LoLEngine::olol_releaseMonsterShapes(%p)", (const void *)script); + for (int i = 0; i < 3; i++) + releaseMonsterShapes(i); + return 0; +} + int LoLEngine::olol_playCharacterScriptChat(EMCState *script) { debugC(3, kDebugLevelScriptFuncs, "LoLEngine::olol_playCharacterScriptChat(%p) (%d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2)); snd_stopSpeech(1); @@ -1392,6 +1399,30 @@ int LoLEngine::olol_countAllMonsters(EMCState *script){ return res; } +int LoLEngine::olol_playEndSequence(EMCState *script){ + debugC(3, kDebugLevelScriptFuncs, "LoLEngine::olol_playEndSequence(%p)", (const void *)script); + + int c = 0; + if (_characters[0].id == -9) + c = 1; + else if (_characters[0].id == -5) + c = 3; + else if (_characters[0].id == -1) + c = 2; + + while (snd_updateCharacterSpeech()) + delay(_tickLength); + + _eventList.clear(); + _screen->hideMouse(); + memset(_screen->getPalette(1), 0, 768); + + showOutro(c, _monsterDifficulty == 2 ? true : false); + quitGame(); + + return 0; +} + int LoLEngine::olol_stopCharacterSpeech(EMCState *script) { debugC(3, kDebugLevelScriptFuncs, "LoLEngine::olol_stopCharacterSpeech(%p)", (const void *)script); snd_stopSpeech(1); @@ -2713,7 +2744,7 @@ void LoLEngine::setupOpcodeTable() { // 0x5C Opcode(olol_getMonsterStat); - OpcodeUnImpl(); + Opcode(olol_releaseMonsterShapes); Opcode(olol_playCharacterScriptChat); Opcode(olol_update); @@ -2731,7 +2762,7 @@ void LoLEngine::setupOpcodeTable() { // 0x68 Opcode(olol_countAllMonsters); - OpcodeUnImpl(); + Opcode(olol_playEndSequence); Opcode(olol_stopCharacterSpeech); Opcode(olol_setPaletteBrightness); |