From c8c3dd04a780a106905cc9582058099a7ead343f Mon Sep 17 00:00:00 2001 From: Max Horn Date: Fri, 23 Mar 2007 23:38:45 +0000 Subject: Patch #1687010: FM-Towns: Handle Alt-F5 svn-id: r26284 --- engines/scumm/verbs.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'engines/scumm') diff --git a/engines/scumm/verbs.cpp b/engines/scumm/verbs.cpp index 76c45a8a47..2e37178bc1 100644 --- a/engines/scumm/verbs.cpp +++ b/engines/scumm/verbs.cpp @@ -557,6 +557,16 @@ void ScummEngine::checkExecVerbs() { _mouseAndKeyboardStat = numpad[_mouseAndKeyboardStat - '0']; } + if (_game.platform == Common::kPlatformFMTowns && (_game.id == GID_ZAK || _game.id == GID_INDY3)) { + // HACK: In the FM-Towns games Indy3 and Zak the most significant bit is set for special keys + // like F5 (=0x8005) or joystick buttons (mask 0xFE00, e.g. SELECT=0xFE40 for the save/load menu). + // Hence the distinction with (_mouseAndKeyboardStat < MBS_MAX_KEY) between mouse- and key-events is not applicable + // to this games, so we have to remap the special keys here. + if(_mouseAndKeyboardStat == 319) { + _mouseAndKeyboardStat = 0x8005; + } + } + // Generic keyboard input runInputScript(4, _mouseAndKeyboardStat, 1); } else if (_mouseAndKeyboardStat & MBS_MOUSE_MASK) { -- cgit v1.2.3