aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
authorJohannes Schickel2008-05-03 19:47:07 +0000
committerJohannes Schickel2008-05-03 19:47:07 +0000
commitf6239f1db645c86fb4f072f7e901ac30c75f71a0 (patch)
tree4c939f3b6fa110c655dcfdd1f5647d0560793d5f /engines/kyra
parent895adc75fa26335a58f31310ecb15e17fdc1667c (diff)
downloadscummvm-rg350-f6239f1db645c86fb4f072f7e901ac30c75f71a0.tar.gz
scummvm-rg350-f6239f1db645c86fb4f072f7e901ac30c75f71a0.tar.bz2
scummvm-rg350-f6239f1db645c86fb4f072f7e901ac30c75f71a0.zip
Moved some more opcodes to KyraEngine_v2.
svn-id: r31843
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/kyra_hof.h11
-rw-r--r--engines/kyra/kyra_mr.h11
-rw-r--r--engines/kyra/kyra_v2.h11
-rw-r--r--engines/kyra/script_hof.cpp92
-rw-r--r--engines/kyra/script_mr.cpp114
-rw-r--r--engines/kyra/script_v2.cpp91
6 files changed, 114 insertions, 216 deletions
diff --git a/engines/kyra/kyra_hof.h b/engines/kyra/kyra_hof.h
index 4035e49ce1..6e1656e638 100644
--- a/engines/kyra/kyra_hof.h
+++ b/engines/kyra/kyra_hof.h
@@ -784,9 +784,6 @@ protected:
int o2_fillRect(EMCState *script);
int o2_waitForConfirmationClick(EMCState *script);
int o2_encodeShape(EMCState *script);
- int o2_defineRoomEntrance(EMCState *script);
- int o2_runTemporaryScript(EMCState *script);
- int o2_setSpecialSceneScriptRunTime(EMCState *script);
int o2_defineSceneAnim(EMCState *script);
int o2_updateSceneAnim(EMCState *script);
int o2_addToSceneAnimPosAndUpdate(EMCState *script);
@@ -815,9 +812,6 @@ protected:
int o2_deinitObject(EMCState *script);
int o2_playTimSequence(EMCState *script);
int o2_makeBookOrCauldronAppear(EMCState *script);
- int o2_setSpecialSceneScriptState(EMCState *script);
- int o2_clearSpecialSceneScriptState(EMCState *script);
- int o2_querySpecialSceneScriptState(EMCState *script);
int o2_resetInputColorCode(EMCState *script);
int o2_setHiddenItemsEntry(EMCState *script);
int o2_getHiddenItemsEntry(EMCState *script);
@@ -826,9 +820,6 @@ protected:
int o2_customChatFinish(EMCState *script);
int o2_setupSceneAnimation(EMCState *script);
int o2_stopSceneAnimation(EMCState *script);
- int o2_disableTimer(EMCState *script);
- int o2_enableTimer(EMCState *script);
- int o2_setTimerCountdown(EMCState *script);
int o2_processPaletteIndex(EMCState *script);
int o2_updateTwoSceneAnims(EMCState *script);
int o2_getRainbowRoomData(EMCState *script);
@@ -837,8 +828,6 @@ protected:
int o2_getSfxDriver(EMCState *script);
int o2_getVocSupport(EMCState *script);
int o2_getMusicDriver(EMCState *script);
- int o2_setVocHigh(EMCState *script);
- int o2_getVocHigh(EMCState *script);
int o2_zanthiaChat(EMCState *script);
int o2_isVoiceEnabled(EMCState *script);
int o2_isVoicePlaying(EMCState *script);
diff --git a/engines/kyra/kyra_mr.h b/engines/kyra/kyra_mr.h
index e662c2e824..33755870ba 100644
--- a/engines/kyra/kyra_mr.h
+++ b/engines/kyra/kyra_mr.h
@@ -560,9 +560,6 @@ private:
int o3_goodConscienceChat(EMCState *script);
int o3_hideGoodConscience(EMCState *script);
int o3_waitForConfirmationClick(EMCState *script);
- int o3_defineRoomEntrance(EMCState *script);
- int o3_runTemporaryScript(EMCState *script);
- int o3_setSpecialSceneScriptRunTime(EMCState *script);
int o3_defineSceneAnim(EMCState *script);
int o3_updateSceneAnim(EMCState *script);
int o3_runActorScript(EMCState *script);
@@ -577,20 +574,12 @@ private:
int o3_countItemInstances(EMCState *script);
int o3_dialogStartScript(EMCState *script);
int o3_dialogEndScript(EMCState *script);
- int o3_setSpecialSceneScriptState(EMCState *script);
- int o3_clearSpecialSceneScriptState(EMCState *script);
- int o3_querySpecialSceneScriptState(EMCState *script);
int o3_setHiddenItemsEntry(EMCState *script);
int o3_getHiddenItemsEntry(EMCState *script);
int o3_customChat(EMCState *script);
int o3_customChatFinish(EMCState *script);
int o3_setupSceneAnimObject(EMCState *script);
int o3_removeSceneAnimObject(EMCState *script);
- int o3_disableTimer(EMCState *script);
- int o3_enableTimer(EMCState *script);
- int o3_setTimerCountdown(EMCState *script);
- int o3_setVocHigh(EMCState *script);
- int o3_getVocHigh(EMCState *script);
int o3_dummy(EMCState *script);
// misc
diff --git a/engines/kyra/kyra_v2.h b/engines/kyra/kyra_v2.h
index e5d91d61b7..265c4dcfbe 100644
--- a/engines/kyra/kyra_v2.h
+++ b/engines/kyra/kyra_v2.h
@@ -369,6 +369,17 @@ protected:
int o2_addSpecialExit(EMCState *script);
int o2_setMousePos(EMCState *script);
int o2_showMouse(EMCState *script);
+ int o2_defineRoomEntrance(EMCState *script);
+ int o2_runAnimationScript(EMCState *script);
+ int o2_setSpecialSceneScriptRunTime(EMCState *script);
+ int o2_setSpecialSceneScriptState(EMCState *script);
+ int o2_clearSpecialSceneScriptState(EMCState *script);
+ int o2_querySpecialSceneScriptState(EMCState *script);
+ int o2_disableTimer(EMCState *script);
+ int o2_enableTimer(EMCState *script);
+ int o2_setTimerCountdown(EMCState *script);
+ int o2_setVocHigh(EMCState *script);
+ int o2_getVocHigh(EMCState *script);
};
} // end of namespace Kyra
diff --git a/engines/kyra/script_hof.cpp b/engines/kyra/script_hof.cpp
index 85536dbaf3..e276eb2a55 100644
--- a/engines/kyra/script_hof.cpp
+++ b/engines/kyra/script_hof.cpp
@@ -980,50 +980,6 @@ int KyraEngine_HoF::o2_encodeShape(EMCState *script) {
return 0;
}
-int KyraEngine_HoF::o2_defineRoomEntrance(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_defineRoomEntrance(%p) (%d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2));
- switch (stackPos(0)) {
- case 0:
- _sceneEnterX1 = stackPos(1);
- _sceneEnterY1 = stackPos(2);
- break;
-
- case 1:
- _sceneEnterX2 = stackPos(1);
- _sceneEnterY2 = stackPos(2);
- break;
-
- case 2:
- _sceneEnterX3 = stackPos(1);
- _sceneEnterY3 = stackPos(2);
- break;
-
- case 3:
- _sceneEnterX4 = stackPos(1);
- _sceneEnterY4 = stackPos(2);
- break;
-
- default:
- break;
- }
- return 0;
-}
-
-int KyraEngine_HoF::o2_runTemporaryScript(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_runTemporaryScript(%p) ('%s', %d, %d, %d)", (const void *)script, stackPosString(0), stackPos(1),
- stackPos(2), stackPos(3));
-
- runAnimationScript(stackPosString(0), stackPos(3), stackPos(2) ? 1 : 0, stackPos(1), stackPos(2));
- return 0;
-}
-
-int KyraEngine_HoF::o2_setSpecialSceneScriptRunTime(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_setSpecialSceneScriptRunTime(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
- assert(stackPos(0) >= 0 && stackPos(0) < 10);
- _sceneSpecialScriptsTimer[stackPos(0)] = _system->getMillis() + stackPos(1) * _tickLength;
- return 0;
-}
-
int KyraEngine_HoF::o2_defineSceneAnim(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_defineSceneAnim(%p) (%d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, '%s')", (const void *)script,
stackPos(0), stackPos(1), stackPos(2), stackPos(3), stackPos(4), stackPos(5), stackPos(6), stackPos(7), stackPos(8),
@@ -1327,23 +1283,6 @@ int KyraEngine_HoF::o2_makeBookOrCauldronAppear(EMCState *script) {
return 0;
}
-int KyraEngine_HoF::o2_setSpecialSceneScriptState(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_setSpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
- _specialSceneScriptState[stackPos(0)] = 1;
- return 1;
-}
-
-int KyraEngine_HoF::o2_clearSpecialSceneScriptState(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_clearSpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
- _specialSceneScriptState[stackPos(0)] = 0;
- return 0;
-}
-
-int KyraEngine_HoF::o2_querySpecialSceneScriptState(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_querySpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
- return _specialSceneScriptState[stackPos(0)];
-}
-
int KyraEngine_HoF::o2_resetInputColorCode(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_resetInputColorCode(%p)", (const void *)script);
memset(_inputColorCode, 255, 7);
@@ -1497,24 +1436,6 @@ int KyraEngine_HoF::o2_stopSceneAnimation(EMCState *script) {
return 0;
}
-int KyraEngine_HoF::o2_disableTimer(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_disableTimer(%p) (%d)", (const void *)script, stackPos(0));
- _timer->disable(stackPos(0));
- return 0;
-}
-
-int KyraEngine_HoF::o2_enableTimer(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_enableTimer(%p) (%d)", (const void *)script, stackPos(0));
- _timer->enable(stackPos(0));
- return 0;
-}
-
-int KyraEngine_HoF::o2_setTimerCountdown(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_setTimerCountdown(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
- _timer->setCountdown(stackPos(0), stackPos(1));
- return 0;
-}
-
int KyraEngine_HoF::o2_processPaletteIndex(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_processPaletteIndex(%p) (%d, %d, %d, %d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2), stackPos(3), stackPos(4), stackPos(5));
uint8 *palette = _screen->getPalette(0);
@@ -1599,17 +1520,6 @@ int KyraEngine_HoF::o2_getMusicDriver(EMCState *script) {
return 0;
}
-int KyraEngine_HoF::o2_setVocHigh(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_setVocHigh(%p) (%d)", (const void *)script, stackPos(0));
- _vocHigh = stackPos(0);
- return _vocHigh;
-}
-
-int KyraEngine_HoF::o2_getVocHigh(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_getVocHigh(%p) ()", (const void *)script);
- return _vocHigh;
-}
-
int KyraEngine_HoF::o2_zanthiaChat(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_HoF::o2_zanthiaChat(%p) ('%s', %d)", (const void *)script, stackPosString(0), stackPos(1));
objectChat(stackPosString(0), 0, _vocHigh, stackPos(1));
@@ -1878,7 +1788,7 @@ void KyraEngine_HoF::setupOpcodeTable() {
// 0x6c
Opcode(o2_encodeShape);
Opcode(o2_defineRoomEntrance);
- Opcode(o2_runTemporaryScript);
+ Opcode(o2_runAnimationScript);
Opcode(o2_setSpecialSceneScriptRunTime);
// 0x70
Opcode(o2_defineSceneAnim);
diff --git a/engines/kyra/script_mr.cpp b/engines/kyra/script_mr.cpp
index c90765dd84..98e8c2a7a5 100644
--- a/engines/kyra/script_mr.cpp
+++ b/engines/kyra/script_mr.cpp
@@ -870,52 +870,6 @@ int KyraEngine_MR::o3_waitForConfirmationClick(EMCState *script) {
return 1;
}
-int KyraEngine_MR::o3_defineRoomEntrance(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_defineRoomEntrance(%p) (%d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2));
- switch (stackPos(0)) {
- case 0:
- _sceneEnterX1 = stackPos(1);
- _sceneEnterY1 = stackPos(2);
- break;
-
- case 1:
- _sceneEnterX2 = stackPos(1);
- _sceneEnterY2 = stackPos(2);
- break;
-
- case 2:
- _sceneEnterX3 = stackPos(1);
- _sceneEnterY3 = stackPos(2);
- break;
-
- case 3:
- _sceneEnterX4 = stackPos(1);
- _sceneEnterY4 = stackPos(2);
- break;
-
- default:
- break;
- }
- return 0;
-}
-
-int KyraEngine_MR::o3_runTemporaryScript(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_runTemporaryScript(%p) ('%s', %d, %d, %d)", (const void *)script,
- stackPosString(0), stackPos(1), stackPos(2), stackPos(3));
- const int newShapes = stackPos(1);
- const int unloadShapes = stackPos(2);
- const int allowSkip = stackPos(3);
- runAnimationScript(stackPosString(0), allowSkip, (unloadShapes != 0) ? 1 : 0, newShapes, unloadShapes);
- return 0;
-}
-
-int KyraEngine_MR::o3_setSpecialSceneScriptRunTime(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_setSpecialSceneScriptRunTime(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
- assert(stackPos(0) >= 0 && stackPos(0) < 10);
- _sceneSpecialScriptsTimer[stackPos(0)] = _system->getMillis() + stackPos(1) * _tickLength;
- return 0;
-}
-
int KyraEngine_MR::o3_defineSceneAnim(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_defineSceneAnim(%p) (%d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, '%s')",
(const void *)script, stackPos(0), stackPos(1), stackPos(2), stackPos(3), stackPos(4), stackPos(5), stackPos(6), stackPos(7),
@@ -1159,23 +1113,6 @@ int KyraEngine_MR::o3_dialogEndScript(EMCState *script) {
return 0;
}
-int KyraEngine_MR::o3_setSpecialSceneScriptState(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_setSpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
- _specialSceneScriptState[stackPos(0)] = 1;
- return 1;
-}
-
-int KyraEngine_MR::o3_clearSpecialSceneScriptState(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_clearSpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
- _specialSceneScriptState[stackPos(0)] = 0;
- return 0;
-}
-
-int KyraEngine_MR::o3_querySpecialSceneScriptState(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_querySpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
- return _specialSceneScriptState[stackPos(0)];
-}
-
int KyraEngine_MR::o3_setHiddenItemsEntry(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_setHiddenItemsEntry(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
return (_hiddenItems[stackPos(0)] = (uint16)stackPos(1));
@@ -1228,35 +1165,6 @@ int KyraEngine_MR::o3_removeSceneAnimObject(EMCState *script) {
return 0;
}
-int KyraEngine_MR::o3_disableTimer(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_disableTimer(%p) (%d)", (const void *)script, stackPos(0));
- _timer->disable(stackPos(0));
- return 0;
-}
-
-int KyraEngine_MR::o3_enableTimer(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_enableTimer(%p) (%d)", (const void *)script, stackPos(0));
- _timer->enable(stackPos(0));
- return 0;
-}
-
-int KyraEngine_MR::o3_setTimerCountdown(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_setTimerCountdown(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
- _timer->setCountdown(stackPos(0), stackPos(1));
- return 0;
-}
-
-int KyraEngine_MR::o3_setVocHigh(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_setVocHigh(%p) (%d)", (const void *)script, stackPos(0));
- _vocHigh = stackPos(0);
- return 0;
-}
-
-int KyraEngine_MR::o3_getVocHigh(EMCState *script) {
- debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_getVocHigh(%p) ()", (const void *)script);
- return _vocHigh;
-}
-
int KyraEngine_MR::o3_dummy(EMCState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_MR::o3_dummy(%p) ()", (const void *)script);
return 0;
@@ -1448,9 +1356,9 @@ void KyraEngine_MR::setupOpcodeTable() {
Opcode(o3_waitForConfirmationClick);
// 0x6c
Opcode(o3_dummy);
- Opcode(o3_defineRoomEntrance);
- Opcode(o3_runTemporaryScript);
- Opcode(o3_setSpecialSceneScriptRunTime);
+ Opcode(o2_defineRoomEntrance);
+ Opcode(o2_runAnimationScript);
+ Opcode(o2_setSpecialSceneScriptRunTime);
// 0x70
Opcode(o3_defineSceneAnim);
Opcode(o3_dummy);
@@ -1490,10 +1398,10 @@ void KyraEngine_MR::setupOpcodeTable() {
Opcode(o3_dialogEndScript);
Opcode(o3_dummy);
Opcode(o3_dummy);
- Opcode(o3_setSpecialSceneScriptState);
+ Opcode(o2_setSpecialSceneScriptState);
// 0x90
- Opcode(o3_clearSpecialSceneScriptState);
- Opcode(o3_querySpecialSceneScriptState);
+ Opcode(o2_clearSpecialSceneScriptState);
+ Opcode(o2_querySpecialSceneScriptState);
Opcode(o3_dummy);
Opcode(o3_setHiddenItemsEntry);
// 0x94
@@ -1507,9 +1415,9 @@ void KyraEngine_MR::setupOpcodeTable() {
Opcode(o3_setupSceneAnimObject);
Opcode(o3_removeSceneAnimObject);
// 0x9c
- Opcode(o3_disableTimer);
- Opcode(o3_enableTimer);
- Opcode(o3_setTimerCountdown);
+ Opcode(o2_disableTimer);
+ Opcode(o2_enableTimer);
+ Opcode(o2_setTimerCountdown);
OpcodeUnImpl();
// 0xa0
Opcode(o3_dummy);
@@ -1520,9 +1428,9 @@ void KyraEngine_MR::setupOpcodeTable() {
OpcodeUnImpl();
OpcodeUnImpl();
OpcodeUnImpl();
- Opcode(o3_setVocHigh);
+ Opcode(o2_setVocHigh);
// 0xa8
- Opcode(o3_getVocHigh);
+ Opcode(o2_getVocHigh);
OpcodeUnImpl();
OpcodeUnImpl();
OpcodeUnImpl();
diff --git a/engines/kyra/script_v2.cpp b/engines/kyra/script_v2.cpp
index dd7aca79ee..10504b2b1e 100644
--- a/engines/kyra/script_v2.cpp
+++ b/engines/kyra/script_v2.cpp
@@ -25,6 +25,7 @@
#include "kyra/kyra_v2.h"
#include "kyra/screen_v2.h"
+#include "kyra/timer.h"
#include "common/endian.h"
@@ -139,6 +140,96 @@ int KyraEngine_v2::o2_showMouse(EMCState *script) {
return 0;
}
+int KyraEngine_v2::o2_defineRoomEntrance(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_defineRoomEntrance(%p) (%d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2));
+ switch (stackPos(0)) {
+ case 0:
+ _sceneEnterX1 = stackPos(1);
+ _sceneEnterY1 = stackPos(2);
+ break;
+
+ case 1:
+ _sceneEnterX2 = stackPos(1);
+ _sceneEnterY2 = stackPos(2);
+ break;
+
+ case 2:
+ _sceneEnterX3 = stackPos(1);
+ _sceneEnterY3 = stackPos(2);
+ break;
+
+ case 3:
+ _sceneEnterX4 = stackPos(1);
+ _sceneEnterY4 = stackPos(2);
+ break;
+
+ default:
+ break;
+ }
+ return 0;
+}
+
+int KyraEngine_v2::o2_runAnimationScript(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_runAnimationScript(%p) ('%s', %d, %d, %d)", (const void *)script, stackPosString(0), stackPos(1),
+ stackPos(2), stackPos(3));
+
+ runAnimationScript(stackPosString(0), stackPos(3), stackPos(2) ? 1 : 0, stackPos(1), stackPos(2));
+ return 0;
+}
+
+int KyraEngine_v2::o2_setSpecialSceneScriptRunTime(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_setSpecialSceneScriptRunTime(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
+ assert(stackPos(0) >= 0 && stackPos(0) < 10);
+ _sceneSpecialScriptsTimer[stackPos(0)] = _system->getMillis() + stackPos(1) * _tickLength;
+ return 0;
+}
+
+int KyraEngine_v2::o2_setSpecialSceneScriptState(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_setSpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
+ _specialSceneScriptState[stackPos(0)] = 1;
+ return 1;
+}
+
+int KyraEngine_v2::o2_clearSpecialSceneScriptState(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_clearSpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
+ _specialSceneScriptState[stackPos(0)] = 0;
+ return 0;
+}
+
+int KyraEngine_v2::o2_querySpecialSceneScriptState(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_querySpecialSceneScriptState(%p) (%d)", (const void *)script, stackPos(0));
+ return _specialSceneScriptState[stackPos(0)];
+}
+
+int KyraEngine_v2::o2_disableTimer(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_disableTimer(%p) (%d)", (const void *)script, stackPos(0));
+ _timer->disable(stackPos(0));
+ return 0;
+}
+
+int KyraEngine_v2::o2_enableTimer(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_enableTimer(%p) (%d)", (const void *)script, stackPos(0));
+ _timer->enable(stackPos(0));
+ return 0;
+}
+
+int KyraEngine_v2::o2_setTimerCountdown(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_setTimerCountdown(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
+ _timer->setCountdown(stackPos(0), stackPos(1));
+ return 0;
+}
+
+int KyraEngine_v2::o2_setVocHigh(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_setVocHigh(%p) (%d)", (const void *)script, stackPos(0));
+ _vocHigh = stackPos(0);
+ return _vocHigh;
+}
+
+int KyraEngine_v2::o2_getVocHigh(EMCState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_getVocHigh(%p) ()", (const void *)script);
+ return _vocHigh;
+}
+
#pragma mark -
int KyraEngine_v2::o2a_setAnimationShapes(EMCState *script) {