diff options
Diffstat (limited to 'engines/kyra')
-rw-r--r-- | engines/kyra/gui_v2.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/kyra_hof.h | 1 | ||||
-rw-r--r-- | engines/kyra/script_hof.cpp | 12 |
3 files changed, 13 insertions, 2 deletions
diff --git a/engines/kyra/gui_v2.cpp b/engines/kyra/gui_v2.cpp index 5ffc4d555c..300f9f116d 100644 --- a/engines/kyra/gui_v2.cpp +++ b/engines/kyra/gui_v2.cpp @@ -410,7 +410,7 @@ void GUI_v2::getInput() { _isDeleteMenu = false; } - delay(10); + _vm->delay(10); } void GUI_v2::renewHighlight(Menu &menu) { diff --git a/engines/kyra/kyra_hof.h b/engines/kyra/kyra_hof.h index f537bf57d3..f34c0d6d3a 100644 --- a/engines/kyra/kyra_hof.h +++ b/engines/kyra/kyra_hof.h @@ -750,6 +750,7 @@ protected: int o2_setRunFlag(EMCState *script); int o2_showLetter(EMCState *script); int o2_fillRect(EMCState *script); + int o2_playFireflyScore(EMCState *script); int o2_encodeShape(EMCState *script); int o2_defineSceneAnim(EMCState *script); int o2_updateSceneAnim(EMCState *script); diff --git a/engines/kyra/script_hof.cpp b/engines/kyra/script_hof.cpp index ff28e08960..14f8faad5f 100644 --- a/engines/kyra/script_hof.cpp +++ b/engines/kyra/script_hof.cpp @@ -862,6 +862,16 @@ int KyraEngine_HoF::o2_fillRect(EMCState *script) { return 0; } +int KyraEngine_HoF::o2_playFireflyScore(EMCState *script) { + debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_playFireflyScore(%p) ()", (const void *)script); + if (_sound->getSfxType() == Sound::kAdlib || _sound->getSfxType() == Sound::kMidiMT32 || _sound->getSfxType() == Sound::kMidiGM) { + snd_playWanderScoreViaMap(86, 1); + return 1; + } else { + return 0; + } +} + int KyraEngine_HoF::o2_encodeShape(EMCState *script) { debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_encodeShape(%p) (%d, %d, %d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2), stackPos(3), stackPos(4)); @@ -1623,7 +1633,7 @@ void KyraEngine_HoF::setupOpcodeTable() { // 0x68 OpcodeUnImpl(); OpcodeUnImpl(); - OpcodeUnImpl(); + Opcode(o2_playFireflyScore); Opcode(o2_waitForConfirmationClick); // 0x6c Opcode(o2_encodeShape); |