aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorTravis Howell2007-03-24 00:21:47 +0000
committerTravis Howell2007-03-24 00:21:47 +0000
commit8d326d1e28eef8e9e8eea9745bdd93ee19580eff (patch)
tree28be6f19d4dc7a216870bb756ad36fe4b7d2c922 /engines
parent013d576417910cd7d8a65ea36db09ac103d9840e (diff)
downloadscummvm-rg350-8d326d1e28eef8e9e8eea9745bdd93ee19580eff.tar.gz
scummvm-rg350-8d326d1e28eef8e9e8eea9745bdd93ee19580eff.tar.bz2
scummvm-rg350-8d326d1e28eef8e9e8eea9745bdd93ee19580eff.zip
Add patch #1687013 - Zak FM-Towns: F1-F4 person switching.
svn-id: r26288
Diffstat (limited to 'engines')
-rw-r--r--engines/scumm/verbs.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/engines/scumm/verbs.cpp b/engines/scumm/verbs.cpp
index 2e37178bc1..b899ab6751 100644
--- a/engines/scumm/verbs.cpp
+++ b/engines/scumm/verbs.cpp
@@ -567,6 +567,23 @@ void ScummEngine::checkExecVerbs() {
}
}
+ if ((_game.platform == Common::kPlatformFMTowns && _game.id == GID_ZAK) &&
+ (_mouseAndKeyboardStat >= 315 && _mouseAndKeyboardStat <= 318)) {
+ // Hack: Handle switching to a person via F1-F4 keys.
+ // This feature isn't available in the scripts of the FM-TOWNS verison.
+ int fKey = _mouseAndKeyboardStat - 314;
+ int switchSlot = getVerbSlot(36, 0);
+ // check if switch-verb is enabled
+ if (_verbs[switchSlot].curmode == 1) {
+ // Check if person is available (see script 23 from ZAK_FM-TOWNS and script 4 from ZAK_PC).
+ // Zak: Var[144 Bit 15], Annie: Var[145 Bit 0], Melissa: Var[145 Bit 1], Leslie: Var[145 Bit 2]
+ if (!readVar(0x890E + fKey)) {
+ runInputScript(1, 36 + fKey, 0);
+ }
+ }
+ return;
+ }
+
// Generic keyboard input
runInputScript(4, _mouseAndKeyboardStat, 1);
} else if (_mouseAndKeyboardStat & MBS_MOUSE_MASK) {