aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorJohannes Schickel2008-03-17 22:42:12 +0000
committerJohannes Schickel2008-03-17 22:42:12 +0000
commit8752939fe480b471febed9a9e85069208429b7d3 (patch)
tree29dc283d47159ee5ecd73ed4a90b9feaf9ff9a0d /engines
parentf6f61a5bc32caf7b3716b0905edba3800de1648d (diff)
downloadscummvm-rg350-8752939fe480b471febed9a9e85069208429b7d3.tar.gz
scummvm-rg350-8752939fe480b471febed9a9e85069208429b7d3.tar.bz2
scummvm-rg350-8752939fe480b471febed9a9e85069208429b7d3.zip
Implemented opcodes:
- 91: o2_blockInRegion - 92: o2_blockOutRegion svn-id: r31166
Diffstat (limited to 'engines')
-rw-r--r--engines/kyra/kyra_v2.h2
-rw-r--r--engines/kyra/script_v2.cpp16
2 files changed, 16 insertions, 2 deletions
diff --git a/engines/kyra/kyra_v2.h b/engines/kyra/kyra_v2.h
index e74be7aab8..87d4e0e29b 100644
--- a/engines/kyra/kyra_v2.h
+++ b/engines/kyra/kyra_v2.h
@@ -1007,6 +1007,8 @@ protected:
int o2_loadMusicTrack(ScriptState *script);
int o2_playWanderScoreViaMap(ScriptState *script);
int o2_playSoundEffect(ScriptState *script);
+ int o2_blockInRegion(ScriptState *script);
+ int o2_blockOutRegion(ScriptState *script);
int o2_setCauldronState(ScriptState *script);
int o2_getRand(ScriptState *script);
int o2_setDrawNoShapeFlag(ScriptState *script);
diff --git a/engines/kyra/script_v2.cpp b/engines/kyra/script_v2.cpp
index e439fe8539..2ea6d51089 100644
--- a/engines/kyra/script_v2.cpp
+++ b/engines/kyra/script_v2.cpp
@@ -688,6 +688,18 @@ int KyraEngine_v2::o2_playSoundEffect(ScriptState *script) {
return 0;
}
+int KyraEngine_v2::o2_blockInRegion(ScriptState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_blockInRegion(%p) (%d, %d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2), stackPos(3));
+ _screen->blockInRegion(stackPos(0), stackPos(1), stackPos(2)-stackPos(0)+1, stackPos(3)-stackPos(1)+1);
+ return 0;
+}
+
+int KyraEngine_v2::o2_blockOutRegion(ScriptState *script) {
+ debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_blockOutRegion(%p) (%d, %d, %d, %d)", (const void *)script, stackPos(0), stackPos(1), stackPos(2), stackPos(3));
+ _screen->blockOutRegion(stackPos(0), stackPos(1), stackPos(2)-stackPos(0)+1, stackPos(3)-stackPos(1)+1);
+ return 0;
+}
+
int KyraEngine_v2::o2_setCauldronState(ScriptState *script) {
debugC(3, kDebugLevelScriptFuncs, "KyraEngine_v2::o2_setCauldronState(%p) (%d, %d)", (const void *)script, stackPos(0), stackPos(1));
setCauldronState(stackPos(0), stackPos(1) != 0);
@@ -1501,9 +1513,9 @@ void KyraEngine_v2::setupOpcodeTable() {
Opcode(o2_playWanderScoreViaMap),
Opcode(o2_playSoundEffect),
OpcodeUnImpl(),
- OpcodeUnImpl(),
+ Opcode(o2_blockInRegion),
// 0x5c
- OpcodeUnImpl(),
+ Opcode(o2_blockOutRegion),
OpcodeUnImpl(),
Opcode(o2_setCauldronState),
OpcodeUnImpl(),