aboutsummaryrefslogtreecommitdiff
path: root/engines/sci
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sci')
-rw-r--r--engines/sci/configure.engine4
-rw-r--r--engines/sci/console.cpp1780
-rw-r--r--engines/sci/console.h4
-rw-r--r--engines/sci/debug.h4
-rw-r--r--engines/sci/decompressor.cpp4
-rw-r--r--engines/sci/decompressor.h4
-rw-r--r--engines/sci/detection.cpp4
-rw-r--r--engines/sci/detection_tables.h883
-rw-r--r--engines/sci/engine/features.cpp4
-rw-r--r--engines/sci/engine/features.h4
-rw-r--r--engines/sci/engine/file.cpp4
-rw-r--r--engines/sci/engine/file.h4
-rw-r--r--engines/sci/engine/gc.cpp4
-rw-r--r--engines/sci/engine/gc.h4
-rw-r--r--engines/sci/engine/kernel.cpp16
-rw-r--r--engines/sci/engine/kernel.h8
-rw-r--r--engines/sci/engine/kernel_tables.h12
-rw-r--r--engines/sci/engine/kevent.cpp16
-rw-r--r--engines/sci/engine/kfile.cpp44
-rw-r--r--engines/sci/engine/kgraphics.cpp7
-rw-r--r--engines/sci/engine/kgraphics32.cpp14
-rw-r--r--engines/sci/engine/klists.cpp4
-rw-r--r--engines/sci/engine/kmath.cpp4
-rw-r--r--engines/sci/engine/kmenu.cpp4
-rw-r--r--engines/sci/engine/kmisc.cpp7
-rw-r--r--engines/sci/engine/kmovement.cpp4
-rw-r--r--engines/sci/engine/kparse.cpp4
-rw-r--r--engines/sci/engine/kpathing.cpp6
-rw-r--r--engines/sci/engine/kscripts.cpp4
-rw-r--r--engines/sci/engine/ksound.cpp4
-rw-r--r--engines/sci/engine/kstring.cpp4
-rw-r--r--engines/sci/engine/kvideo.cpp4
-rw-r--r--engines/sci/engine/message.cpp4
-rw-r--r--engines/sci/engine/message.h4
-rw-r--r--engines/sci/engine/object.cpp5
-rw-r--r--engines/sci/engine/object.h4
-rw-r--r--engines/sci/engine/savegame.cpp64
-rw-r--r--engines/sci/engine/savegame.h4
-rw-r--r--engines/sci/engine/script.cpp11
-rw-r--r--engines/sci/engine/script.h13
-rw-r--r--engines/sci/engine/script_patches.cpp3557
-rw-r--r--engines/sci/engine/script_patches.h108
-rw-r--r--engines/sci/engine/scriptdebug.cpp78
-rw-r--r--engines/sci/engine/seg_manager.cpp21
-rw-r--r--engines/sci/engine/seg_manager.h9
-rw-r--r--engines/sci/engine/segment.cpp4
-rw-r--r--engines/sci/engine/segment.h4
-rw-r--r--engines/sci/engine/selector.cpp4
-rw-r--r--engines/sci/engine/selector.h4
-rw-r--r--engines/sci/engine/state.cpp6
-rw-r--r--engines/sci/engine/state.h4
-rw-r--r--engines/sci/engine/static_selectors.cpp4
-rw-r--r--engines/sci/engine/vm.cpp21
-rw-r--r--engines/sci/engine/vm.h4
-rw-r--r--engines/sci/engine/vm_types.cpp41
-rw-r--r--engines/sci/engine/vm_types.h29
-rw-r--r--engines/sci/engine/workarounds.cpp239
-rw-r--r--engines/sci/engine/workarounds.h7
-rw-r--r--engines/sci/event.cpp4
-rw-r--r--engines/sci/event.h4
-rw-r--r--engines/sci/graphics/animate.cpp6
-rw-r--r--engines/sci/graphics/animate.h4
-rw-r--r--engines/sci/graphics/cache.cpp4
-rw-r--r--engines/sci/graphics/cache.h4
-rw-r--r--engines/sci/graphics/compare.cpp14
-rw-r--r--engines/sci/graphics/compare.h6
-rw-r--r--engines/sci/graphics/controls16.cpp4
-rw-r--r--engines/sci/graphics/controls16.h4
-rw-r--r--engines/sci/graphics/controls32.cpp4
-rw-r--r--engines/sci/graphics/controls32.h4
-rw-r--r--engines/sci/graphics/coordadjuster.cpp4
-rw-r--r--engines/sci/graphics/coordadjuster.h4
-rw-r--r--engines/sci/graphics/cursor.cpp4
-rw-r--r--engines/sci/graphics/cursor.h4
-rw-r--r--engines/sci/graphics/font.cpp4
-rw-r--r--engines/sci/graphics/font.h4
-rw-r--r--engines/sci/graphics/fontsjis.cpp4
-rw-r--r--engines/sci/graphics/fontsjis.h4
-rw-r--r--engines/sci/graphics/frameout.cpp14
-rw-r--r--engines/sci/graphics/frameout.h4
-rw-r--r--engines/sci/graphics/helpers.h4
-rw-r--r--engines/sci/graphics/maciconbar.cpp8
-rw-r--r--engines/sci/graphics/maciconbar.h4
-rw-r--r--engines/sci/graphics/menu.cpp4
-rw-r--r--engines/sci/graphics/menu.h4
-rw-r--r--engines/sci/graphics/paint.cpp4
-rw-r--r--engines/sci/graphics/paint.h4
-rw-r--r--engines/sci/graphics/paint16.cpp4
-rw-r--r--engines/sci/graphics/paint16.h4
-rw-r--r--engines/sci/graphics/paint32.cpp12
-rw-r--r--engines/sci/graphics/paint32.h4
-rw-r--r--engines/sci/graphics/palette.cpp4
-rw-r--r--engines/sci/graphics/palette.h4
-rw-r--r--engines/sci/graphics/picture.cpp154
-rw-r--r--engines/sci/graphics/picture.h6
-rw-r--r--engines/sci/graphics/portrait.cpp265
-rw-r--r--engines/sci/graphics/portrait.h15
-rw-r--r--engines/sci/graphics/ports.cpp11
-rw-r--r--engines/sci/graphics/ports.h4
-rw-r--r--engines/sci/graphics/screen.cpp160
-rw-r--r--engines/sci/graphics/screen.h18
-rw-r--r--engines/sci/graphics/text16.cpp4
-rw-r--r--engines/sci/graphics/text16.h4
-rw-r--r--engines/sci/graphics/text32.cpp4
-rw-r--r--engines/sci/graphics/text32.h4
-rw-r--r--engines/sci/graphics/transitions.cpp4
-rw-r--r--engines/sci/graphics/transitions.h4
-rw-r--r--engines/sci/graphics/view.cpp116
-rw-r--r--engines/sci/graphics/view.h4
-rw-r--r--engines/sci/parser/grammar.cpp26
-rw-r--r--engines/sci/parser/said.cpp4
-rw-r--r--engines/sci/parser/vocabulary.cpp31
-rw-r--r--engines/sci/parser/vocabulary.h4
-rw-r--r--engines/sci/resource.cpp55
-rw-r--r--engines/sci/resource.h38
-rw-r--r--engines/sci/resource_audio.cpp126
-rw-r--r--engines/sci/resource_intern.h4
-rw-r--r--engines/sci/sci.cpp81
-rw-r--r--engines/sci/sci.h56
-rw-r--r--engines/sci/sound/audio.cpp60
-rw-r--r--engines/sci/sound/audio.h6
-rw-r--r--engines/sci/sound/drivers/adlib.cpp4
-rw-r--r--engines/sci/sound/drivers/amigamac.cpp4
-rw-r--r--engines/sci/sound/drivers/cms.cpp4
-rw-r--r--engines/sci/sound/drivers/fb01.cpp4
-rw-r--r--engines/sci/sound/drivers/fmtowns.cpp4
-rw-r--r--engines/sci/sound/drivers/gm_names.h4
-rw-r--r--engines/sci/sound/drivers/map-mt32-to-gm.h4
-rw-r--r--engines/sci/sound/drivers/midi.cpp4
-rw-r--r--engines/sci/sound/drivers/mididriver.h4
-rw-r--r--engines/sci/sound/drivers/pcjr.cpp4
-rw-r--r--engines/sci/sound/midiparser_sci.cpp239
-rw-r--r--engines/sci/sound/midiparser_sci.h26
-rw-r--r--engines/sci/sound/music.cpp638
-rw-r--r--engines/sci/sound/music.h50
-rw-r--r--engines/sci/sound/soundcmd.cpp22
-rw-r--r--engines/sci/sound/soundcmd.h4
-rw-r--r--engines/sci/util.cpp4
-rw-r--r--engines/sci/util.h4
-rw-r--r--engines/sci/video/robot_decoder.cpp8
-rw-r--r--engines/sci/video/robot_decoder.h4
-rw-r--r--engines/sci/video/seq_decoder.cpp4
-rw-r--r--engines/sci/video/seq_decoder.h4
143 files changed, 6291 insertions, 3330 deletions
diff --git a/engines/sci/configure.engine b/engines/sci/configure.engine
new file mode 100644
index 0000000000..d1c45a4654
--- /dev/null
+++ b/engines/sci/configure.engine
@@ -0,0 +1,4 @@
+# This file is included from the main "configure" script
+# add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps]
+add_engine sci "SCI" yes "sci32" "SCI 0-1.1 games"
+add_engine sci32 "SCI32 games" no
diff --git a/engines/sci/console.cpp b/engines/sci/console.cpp
index 50fae61de0..565e9752c3 100644
--- a/engines/sci/console.cpp
+++ b/engines/sci/console.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -79,148 +79,151 @@ Console::Console(SciEngine *engine) : GUI::Debugger(),
assert(_engine->_gamestate);
// Variables
- DVar_Register("sleeptime_factor", &g_debug_sleeptime_factor, DVAR_INT, 0);
- DVar_Register("gc_interval", &engine->_gamestate->scriptGCInterval, DVAR_INT, 0);
- DVar_Register("simulated_key", &g_debug_simulated_key, DVAR_INT, 0);
- DVar_Register("track_mouse_clicks", &g_debug_track_mouse_clicks, DVAR_BOOL, 0);
- DVar_Register("script_abort_flag", &_engine->_gamestate->abortScriptProcessing, DVAR_INT, 0);
+ registerVar("sleeptime_factor", &g_debug_sleeptime_factor);
+ registerVar("gc_interval", &engine->_gamestate->scriptGCInterval);
+ registerVar("simulated_key", &g_debug_simulated_key);
+ registerVar("track_mouse_clicks", &g_debug_track_mouse_clicks);
+ // FIXME: This actually passes an enum type instead of an integer but no
+ // precaution is taken to assure that all assigned values are in the range
+ // of the enum type. We should handle this more carefully...
+ registerVar("script_abort_flag", (int *)&_engine->_gamestate->abortScriptProcessing);
// General
- DCmd_Register("help", WRAP_METHOD(Console, cmdHelp));
+ registerCmd("help", WRAP_METHOD(Console, cmdHelp));
// Kernel
-// DCmd_Register("classes", WRAP_METHOD(Console, cmdClasses)); // TODO
- DCmd_Register("opcodes", WRAP_METHOD(Console, cmdOpcodes));
- DCmd_Register("selector", WRAP_METHOD(Console, cmdSelector));
- DCmd_Register("selectors", WRAP_METHOD(Console, cmdSelectors));
- DCmd_Register("functions", WRAP_METHOD(Console, cmdKernelFunctions));
- DCmd_Register("class_table", WRAP_METHOD(Console, cmdClassTable));
+// registerCmd("classes", WRAP_METHOD(Console, cmdClasses)); // TODO
+ registerCmd("opcodes", WRAP_METHOD(Console, cmdOpcodes));
+ registerCmd("selector", WRAP_METHOD(Console, cmdSelector));
+ registerCmd("selectors", WRAP_METHOD(Console, cmdSelectors));
+ registerCmd("functions", WRAP_METHOD(Console, cmdKernelFunctions));
+ registerCmd("class_table", WRAP_METHOD(Console, cmdClassTable));
// Parser
- DCmd_Register("suffixes", WRAP_METHOD(Console, cmdSuffixes));
- DCmd_Register("parse_grammar", WRAP_METHOD(Console, cmdParseGrammar));
- DCmd_Register("parser_nodes", WRAP_METHOD(Console, cmdParserNodes));
- DCmd_Register("parser_words", WRAP_METHOD(Console, cmdParserWords));
- DCmd_Register("sentence_fragments", WRAP_METHOD(Console, cmdSentenceFragments));
- DCmd_Register("parse", WRAP_METHOD(Console, cmdParse));
- DCmd_Register("set_parse_nodes", WRAP_METHOD(Console, cmdSetParseNodes));
- DCmd_Register("said", WRAP_METHOD(Console, cmdSaid));
+ registerCmd("suffixes", WRAP_METHOD(Console, cmdSuffixes));
+ registerCmd("parse_grammar", WRAP_METHOD(Console, cmdParseGrammar));
+ registerCmd("parser_nodes", WRAP_METHOD(Console, cmdParserNodes));
+ registerCmd("parser_words", WRAP_METHOD(Console, cmdParserWords));
+ registerCmd("sentence_fragments", WRAP_METHOD(Console, cmdSentenceFragments));
+ registerCmd("parse", WRAP_METHOD(Console, cmdParse));
+ registerCmd("set_parse_nodes", WRAP_METHOD(Console, cmdSetParseNodes));
+ registerCmd("said", WRAP_METHOD(Console, cmdSaid));
// Resources
- DCmd_Register("diskdump", WRAP_METHOD(Console, cmdDiskDump));
- DCmd_Register("hexdump", WRAP_METHOD(Console, cmdHexDump));
- DCmd_Register("resource_id", WRAP_METHOD(Console, cmdResourceId));
- DCmd_Register("resource_info", WRAP_METHOD(Console, cmdResourceInfo));
- DCmd_Register("resource_types", WRAP_METHOD(Console, cmdResourceTypes));
- DCmd_Register("list", WRAP_METHOD(Console, cmdList));
- DCmd_Register("hexgrep", WRAP_METHOD(Console, cmdHexgrep));
- DCmd_Register("verify_scripts", WRAP_METHOD(Console, cmdVerifyScripts));
+ registerCmd("diskdump", WRAP_METHOD(Console, cmdDiskDump));
+ registerCmd("hexdump", WRAP_METHOD(Console, cmdHexDump));
+ registerCmd("resource_id", WRAP_METHOD(Console, cmdResourceId));
+ registerCmd("resource_info", WRAP_METHOD(Console, cmdResourceInfo));
+ registerCmd("resource_types", WRAP_METHOD(Console, cmdResourceTypes));
+ registerCmd("list", WRAP_METHOD(Console, cmdList));
+ registerCmd("hexgrep", WRAP_METHOD(Console, cmdHexgrep));
+ registerCmd("verify_scripts", WRAP_METHOD(Console, cmdVerifyScripts));
// Game
- DCmd_Register("save_game", WRAP_METHOD(Console, cmdSaveGame));
- DCmd_Register("restore_game", WRAP_METHOD(Console, cmdRestoreGame));
- DCmd_Register("restart_game", WRAP_METHOD(Console, cmdRestartGame));
- DCmd_Register("version", WRAP_METHOD(Console, cmdGetVersion));
- DCmd_Register("room", WRAP_METHOD(Console, cmdRoomNumber));
- DCmd_Register("quit", WRAP_METHOD(Console, cmdQuit));
- DCmd_Register("list_saves", WRAP_METHOD(Console, cmdListSaves));
+ registerCmd("save_game", WRAP_METHOD(Console, cmdSaveGame));
+ registerCmd("restore_game", WRAP_METHOD(Console, cmdRestoreGame));
+ registerCmd("restart_game", WRAP_METHOD(Console, cmdRestartGame));
+ registerCmd("version", WRAP_METHOD(Console, cmdGetVersion));
+ registerCmd("room", WRAP_METHOD(Console, cmdRoomNumber));
+ registerCmd("quit", WRAP_METHOD(Console, cmdQuit));
+ registerCmd("list_saves", WRAP_METHOD(Console, cmdListSaves));
// Graphics
- DCmd_Register("show_map", WRAP_METHOD(Console, cmdShowMap));
- DCmd_Register("set_palette", WRAP_METHOD(Console, cmdSetPalette));
- DCmd_Register("draw_pic", WRAP_METHOD(Console, cmdDrawPic));
- DCmd_Register("draw_cel", WRAP_METHOD(Console, cmdDrawCel));
- DCmd_Register("undither", WRAP_METHOD(Console, cmdUndither));
- DCmd_Register("pic_visualize", WRAP_METHOD(Console, cmdPicVisualize));
- DCmd_Register("play_video", WRAP_METHOD(Console, cmdPlayVideo));
- DCmd_Register("animate_list", WRAP_METHOD(Console, cmdAnimateList));
- DCmd_Register("al", WRAP_METHOD(Console, cmdAnimateList)); // alias
- DCmd_Register("window_list", WRAP_METHOD(Console, cmdWindowList));
- DCmd_Register("wl", WRAP_METHOD(Console, cmdWindowList)); // alias
- DCmd_Register("plane_list", WRAP_METHOD(Console, cmdPlaneList));
- DCmd_Register("pl", WRAP_METHOD(Console, cmdPlaneList)); // alias
- DCmd_Register("plane_items", WRAP_METHOD(Console, cmdPlaneItemList));
- DCmd_Register("pi", WRAP_METHOD(Console, cmdPlaneItemList)); // alias
- DCmd_Register("saved_bits", WRAP_METHOD(Console, cmdSavedBits));
- DCmd_Register("show_saved_bits", WRAP_METHOD(Console, cmdShowSavedBits));
+ registerCmd("show_map", WRAP_METHOD(Console, cmdShowMap));
+ registerCmd("set_palette", WRAP_METHOD(Console, cmdSetPalette));
+ registerCmd("draw_pic", WRAP_METHOD(Console, cmdDrawPic));
+ registerCmd("draw_cel", WRAP_METHOD(Console, cmdDrawCel));
+ registerCmd("undither", WRAP_METHOD(Console, cmdUndither));
+ registerCmd("pic_visualize", WRAP_METHOD(Console, cmdPicVisualize));
+ registerCmd("play_video", WRAP_METHOD(Console, cmdPlayVideo));
+ registerCmd("animate_list", WRAP_METHOD(Console, cmdAnimateList));
+ registerCmd("al", WRAP_METHOD(Console, cmdAnimateList)); // alias
+ registerCmd("window_list", WRAP_METHOD(Console, cmdWindowList));
+ registerCmd("wl", WRAP_METHOD(Console, cmdWindowList)); // alias
+ registerCmd("plane_list", WRAP_METHOD(Console, cmdPlaneList));
+ registerCmd("pl", WRAP_METHOD(Console, cmdPlaneList)); // alias
+ registerCmd("plane_items", WRAP_METHOD(Console, cmdPlaneItemList));
+ registerCmd("pi", WRAP_METHOD(Console, cmdPlaneItemList)); // alias
+ registerCmd("saved_bits", WRAP_METHOD(Console, cmdSavedBits));
+ registerCmd("show_saved_bits", WRAP_METHOD(Console, cmdShowSavedBits));
// Segments
- DCmd_Register("segment_table", WRAP_METHOD(Console, cmdPrintSegmentTable));
- DCmd_Register("segtable", WRAP_METHOD(Console, cmdPrintSegmentTable)); // alias
- DCmd_Register("segment_info", WRAP_METHOD(Console, cmdSegmentInfo));
- DCmd_Register("seginfo", WRAP_METHOD(Console, cmdSegmentInfo)); // alias
- DCmd_Register("segment_kill", WRAP_METHOD(Console, cmdKillSegment));
- DCmd_Register("segkill", WRAP_METHOD(Console, cmdKillSegment)); // alias
+ registerCmd("segment_table", WRAP_METHOD(Console, cmdPrintSegmentTable));
+ registerCmd("segtable", WRAP_METHOD(Console, cmdPrintSegmentTable)); // alias
+ registerCmd("segment_info", WRAP_METHOD(Console, cmdSegmentInfo));
+ registerCmd("seginfo", WRAP_METHOD(Console, cmdSegmentInfo)); // alias
+ registerCmd("segment_kill", WRAP_METHOD(Console, cmdKillSegment));
+ registerCmd("segkill", WRAP_METHOD(Console, cmdKillSegment)); // alias
// Garbage collection
- DCmd_Register("gc", WRAP_METHOD(Console, cmdGCInvoke));
- DCmd_Register("gc_objects", WRAP_METHOD(Console, cmdGCObjects));
- DCmd_Register("gc_reachable", WRAP_METHOD(Console, cmdGCShowReachable));
- DCmd_Register("gc_freeable", WRAP_METHOD(Console, cmdGCShowFreeable));
- DCmd_Register("gc_normalize", WRAP_METHOD(Console, cmdGCNormalize));
+ registerCmd("gc", WRAP_METHOD(Console, cmdGCInvoke));
+ registerCmd("gc_objects", WRAP_METHOD(Console, cmdGCObjects));
+ registerCmd("gc_reachable", WRAP_METHOD(Console, cmdGCShowReachable));
+ registerCmd("gc_freeable", WRAP_METHOD(Console, cmdGCShowFreeable));
+ registerCmd("gc_normalize", WRAP_METHOD(Console, cmdGCNormalize));
// Music/SFX
- DCmd_Register("songlib", WRAP_METHOD(Console, cmdSongLib));
- DCmd_Register("songinfo", WRAP_METHOD(Console, cmdSongInfo));
- DCmd_Register("is_sample", WRAP_METHOD(Console, cmdIsSample));
- DCmd_Register("startsound", WRAP_METHOD(Console, cmdStartSound));
- DCmd_Register("togglesound", WRAP_METHOD(Console, cmdToggleSound));
- DCmd_Register("stopallsounds", WRAP_METHOD(Console, cmdStopAllSounds));
- DCmd_Register("sfx01_header", WRAP_METHOD(Console, cmdSfx01Header));
- DCmd_Register("sfx01_track", WRAP_METHOD(Console, cmdSfx01Track));
- DCmd_Register("show_instruments", WRAP_METHOD(Console, cmdShowInstruments));
- DCmd_Register("map_instrument", WRAP_METHOD(Console, cmdMapInstrument));
+ registerCmd("songlib", WRAP_METHOD(Console, cmdSongLib));
+ registerCmd("songinfo", WRAP_METHOD(Console, cmdSongInfo));
+ registerCmd("is_sample", WRAP_METHOD(Console, cmdIsSample));
+ registerCmd("startsound", WRAP_METHOD(Console, cmdStartSound));
+ registerCmd("togglesound", WRAP_METHOD(Console, cmdToggleSound));
+ registerCmd("stopallsounds", WRAP_METHOD(Console, cmdStopAllSounds));
+ registerCmd("sfx01_header", WRAP_METHOD(Console, cmdSfx01Header));
+ registerCmd("sfx01_track", WRAP_METHOD(Console, cmdSfx01Track));
+ registerCmd("show_instruments", WRAP_METHOD(Console, cmdShowInstruments));
+ registerCmd("map_instrument", WRAP_METHOD(Console, cmdMapInstrument));
// Script
- DCmd_Register("addresses", WRAP_METHOD(Console, cmdAddresses));
- DCmd_Register("registers", WRAP_METHOD(Console, cmdRegisters));
- DCmd_Register("dissect_script", WRAP_METHOD(Console, cmdDissectScript));
- DCmd_Register("backtrace", WRAP_METHOD(Console, cmdBacktrace));
- DCmd_Register("bt", WRAP_METHOD(Console, cmdBacktrace)); // alias
- DCmd_Register("trace", WRAP_METHOD(Console, cmdTrace));
- DCmd_Register("t", WRAP_METHOD(Console, cmdTrace)); // alias
- DCmd_Register("s", WRAP_METHOD(Console, cmdTrace)); // alias
- DCmd_Register("stepover", WRAP_METHOD(Console, cmdStepOver));
- DCmd_Register("p", WRAP_METHOD(Console, cmdStepOver)); // alias
- DCmd_Register("step_ret", WRAP_METHOD(Console, cmdStepRet));
- DCmd_Register("pret", WRAP_METHOD(Console, cmdStepRet)); // alias
- DCmd_Register("step_event", WRAP_METHOD(Console, cmdStepEvent));
- DCmd_Register("se", WRAP_METHOD(Console, cmdStepEvent)); // alias
- DCmd_Register("step_global", WRAP_METHOD(Console, cmdStepGlobal));
- DCmd_Register("sg", WRAP_METHOD(Console, cmdStepGlobal)); // alias
- DCmd_Register("step_callk", WRAP_METHOD(Console, cmdStepCallk));
- DCmd_Register("snk", WRAP_METHOD(Console, cmdStepCallk)); // alias
- DCmd_Register("disasm", WRAP_METHOD(Console, cmdDisassemble));
- DCmd_Register("disasm_addr", WRAP_METHOD(Console, cmdDisassembleAddress));
- DCmd_Register("find_callk", WRAP_METHOD(Console, cmdFindKernelFunctionCall));
- DCmd_Register("send", WRAP_METHOD(Console, cmdSend));
- DCmd_Register("go", WRAP_METHOD(Console, cmdGo));
- DCmd_Register("logkernel", WRAP_METHOD(Console, cmdLogKernel));
+ registerCmd("addresses", WRAP_METHOD(Console, cmdAddresses));
+ registerCmd("registers", WRAP_METHOD(Console, cmdRegisters));
+ registerCmd("dissect_script", WRAP_METHOD(Console, cmdDissectScript));
+ registerCmd("backtrace", WRAP_METHOD(Console, cmdBacktrace));
+ registerCmd("bt", WRAP_METHOD(Console, cmdBacktrace)); // alias
+ registerCmd("trace", WRAP_METHOD(Console, cmdTrace));
+ registerCmd("t", WRAP_METHOD(Console, cmdTrace)); // alias
+ registerCmd("s", WRAP_METHOD(Console, cmdTrace)); // alias
+ registerCmd("stepover", WRAP_METHOD(Console, cmdStepOver));
+ registerCmd("p", WRAP_METHOD(Console, cmdStepOver)); // alias
+ registerCmd("step_ret", WRAP_METHOD(Console, cmdStepRet));
+ registerCmd("pret", WRAP_METHOD(Console, cmdStepRet)); // alias
+ registerCmd("step_event", WRAP_METHOD(Console, cmdStepEvent));
+ registerCmd("se", WRAP_METHOD(Console, cmdStepEvent)); // alias
+ registerCmd("step_global", WRAP_METHOD(Console, cmdStepGlobal));
+ registerCmd("sg", WRAP_METHOD(Console, cmdStepGlobal)); // alias
+ registerCmd("step_callk", WRAP_METHOD(Console, cmdStepCallk));
+ registerCmd("snk", WRAP_METHOD(Console, cmdStepCallk)); // alias
+ registerCmd("disasm", WRAP_METHOD(Console, cmdDisassemble));
+ registerCmd("disasm_addr", WRAP_METHOD(Console, cmdDisassembleAddress));
+ registerCmd("find_callk", WRAP_METHOD(Console, cmdFindKernelFunctionCall));
+ registerCmd("send", WRAP_METHOD(Console, cmdSend));
+ registerCmd("go", WRAP_METHOD(Console, cmdGo));
+ registerCmd("logkernel", WRAP_METHOD(Console, cmdLogKernel));
// Breakpoints
- DCmd_Register("bp_list", WRAP_METHOD(Console, cmdBreakpointList));
- DCmd_Register("bplist", WRAP_METHOD(Console, cmdBreakpointList)); // alias
- DCmd_Register("bl", WRAP_METHOD(Console, cmdBreakpointList)); // alias
- DCmd_Register("bp_del", WRAP_METHOD(Console, cmdBreakpointDelete));
- DCmd_Register("bpdel", WRAP_METHOD(Console, cmdBreakpointDelete)); // alias
- DCmd_Register("bc", WRAP_METHOD(Console, cmdBreakpointDelete)); // alias
- DCmd_Register("bp_method", WRAP_METHOD(Console, cmdBreakpointMethod));
- DCmd_Register("bpx", WRAP_METHOD(Console, cmdBreakpointMethod)); // alias
- DCmd_Register("bp_read", WRAP_METHOD(Console, cmdBreakpointRead));
- DCmd_Register("bpr", WRAP_METHOD(Console, cmdBreakpointRead)); // alias
- DCmd_Register("bp_write", WRAP_METHOD(Console, cmdBreakpointWrite));
- DCmd_Register("bpw", WRAP_METHOD(Console, cmdBreakpointWrite)); // alias
- DCmd_Register("bp_kernel", WRAP_METHOD(Console, cmdBreakpointKernel));
- DCmd_Register("bpk", WRAP_METHOD(Console, cmdBreakpointKernel)); // alias
- DCmd_Register("bp_function", WRAP_METHOD(Console, cmdBreakpointFunction));
- DCmd_Register("bpe", WRAP_METHOD(Console, cmdBreakpointFunction)); // alias
+ registerCmd("bp_list", WRAP_METHOD(Console, cmdBreakpointList));
+ registerCmd("bplist", WRAP_METHOD(Console, cmdBreakpointList)); // alias
+ registerCmd("bl", WRAP_METHOD(Console, cmdBreakpointList)); // alias
+ registerCmd("bp_del", WRAP_METHOD(Console, cmdBreakpointDelete));
+ registerCmd("bpdel", WRAP_METHOD(Console, cmdBreakpointDelete)); // alias
+ registerCmd("bc", WRAP_METHOD(Console, cmdBreakpointDelete)); // alias
+ registerCmd("bp_method", WRAP_METHOD(Console, cmdBreakpointMethod));
+ registerCmd("bpx", WRAP_METHOD(Console, cmdBreakpointMethod)); // alias
+ registerCmd("bp_read", WRAP_METHOD(Console, cmdBreakpointRead));
+ registerCmd("bpr", WRAP_METHOD(Console, cmdBreakpointRead)); // alias
+ registerCmd("bp_write", WRAP_METHOD(Console, cmdBreakpointWrite));
+ registerCmd("bpw", WRAP_METHOD(Console, cmdBreakpointWrite)); // alias
+ registerCmd("bp_kernel", WRAP_METHOD(Console, cmdBreakpointKernel));
+ registerCmd("bpk", WRAP_METHOD(Console, cmdBreakpointKernel)); // alias
+ registerCmd("bp_function", WRAP_METHOD(Console, cmdBreakpointFunction));
+ registerCmd("bpe", WRAP_METHOD(Console, cmdBreakpointFunction)); // alias
// VM
- DCmd_Register("script_steps", WRAP_METHOD(Console, cmdScriptSteps));
- DCmd_Register("vm_varlist", WRAP_METHOD(Console, cmdVMVarlist));
- DCmd_Register("vmvarlist", WRAP_METHOD(Console, cmdVMVarlist)); // alias
- DCmd_Register("vl", WRAP_METHOD(Console, cmdVMVarlist)); // alias
- DCmd_Register("vm_vars", WRAP_METHOD(Console, cmdVMVars));
- DCmd_Register("vmvars", WRAP_METHOD(Console, cmdVMVars)); // alias
- DCmd_Register("vv", WRAP_METHOD(Console, cmdVMVars)); // alias
- DCmd_Register("stack", WRAP_METHOD(Console, cmdStack));
- DCmd_Register("value_type", WRAP_METHOD(Console, cmdValueType));
- DCmd_Register("view_listnode", WRAP_METHOD(Console, cmdViewListNode));
- DCmd_Register("view_reference", WRAP_METHOD(Console, cmdViewReference));
- DCmd_Register("vr", WRAP_METHOD(Console, cmdViewReference)); // alias
- DCmd_Register("view_object", WRAP_METHOD(Console, cmdViewObject));
- DCmd_Register("vo", WRAP_METHOD(Console, cmdViewObject)); // alias
- DCmd_Register("active_object", WRAP_METHOD(Console, cmdViewActiveObject));
- DCmd_Register("acc_object", WRAP_METHOD(Console, cmdViewAccumulatorObject));
+ registerCmd("script_steps", WRAP_METHOD(Console, cmdScriptSteps));
+ registerCmd("vm_varlist", WRAP_METHOD(Console, cmdVMVarlist));
+ registerCmd("vmvarlist", WRAP_METHOD(Console, cmdVMVarlist)); // alias
+ registerCmd("vl", WRAP_METHOD(Console, cmdVMVarlist)); // alias
+ registerCmd("vm_vars", WRAP_METHOD(Console, cmdVMVars));
+ registerCmd("vmvars", WRAP_METHOD(Console, cmdVMVars)); // alias
+ registerCmd("vv", WRAP_METHOD(Console, cmdVMVars)); // alias
+ registerCmd("stack", WRAP_METHOD(Console, cmdStack));
+ registerCmd("value_type", WRAP_METHOD(Console, cmdValueType));
+ registerCmd("view_listnode", WRAP_METHOD(Console, cmdViewListNode));
+ registerCmd("view_reference", WRAP_METHOD(Console, cmdViewReference));
+ registerCmd("vr", WRAP_METHOD(Console, cmdViewReference)); // alias
+ registerCmd("view_object", WRAP_METHOD(Console, cmdViewObject));
+ registerCmd("vo", WRAP_METHOD(Console, cmdViewObject)); // alias
+ registerCmd("active_object", WRAP_METHOD(Console, cmdViewActiveObject));
+ registerCmd("acc_object", WRAP_METHOD(Console, cmdViewAccumulatorObject));
_debugState.seeking = kDebugSeekNothing;
_debugState.seekLevel = 0;
@@ -307,137 +310,137 @@ void Console::postEnter() {
}
bool Console::cmdHelp(int argc, const char **argv) {
- DebugPrintf("\n");
- DebugPrintf("Variables\n");
- DebugPrintf("---------\n");
- DebugPrintf("sleeptime_factor: Factor to multiply with wait times in kWait()\n");
- DebugPrintf("gc_interval: Number of kernel calls in between garbage collections\n");
- DebugPrintf("simulated_key: Add a key with the specified scan code to the event list\n");
- DebugPrintf("track_mouse_clicks: Toggles mouse click tracking to the console\n");
- DebugPrintf("weak_validations: Turns some validation errors into warnings\n");
- DebugPrintf("script_abort_flag: Set to 1 to abort script execution. Set to 2 to force a replay afterwards\n");
- DebugPrintf("\n");
- DebugPrintf("Debug flags\n");
- DebugPrintf("-----------\n");
- DebugPrintf("debugflag_list - Lists the available debug flags and their status\n");
- DebugPrintf("debugflag_enable - Enables a debug flag\n");
- DebugPrintf("debugflag_disable - Disables a debug flag\n");
- DebugPrintf("\n");
- DebugPrintf("Commands\n");
- DebugPrintf("--------\n");
- DebugPrintf("Kernel:\n");
- DebugPrintf(" opcodes - Lists the opcode names\n");
- DebugPrintf(" selectors - Lists the selector names\n");
- DebugPrintf(" selector - Attempts to find the requested selector by name\n");
- DebugPrintf(" functions - Lists the kernel functions\n");
- DebugPrintf(" class_table - Shows the available classes\n");
- DebugPrintf("\n");
- DebugPrintf("Parser:\n");
- DebugPrintf(" suffixes - Lists the vocabulary suffixes\n");
- DebugPrintf(" parse_grammar - Shows the parse grammar, in strict GNF\n");
- DebugPrintf(" parser_nodes - Shows the specified number of nodes from the parse node tree\n");
- DebugPrintf(" parser_words - Shows the words from the parse node tree\n");
- DebugPrintf(" sentence_fragments - Shows the sentence fragments (used to build Parse trees)\n");
- DebugPrintf(" parse - Parses a sequence of words and prints the resulting parse tree\n");
- DebugPrintf(" set_parse_nodes - Sets the contents of all parse nodes\n");
- DebugPrintf(" said - Match a string against a said spec\n");
- DebugPrintf("\n");
- DebugPrintf("Resources:\n");
- DebugPrintf(" diskdump - Dumps the specified resource to disk as a patch file\n");
- DebugPrintf(" hexdump - Dumps the specified resource to standard output\n");
- DebugPrintf(" resource_id - Identifies a resource number by splitting it up in resource type and resource number\n");
- DebugPrintf(" resource_info - Shows info about a resource\n");
- DebugPrintf(" resource_types - Shows the valid resource types\n");
- DebugPrintf(" list - Lists all the resources of a given type\n");
- DebugPrintf(" hexgrep - Searches some resources for a particular sequence of bytes, represented as hexadecimal numbers\n");
- DebugPrintf(" verify_scripts - Performs sanity checks on SCI1.1-SCI2.1 game scripts (e.g. if they're up to 64KB in total)\n");
- DebugPrintf("\n");
- DebugPrintf("Game:\n");
- DebugPrintf(" save_game - Saves the current game state to the hard disk\n");
- DebugPrintf(" restore_game - Restores a saved game from the hard disk\n");
- DebugPrintf(" list_saves - List all saved games including filenames\n");
- DebugPrintf(" restart_game - Restarts the game\n");
- DebugPrintf(" version - Shows the resource and interpreter versions\n");
- DebugPrintf(" room - Gets or sets the current room number\n");
- DebugPrintf(" quit - Quits the game\n");
- DebugPrintf("\n");
- DebugPrintf("Graphics:\n");
- DebugPrintf(" show_map - Switches to visual, priority, control or display screen\n");
- DebugPrintf(" set_palette - Sets a palette resource\n");
- DebugPrintf(" draw_pic - Draws a pic resource\n");
- DebugPrintf(" draw_cel - Draws a cel from a view resource\n");
- DebugPrintf(" pic_visualize - Enables visualization of the drawing process of EGA pictures\n");
- DebugPrintf(" undither - Enable/disable undithering\n");
- DebugPrintf(" play_video - Plays a SEQ, AVI, VMD, RBT or DUK video\n");
- DebugPrintf(" animate_list / al - Shows the current list of objects in kAnimate's draw list (SCI0 - SCI1.1)\n");
- DebugPrintf(" window_list / wl - Shows a list of all the windows (ports) in the draw list (SCI0 - SCI1.1)\n");
- DebugPrintf(" plane_list / pl - Shows a list of all the planes in the draw list (SCI2+)\n");
- DebugPrintf(" plane_items / pi - Shows a list of all items for a plane (SCI2+)\n");
- DebugPrintf(" saved_bits - List saved bits on the hunk\n");
- DebugPrintf(" show_saved_bits - Display saved bits\n");
- DebugPrintf("\n");
- DebugPrintf("Segments:\n");
- DebugPrintf(" segment_table / segtable - Lists all segments\n");
- DebugPrintf(" segment_info / seginfo - Provides information on the specified segment\n");
- DebugPrintf(" segment_kill / segkill - Deletes the specified segment\n");
- DebugPrintf("\n");
- DebugPrintf("Garbage collection:\n");
- DebugPrintf(" gc - Invokes the garbage collector\n");
- DebugPrintf(" gc_objects - Lists all reachable objects, normalized\n");
- DebugPrintf(" gc_reachable - Lists all addresses directly reachable from a given memory object\n");
- DebugPrintf(" gc_freeable - Lists all addresses freeable in a given segment\n");
- DebugPrintf(" gc_normalize - Prints the \"normal\" address of a given address\n");
- DebugPrintf("\n");
- DebugPrintf("Music/SFX:\n");
- DebugPrintf(" songlib - Shows the song library\n");
- DebugPrintf(" songinfo - Shows information about a specified song in the song library\n");
- DebugPrintf(" togglesound - Starts/stops a sound in the song library\n");
- DebugPrintf(" stopallsounds - Stops all sounds in the playlist\n");
- DebugPrintf(" startsound - Starts the specified sound resource, replacing the first song in the song library\n");
- DebugPrintf(" is_sample - Shows information on a given sound resource, if it's a PCM sample\n");
- DebugPrintf(" sfx01_header - Dumps the header of a SCI01 song\n");
- DebugPrintf(" sfx01_track - Dumps a track of a SCI01 song\n");
- DebugPrintf(" show_instruments - Shows the instruments of a specific song, or all songs\n");
- DebugPrintf(" map_instrument - Dynamically maps an MT-32 instrument to a GM instrument\n");
- DebugPrintf("\n");
- DebugPrintf("Script:\n");
- DebugPrintf(" addresses - Provides information on how to pass addresses\n");
- DebugPrintf(" registers - Shows the current register values\n");
- DebugPrintf(" dissect_script - Examines a script\n");
- DebugPrintf(" backtrace / bt - Dumps the send/self/super/call/calle/callb stack\n");
- DebugPrintf(" trace / t / s - Executes one operation (no parameters) or several operations (specified as a parameter) \n");
- DebugPrintf(" stepover / p - Executes one operation, skips over call/send\n");
- DebugPrintf(" step_ret / pret - Steps forward until ret is called on the current execution stack level.\n");
- DebugPrintf(" step_event / se - Steps forward until a SCI event is received.\n");
- DebugPrintf(" step_global / sg - Steps until the global variable with the specified index is modified.\n");
- DebugPrintf(" step_callk / snk - Steps forward until it hits the next callk operation, or a specific callk (specified as a parameter)\n");
- DebugPrintf(" disasm - Disassembles a method by name\n");
- DebugPrintf(" disasm_addr - Disassembles one or more commands\n");
- DebugPrintf(" send - Sends a message to an object\n");
- DebugPrintf(" go - Executes the script\n");
- DebugPrintf(" logkernel - Logs kernel calls\n");
- DebugPrintf("\n");
- DebugPrintf("Breakpoints:\n");
- DebugPrintf(" bp_list / bplist / bl - Lists the current breakpoints\n");
- DebugPrintf(" bp_del / bpdel / bc - Deletes a breakpoint with the specified index\n");
- DebugPrintf(" bp_method / bpx - Sets a breakpoint on the execution of a specified method/selector\n");
- DebugPrintf(" bp_read / bpr - Sets a breakpoint on reading of a specified selector\n");
- DebugPrintf(" bp_write / bpw - Sets a breakpoint on writing to a specified selector\n");
- DebugPrintf(" bp_kernel / bpk - Sets a breakpoint on execution of a kernel function\n");
- DebugPrintf(" bp_function / bpe - Sets a breakpoint on the execution of the specified exported function\n");
- DebugPrintf("\n");
- DebugPrintf("VM:\n");
- DebugPrintf(" script_steps - Shows the number of executed SCI operations\n");
- DebugPrintf(" vm_varlist / vmvarlist / vl - Shows the addresses of variables in the VM\n");
- DebugPrintf(" vm_vars / vmvars / vv - Displays or changes variables in the VM\n");
- DebugPrintf(" stack - Lists the specified number of stack elements\n");
- DebugPrintf(" value_type - Determines the type of a value\n");
- DebugPrintf(" view_listnode - Examines the list node at the given address\n");
- DebugPrintf(" view_reference / vr - Examines an arbitrary reference\n");
- DebugPrintf(" view_object / vo - Examines the object at the given address\n");
- DebugPrintf(" active_object - Shows information on the currently active object or class\n");
- DebugPrintf(" acc_object - Shows information on the object or class at the address indexed by the accumulator\n");
- DebugPrintf("\n");
+ debugPrintf("\n");
+ debugPrintf("Variables\n");
+ debugPrintf("---------\n");
+ debugPrintf("sleeptime_factor: Factor to multiply with wait times in kWait()\n");
+ debugPrintf("gc_interval: Number of kernel calls in between garbage collections\n");
+ debugPrintf("simulated_key: Add a key with the specified scan code to the event list\n");
+ debugPrintf("track_mouse_clicks: Toggles mouse click tracking to the console\n");
+ debugPrintf("weak_validations: Turns some validation errors into warnings\n");
+ debugPrintf("script_abort_flag: Set to 1 to abort script execution. Set to 2 to force a replay afterwards\n");
+ debugPrintf("\n");
+ debugPrintf("Debug flags\n");
+ debugPrintf("-----------\n");
+ debugPrintf("debugflag_list - Lists the available debug flags and their status\n");
+ debugPrintf("debugflag_enable - Enables a debug flag\n");
+ debugPrintf("debugflag_disable - Disables a debug flag\n");
+ debugPrintf("\n");
+ debugPrintf("Commands\n");
+ debugPrintf("--------\n");
+ debugPrintf("Kernel:\n");
+ debugPrintf(" opcodes - Lists the opcode names\n");
+ debugPrintf(" selectors - Lists the selector names\n");
+ debugPrintf(" selector - Attempts to find the requested selector by name\n");
+ debugPrintf(" functions - Lists the kernel functions\n");
+ debugPrintf(" class_table - Shows the available classes\n");
+ debugPrintf("\n");
+ debugPrintf("Parser:\n");
+ debugPrintf(" suffixes - Lists the vocabulary suffixes\n");
+ debugPrintf(" parse_grammar - Shows the parse grammar, in strict GNF\n");
+ debugPrintf(" parser_nodes - Shows the specified number of nodes from the parse node tree\n");
+ debugPrintf(" parser_words - Shows the words from the parse node tree\n");
+ debugPrintf(" sentence_fragments - Shows the sentence fragments (used to build Parse trees)\n");
+ debugPrintf(" parse - Parses a sequence of words and prints the resulting parse tree\n");
+ debugPrintf(" set_parse_nodes - Sets the contents of all parse nodes\n");
+ debugPrintf(" said - Match a string against a said spec\n");
+ debugPrintf("\n");
+ debugPrintf("Resources:\n");
+ debugPrintf(" diskdump - Dumps the specified resource to disk as a patch file\n");
+ debugPrintf(" hexdump - Dumps the specified resource to standard output\n");
+ debugPrintf(" resource_id - Identifies a resource number by splitting it up in resource type and resource number\n");
+ debugPrintf(" resource_info - Shows info about a resource\n");
+ debugPrintf(" resource_types - Shows the valid resource types\n");
+ debugPrintf(" list - Lists all the resources of a given type\n");
+ debugPrintf(" hexgrep - Searches some resources for a particular sequence of bytes, represented as hexadecimal numbers\n");
+ debugPrintf(" verify_scripts - Performs sanity checks on SCI1.1-SCI2.1 game scripts (e.g. if they're up to 64KB in total)\n");
+ debugPrintf("\n");
+ debugPrintf("Game:\n");
+ debugPrintf(" save_game - Saves the current game state to the hard disk\n");
+ debugPrintf(" restore_game - Restores a saved game from the hard disk\n");
+ debugPrintf(" list_saves - List all saved games including filenames\n");
+ debugPrintf(" restart_game - Restarts the game\n");
+ debugPrintf(" version - Shows the resource and interpreter versions\n");
+ debugPrintf(" room - Gets or sets the current room number\n");
+ debugPrintf(" quit - Quits the game\n");
+ debugPrintf("\n");
+ debugPrintf("Graphics:\n");
+ debugPrintf(" show_map - Switches to visual, priority, control or display screen\n");
+ debugPrintf(" set_palette - Sets a palette resource\n");
+ debugPrintf(" draw_pic - Draws a pic resource\n");
+ debugPrintf(" draw_cel - Draws a cel from a view resource\n");
+ debugPrintf(" pic_visualize - Enables visualization of the drawing process of EGA pictures\n");
+ debugPrintf(" undither - Enable/disable undithering\n");
+ debugPrintf(" play_video - Plays a SEQ, AVI, VMD, RBT or DUK video\n");
+ debugPrintf(" animate_list / al - Shows the current list of objects in kAnimate's draw list (SCI0 - SCI1.1)\n");
+ debugPrintf(" window_list / wl - Shows a list of all the windows (ports) in the draw list (SCI0 - SCI1.1)\n");
+ debugPrintf(" plane_list / pl - Shows a list of all the planes in the draw list (SCI2+)\n");
+ debugPrintf(" plane_items / pi - Shows a list of all items for a plane (SCI2+)\n");
+ debugPrintf(" saved_bits - List saved bits on the hunk\n");
+ debugPrintf(" show_saved_bits - Display saved bits\n");
+ debugPrintf("\n");
+ debugPrintf("Segments:\n");
+ debugPrintf(" segment_table / segtable - Lists all segments\n");
+ debugPrintf(" segment_info / seginfo - Provides information on the specified segment\n");
+ debugPrintf(" segment_kill / segkill - Deletes the specified segment\n");
+ debugPrintf("\n");
+ debugPrintf("Garbage collection:\n");
+ debugPrintf(" gc - Invokes the garbage collector\n");
+ debugPrintf(" gc_objects - Lists all reachable objects, normalized\n");
+ debugPrintf(" gc_reachable - Lists all addresses directly reachable from a given memory object\n");
+ debugPrintf(" gc_freeable - Lists all addresses freeable in a given segment\n");
+ debugPrintf(" gc_normalize - Prints the \"normal\" address of a given address\n");
+ debugPrintf("\n");
+ debugPrintf("Music/SFX:\n");
+ debugPrintf(" songlib - Shows the song library\n");
+ debugPrintf(" songinfo - Shows information about a specified song in the song library\n");
+ debugPrintf(" togglesound - Starts/stops a sound in the song library\n");
+ debugPrintf(" stopallsounds - Stops all sounds in the playlist\n");
+ debugPrintf(" startsound - Starts the specified sound resource, replacing the first song in the song library\n");
+ debugPrintf(" is_sample - Shows information on a given sound resource, if it's a PCM sample\n");
+ debugPrintf(" sfx01_header - Dumps the header of a SCI01 song\n");
+ debugPrintf(" sfx01_track - Dumps a track of a SCI01 song\n");
+ debugPrintf(" show_instruments - Shows the instruments of a specific song, or all songs\n");
+ debugPrintf(" map_instrument - Dynamically maps an MT-32 instrument to a GM instrument\n");
+ debugPrintf("\n");
+ debugPrintf("Script:\n");
+ debugPrintf(" addresses - Provides information on how to pass addresses\n");
+ debugPrintf(" registers - Shows the current register values\n");
+ debugPrintf(" dissect_script - Examines a script\n");
+ debugPrintf(" backtrace / bt - Dumps the send/self/super/call/calle/callb stack\n");
+ debugPrintf(" trace / t / s - Executes one operation (no parameters) or several operations (specified as a parameter) \n");
+ debugPrintf(" stepover / p - Executes one operation, skips over call/send\n");
+ debugPrintf(" step_ret / pret - Steps forward until ret is called on the current execution stack level.\n");
+ debugPrintf(" step_event / se - Steps forward until a SCI event is received.\n");
+ debugPrintf(" step_global / sg - Steps until the global variable with the specified index is modified.\n");
+ debugPrintf(" step_callk / snk - Steps forward until it hits the next callk operation, or a specific callk (specified as a parameter)\n");
+ debugPrintf(" disasm - Disassembles a method by name\n");
+ debugPrintf(" disasm_addr - Disassembles one or more commands\n");
+ debugPrintf(" send - Sends a message to an object\n");
+ debugPrintf(" go - Executes the script\n");
+ debugPrintf(" logkernel - Logs kernel calls\n");
+ debugPrintf("\n");
+ debugPrintf("Breakpoints:\n");
+ debugPrintf(" bp_list / bplist / bl - Lists the current breakpoints\n");
+ debugPrintf(" bp_del / bpdel / bc - Deletes a breakpoint with the specified index\n");
+ debugPrintf(" bp_method / bpx - Sets a breakpoint on the execution of a specified method/selector\n");
+ debugPrintf(" bp_read / bpr - Sets a breakpoint on reading of a specified selector\n");
+ debugPrintf(" bp_write / bpw - Sets a breakpoint on writing to a specified selector\n");
+ debugPrintf(" bp_kernel / bpk - Sets a breakpoint on execution of a kernel function\n");
+ debugPrintf(" bp_function / bpe - Sets a breakpoint on the execution of the specified exported function\n");
+ debugPrintf("\n");
+ debugPrintf("VM:\n");
+ debugPrintf(" script_steps - Shows the number of executed SCI operations\n");
+ debugPrintf(" vm_varlist / vmvarlist / vl - Shows the addresses of variables in the VM\n");
+ debugPrintf(" vm_vars / vmvars / vv - Displays or changes variables in the VM\n");
+ debugPrintf(" stack - Lists the specified number of stack elements\n");
+ debugPrintf(" value_type - Determines the type of a value\n");
+ debugPrintf(" view_listnode - Examines the list node at the given address\n");
+ debugPrintf(" view_reference / vr - Examines an arbitrary reference\n");
+ debugPrintf(" view_object / vo - Examines the object at the given address\n");
+ debugPrintf(" active_object - Shows information on the currently active object or class\n");
+ debugPrintf(" acc_object - Shows information on the object or class at the address indexed by the accumulator\n");
+ debugPrintf("\n");
return true;
}
@@ -464,30 +467,30 @@ bool Console::cmdGetVersion(int argc, const char **argv) {
versionFile.close();
}
- DebugPrintf("Game ID: %s\n", _engine->getGameIdStr());
- DebugPrintf("Emulated interpreter version: %s\n", getSciVersionDesc(getSciVersion()));
- DebugPrintf("\n");
- DebugPrintf("Detected features:\n");
- DebugPrintf("------------------\n");
- DebugPrintf("Sound type: %s\n", getSciVersionDesc(_engine->_features->detectDoSoundType()));
- DebugPrintf("Graphics functions type: %s\n", getSciVersionDesc(_engine->_features->detectGfxFunctionsType()));
- DebugPrintf("Lofs type: %s\n", getSciVersionDesc(_engine->_features->detectLofsType()));
- DebugPrintf("Move count type: %s\n", (_engine->_features->handleMoveCount()) ? "increment" : "ignore");
- DebugPrintf("SetCursor type: %s\n", getSciVersionDesc(_engine->_features->detectSetCursorType()));
+ debugPrintf("Game ID: %s\n", _engine->getGameIdStr());
+ debugPrintf("Emulated interpreter version: %s\n", getSciVersionDesc(getSciVersion()));
+ debugPrintf("\n");
+ debugPrintf("Detected features:\n");
+ debugPrintf("------------------\n");
+ debugPrintf("Sound type: %s\n", getSciVersionDesc(_engine->_features->detectDoSoundType()));
+ debugPrintf("Graphics functions type: %s\n", getSciVersionDesc(_engine->_features->detectGfxFunctionsType()));
+ debugPrintf("Lofs type: %s\n", getSciVersionDesc(_engine->_features->detectLofsType()));
+ debugPrintf("Move count type: %s\n", (_engine->_features->handleMoveCount()) ? "increment" : "ignore");
+ debugPrintf("SetCursor type: %s\n", getSciVersionDesc(_engine->_features->detectSetCursorType()));
#ifdef ENABLE_SCI32
if (getSciVersion() >= SCI_VERSION_2)
- DebugPrintf("kString type: %s\n", (_engine->_features->detectSci2StringFunctionType() == kSci2StringFunctionOld) ? "SCI2 (old)" : "SCI2.1 (new)");
+ debugPrintf("kString type: %s\n", (_engine->_features->detectSci2StringFunctionType() == kSci2StringFunctionOld) ? "SCI2 (old)" : "SCI2.1 (new)");
if (getSciVersion() == SCI_VERSION_2_1)
- DebugPrintf("SCI2.1 kernel table: %s\n", (_engine->_features->detectSci21KernelType() == SCI_VERSION_2) ? "modified SCI2 (old)" : "SCI2.1 (new)");
+ debugPrintf("SCI2.1 kernel table: %s\n", (_engine->_features->detectSci21KernelType() == SCI_VERSION_2) ? "modified SCI2 (old)" : "SCI2.1 (new)");
#endif
- DebugPrintf("View type: %s\n", viewTypeDesc[g_sci->getResMan()->getViewType()]);
- DebugPrintf("Uses palette merging: %s\n", g_sci->_gfxPalette->isMerging() ? "yes" : "no");
- DebugPrintf("Resource volume version: %s\n", g_sci->getResMan()->getVolVersionDesc());
- DebugPrintf("Resource map version: %s\n", g_sci->getResMan()->getMapVersionDesc());
- DebugPrintf("Contains selector vocabulary (vocab.997): %s\n", hasVocab997 ? "yes" : "no");
- DebugPrintf("Has CantBeHere selector: %s\n", g_sci->getKernel()->_selectorCache.cantBeHere != -1 ? "yes" : "no");
- DebugPrintf("Game version (VERSION file): %s\n", gameVersion.c_str());
- DebugPrintf("\n");
+ debugPrintf("View type: %s\n", viewTypeDesc[g_sci->getResMan()->getViewType()]);
+ debugPrintf("Uses palette merging: %s\n", g_sci->_gfxPalette->isMerging() ? "yes" : "no");
+ debugPrintf("Resource volume version: %s\n", g_sci->getResMan()->getVolVersionDesc());
+ debugPrintf("Resource map version: %s\n", g_sci->getResMan()->getMapVersionDesc());
+ debugPrintf("Contains selector vocabulary (vocab.997): %s\n", hasVocab997 ? "yes" : "no");
+ debugPrintf("Has CantBeHere selector: %s\n", g_sci->getKernel()->_selectorCache.cantBeHere != -1 ? "yes" : "no");
+ debugPrintf("Game version (VERSION file): %s\n", gameVersion.c_str());
+ debugPrintf("\n");
return true;
}
@@ -498,13 +501,13 @@ bool Console::cmdOpcodes(int argc, const char **argv) {
// If the resource couldn't be loaded, leave
if (!r) {
- DebugPrintf("unable to load vocab.998");
+ debugPrintf("unable to load vocab.998");
return true;
}
int count = READ_LE_UINT16(r->data);
- DebugPrintf("Opcode names in numeric order [index: type name]:\n");
+ debugPrintf("Opcode names in numeric order [index: type name]:\n");
for (int i = 0; i < count; i++) {
int offset = READ_LE_UINT16(r->data + 2 + i * 2);
@@ -512,49 +515,49 @@ bool Console::cmdOpcodes(int argc, const char **argv) {
int type = READ_LE_UINT16(r->data + offset + 2);
// QFG3 has empty opcodes
Common::String name = len > 0 ? Common::String((const char *)r->data + offset + 4, len) : "Dummy";
- DebugPrintf("%03x: %03x %20s | ", i, type, name.c_str());
+ debugPrintf("%03x: %03x %20s | ", i, type, name.c_str());
if ((i % 3) == 2)
- DebugPrintf("\n");
+ debugPrintf("\n");
}
- DebugPrintf("\n");
+ debugPrintf("\n");
return true;
}
bool Console::cmdSelector(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Attempts to find the requested selector by name.\n");
- DebugPrintf("Usage: %s <selector name>\n", argv[0]);
+ debugPrintf("Attempts to find the requested selector by name.\n");
+ debugPrintf("Usage: %s <selector name>\n", argv[0]);
return true;
}
Common::String name = argv[1];
int seeker = _engine->getKernel()->findSelector(name.c_str());
if (seeker >= 0) {
- DebugPrintf("Selector %s found at %03x (%d)\n", name.c_str(), seeker, seeker);
+ debugPrintf("Selector %s found at %03x (%d)\n", name.c_str(), seeker, seeker);
return true;
}
- DebugPrintf("Selector %s wasn't found\n", name.c_str());
+ debugPrintf("Selector %s wasn't found\n", name.c_str());
return true;
}
bool Console::cmdSelectors(int argc, const char **argv) {
- DebugPrintf("Selector names in numeric order:\n");
+ debugPrintf("Selector names in numeric order:\n");
Common::String selectorName;
for (uint seeker = 0; seeker < _engine->getKernel()->getSelectorNamesSize(); seeker++) {
selectorName = _engine->getKernel()->getSelectorName(seeker);
if (selectorName != "BAD SELECTOR")
- DebugPrintf("%03x: %20s | ", seeker, selectorName.c_str());
+ debugPrintf("%03x: %20s | ", seeker, selectorName.c_str());
else
continue;
if ((seeker % 3) == 2)
- DebugPrintf("\n");
+ debugPrintf("\n");
}
- DebugPrintf("\n");
+ debugPrintf("\n");
#if 0
// For debug/development
@@ -584,14 +587,14 @@ bool Console::cmdSelectors(int argc, const char **argv) {
}
bool Console::cmdKernelFunctions(int argc, const char **argv) {
- DebugPrintf("Kernel function names in numeric order:\n");
+ debugPrintf("Kernel function names in numeric order:\n");
for (uint seeker = 0; seeker < _engine->getKernel()->getKernelNamesSize(); seeker++) {
- DebugPrintf("%03x: %20s | ", seeker, _engine->getKernel()->getKernelName(seeker).c_str());
+ debugPrintf("%03x: %20s | ", seeker, _engine->getKernel()->getKernelName(seeker).c_str());
if ((seeker % 3) == 2)
- DebugPrintf("\n");
+ debugPrintf("\n");
}
- DebugPrintf("\n");
+ debugPrintf("\n");
return true;
}
@@ -610,9 +613,9 @@ bool Console::cmdParserWords(int argc, const char **argv) {
bool Console::cmdSetParseNodes(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Sets the contents of all parse nodes.\n");
- DebugPrintf("Usage: %s <parse node1> <parse node2> ... <parse noden>\n", argv[0]);
- DebugPrintf("Tokens should be separated by blanks and enclosed in parentheses\n");
+ debugPrintf("Sets the contents of all parse nodes.\n");
+ debugPrintf("Usage: %s <parse node1> <parse node2> ... <parse noden>\n", argv[0]);
+ debugPrintf("Tokens should be separated by blanks and enclosed in parentheses\n");
return true;
}
@@ -643,46 +646,62 @@ bool Console::cmdSetParseNodes(int argc, const char **argv) {
bool Console::cmdRegisters(int argc, const char **argv) {
EngineState *s = _engine->_gamestate;
- DebugPrintf("Current register values:\n");
- DebugPrintf("acc=%04x:%04x prev=%04x:%04x &rest=%x\n", PRINT_REG(s->r_acc), PRINT_REG(s->r_prev), s->r_rest);
+ debugPrintf("Current register values:\n");
+ debugPrintf("acc=%04x:%04x prev=%04x:%04x &rest=%x\n", PRINT_REG(s->r_acc), PRINT_REG(s->r_prev), s->r_rest);
if (!s->_executionStack.empty()) {
- DebugPrintf("pc=%04x:%04x obj=%04x:%04x fp=ST:%04x sp=ST:%04x\n",
+ debugPrintf("pc=%04x:%04x obj=%04x:%04x fp=ST:%04x sp=ST:%04x\n",
PRINT_REG(s->xs->addr.pc), PRINT_REG(s->xs->objp),
(unsigned)(s->xs->fp - s->stack_base), (unsigned)(s->xs->sp - s->stack_base));
} else
- DebugPrintf("<no execution stack: pc,obj,fp omitted>\n");
+ debugPrintf("<no execution stack: pc,obj,fp omitted>\n");
return true;
}
bool Console::cmdDiskDump(int argc, const char **argv) {
+ int resNumFrom = 0;
+ int resNumTo = 0;
+ int resNumCur = 0;
+
if (argc != 3) {
- DebugPrintf("Dumps the specified resource to disk as a patch file\n");
- DebugPrintf("Usage: %s <resource type> <resource number>\n", argv[0]);
+ debugPrintf("Dumps the specified resource to disk as a patch file\n");
+ debugPrintf("Usage: %s <resource type> <resource number>\n", argv[0]);
+ debugPrintf(" <resource number> may be '*' to dump all resources of given type\n");
cmdResourceTypes(argc, argv);
return true;
}
+
+ if (strcmp(argv[2], "*") == 0) {
+ resNumFrom = 0;
+ resNumTo = 65535;
+ } else {
+ resNumFrom = atoi(argv[2]);
+ resNumTo = resNumFrom;
+ }
- int resNum = atoi(argv[2]);
ResourceType res = parseResourceType(argv[1]);
if (res == kResourceTypeInvalid)
- DebugPrintf("Resource type '%s' is not valid\n", argv[1]);
+ debugPrintf("Resource type '%s' is not valid\n", argv[1]);
else {
- Resource *resource = _engine->getResMan()->findResource(ResourceId(res, resNum), 0);
- if (resource) {
- char outFileName[50];
- sprintf(outFileName, "%s.%03d", getResourceTypeName(res), resNum);
- Common::DumpFile *outFile = new Common::DumpFile();
- outFile->open(outFileName);
- resource->writeToStream(outFile);
- outFile->finalize();
- outFile->close();
- delete outFile;
- DebugPrintf("Resource %s.%03d (located in %s) has been dumped to disk\n", argv[1], resNum, resource->getResourceLocation().c_str());
- } else {
- DebugPrintf("Resource %s.%03d not found\n", argv[1], resNum);
+ for (resNumCur = resNumFrom; resNumCur <= resNumTo; resNumCur++) {
+ Resource *resource = _engine->getResMan()->findResource(ResourceId(res, resNumCur), 0);
+ if (resource) {
+ char outFileName[50];
+ sprintf(outFileName, "%s.%03d", getResourceTypeName(res), resNumCur);
+ Common::DumpFile *outFile = new Common::DumpFile();
+ outFile->open(outFileName);
+ resource->writeToStream(outFile);
+ outFile->finalize();
+ outFile->close();
+ delete outFile;
+ debugPrintf("Resource %s.%03d (located in %s) has been dumped to disk\n", argv[1], resNumCur, resource->getResourceLocation().c_str());
+ } else {
+ if (resNumFrom == resNumTo) {
+ debugPrintf("Resource %s.%03d not found\n", argv[1], resNumCur);
+ }
+ }
}
}
@@ -691,8 +710,8 @@ bool Console::cmdDiskDump(int argc, const char **argv) {
bool Console::cmdHexDump(int argc, const char **argv) {
if (argc != 3) {
- DebugPrintf("Dumps the specified resource to standard output\n");
- DebugPrintf("Usage: %s <resource type> <resource number>\n", argv[0]);
+ debugPrintf("Dumps the specified resource to standard output\n");
+ debugPrintf("Usage: %s <resource type> <resource number>\n", argv[0]);
cmdResourceTypes(argc, argv);
return true;
}
@@ -701,14 +720,14 @@ bool Console::cmdHexDump(int argc, const char **argv) {
ResourceType res = parseResourceType(argv[1]);
if (res == kResourceTypeInvalid)
- DebugPrintf("Resource type '%s' is not valid\n", argv[1]);
+ debugPrintf("Resource type '%s' is not valid\n", argv[1]);
else {
Resource *resource = _engine->getResMan()->findResource(ResourceId(res, resNum), 0);
if (resource) {
Common::hexdump(resource->data, resource->size, 16, 0);
- DebugPrintf("Resource %s.%03d has been dumped to standard output\n", argv[1], resNum);
+ debugPrintf("Resource %s.%03d has been dumped to standard output\n", argv[1], resNum);
} else {
- DebugPrintf("Resource %s.%03d not found\n", argv[1], resNum);
+ debugPrintf("Resource %s.%03d not found\n", argv[1], resNum);
}
}
@@ -717,21 +736,21 @@ bool Console::cmdHexDump(int argc, const char **argv) {
bool Console::cmdResourceId(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Identifies a resource number by splitting it up in resource type and resource number\n");
- DebugPrintf("Usage: %s <resource number>\n", argv[0]);
+ debugPrintf("Identifies a resource number by splitting it up in resource type and resource number\n");
+ debugPrintf("Usage: %s <resource number>\n", argv[0]);
return true;
}
int id = atoi(argv[1]);
- DebugPrintf("%s.%d (0x%x)\n", getResourceTypeName((ResourceType)(id >> 11)), id & 0x7ff, id & 0x7ff);
+ debugPrintf("%s.%d (0x%x)\n", getResourceTypeName((ResourceType)(id >> 11)), id & 0x7ff, id & 0x7ff);
return true;
}
bool Console::cmdDissectScript(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Examines a script\n");
- DebugPrintf("Usage: %s <script number>\n", argv[0]);
+ debugPrintf("Examines a script\n");
+ debugPrintf("Usage: %s <script number>\n", argv[0]);
return true;
}
@@ -745,13 +764,13 @@ bool Console::cmdRoomNumber(int argc, const char **argv) {
// The same functionality is provided by "vmvars g 13" (but this one is more straighforward)
if (argc != 2) {
- DebugPrintf("Current room number is %d\n", _engine->_gamestate->currentRoomNumber());
- DebugPrintf("Calling this command with the room number (in decimal or hexadecimal) changes the room\n");
+ debugPrintf("Current room number is %d\n", _engine->_gamestate->currentRoomNumber());
+ debugPrintf("Calling this command with the room number (in decimal or hexadecimal) changes the room\n");
} else {
Common::String roomNumberStr = argv[1];
int roomNumber = strtol(roomNumberStr.c_str(), NULL, roomNumberStr.hasSuffix("h") ? 16 : 10);
_engine->_gamestate->setRoomNumber(roomNumber);
- DebugPrintf("Room number changed to %d (%x in hex)\n", roomNumber, roomNumber);
+ debugPrintf("Room number changed to %d (%x in hex)\n", roomNumber, roomNumber);
}
return true;
@@ -759,8 +778,8 @@ bool Console::cmdRoomNumber(int argc, const char **argv) {
bool Console::cmdResourceInfo(int argc, const char **argv) {
if (argc != 3) {
- DebugPrintf("Shows information about a resource\n");
- DebugPrintf("Usage: %s <resource type> <resource number>\n", argv[0]);
+ debugPrintf("Shows information about a resource\n");
+ debugPrintf("Usage: %s <resource type> <resource number>\n", argv[0]);
return true;
}
@@ -768,14 +787,14 @@ bool Console::cmdResourceInfo(int argc, const char **argv) {
ResourceType res = parseResourceType(argv[1]);
if (res == kResourceTypeInvalid)
- DebugPrintf("Resource type '%s' is not valid\n", argv[1]);
+ debugPrintf("Resource type '%s' is not valid\n", argv[1]);
else {
Resource *resource = _engine->getResMan()->findResource(ResourceId(res, resNum), 0);
if (resource) {
- DebugPrintf("Resource size: %d\n", resource->size);
- DebugPrintf("Resource location: %s\n", resource->getResourceLocation().c_str());
+ debugPrintf("Resource size: %d\n", resource->size);
+ debugPrintf("Resource location: %s\n", resource->getResourceLocation().c_str());
} else {
- DebugPrintf("Resource %s.%03d not found\n", argv[1], resNum);
+ debugPrintf("Resource %s.%03d not found\n", argv[1], resNum);
}
}
@@ -783,10 +802,10 @@ bool Console::cmdResourceInfo(int argc, const char **argv) {
}
bool Console::cmdResourceTypes(int argc, const char **argv) {
- DebugPrintf("The %d valid resource types are:\n", kResourceTypeInvalid);
+ debugPrintf("The %d valid resource types are:\n", kResourceTypeInvalid);
for (int i = 0; i < kResourceTypeInvalid; i++) {
- DebugPrintf("%s", getResourceTypeName((ResourceType) i));
- DebugPrintf((i < kResourceTypeInvalid - 1) ? ", " : "\n");
+ debugPrintf("%s", getResourceTypeName((ResourceType) i));
+ debugPrintf((i < kResourceTypeInvalid - 1) ? ", " : "\n");
}
return true;
@@ -794,10 +813,10 @@ bool Console::cmdResourceTypes(int argc, const char **argv) {
bool Console::cmdHexgrep(int argc, const char **argv) {
if (argc < 4) {
- DebugPrintf("Searches some resources for a particular sequence of bytes, represented as decimal or hexadecimal numbers.\n");
- DebugPrintf("Usage: %s <resource type> <resource number> <search string>\n", argv[0]);
- DebugPrintf("<resource number> can be a specific resource number, or \"all\" for all of the resources of the specified type\n");
- DebugPrintf("EXAMPLES:\n hexgrep script all 0xe8 0x03 0xc8 0x00\n hexgrep pic 0x42 0xfe\n");
+ debugPrintf("Searches some resources for a particular sequence of bytes, represented as decimal or hexadecimal numbers.\n");
+ debugPrintf("Usage: %s <resource type> <resource number> <search string>\n", argv[0]);
+ debugPrintf("<resource number> can be a specific resource number, or \"all\" for all of the resources of the specified type\n");
+ debugPrintf("EXAMPLES:\n hexgrep script all 0xe8 0x03 0xc8 0x00\n hexgrep pic 0x42 0xfe\n");
cmdResourceTypes(argc, argv);
return true;
}
@@ -807,7 +826,7 @@ bool Console::cmdHexgrep(int argc, const char **argv) {
Resource *script = NULL;
if (restype == kResourceTypeInvalid) {
- DebugPrintf("Resource type '%s' is not valid\n", argv[1]);
+ debugPrintf("Resource type '%s' is not valid\n", argv[1]);
return true;
}
@@ -845,10 +864,10 @@ bool Console::cmdHexgrep(int argc, const char **argv) {
seeker = seekerold + 1;
if (!output_script_name) {
- DebugPrintf("\nIn %s.%03d:\n", getResourceTypeName((ResourceType)restype), resNumber);
+ debugPrintf("\nIn %s.%03d:\n", getResourceTypeName((ResourceType)restype), resNumber);
output_script_name = 1;
}
- DebugPrintf(" 0x%04x\n", seekerold);
+ debugPrintf(" 0x%04x\n", seekerold);
}
} else
comppos = 0;
@@ -863,38 +882,38 @@ bool Console::cmdHexgrep(int argc, const char **argv) {
bool Console::cmdVerifyScripts(int argc, const char **argv) {
if (getSciVersion() < SCI_VERSION_1_1) {
- DebugPrintf("This script check is only meant for SCI1.1-SCI3 games\n");
+ debugPrintf("This script check is only meant for SCI1.1-SCI3 games\n");
return true;
}
Common::List<ResourceId> resources = _engine->getResMan()->listResources(kResourceTypeScript);
Common::sort(resources.begin(), resources.end());
- DebugPrintf("%d SCI1.1-SCI3 scripts found, performing sanity checks...\n", resources.size());
+ debugPrintf("%d SCI1.1-SCI3 scripts found, performing sanity checks...\n", resources.size());
Resource *script, *heap;
Common::List<ResourceId>::iterator itr;
for (itr = resources.begin(); itr != resources.end(); ++itr) {
script = _engine->getResMan()->findResource(*itr, false);
if (!script)
- DebugPrintf("Error: script %d couldn't be loaded\n", itr->getNumber());
+ debugPrintf("Error: script %d couldn't be loaded\n", itr->getNumber());
if (getSciVersion() <= SCI_VERSION_2_1) {
heap = _engine->getResMan()->findResource(ResourceId(kResourceTypeHeap, itr->getNumber()), false);
if (!heap)
- DebugPrintf("Error: script %d doesn't have a corresponding heap\n", itr->getNumber());
+ debugPrintf("Error: script %d doesn't have a corresponding heap\n", itr->getNumber());
if (script && heap && (script->size + heap->size > 65535))
- DebugPrintf("Error: script and heap %d together are larger than 64KB (%d bytes)\n",
+ debugPrintf("Error: script and heap %d together are larger than 64KB (%d bytes)\n",
itr->getNumber(), script->size + heap->size);
} else { // SCI3
if (script && script->size > 65535)
- DebugPrintf("Error: script %d is larger than 64KB (%d bytes)\n",
+ debugPrintf("Error: script %d is larger than 64KB (%d bytes)\n",
itr->getNumber(), script->size);
}
}
- DebugPrintf("SCI1.1-SCI2.1 script check finished\n");
+ debugPrintf("SCI1.1-SCI2.1 script check finished\n");
return true;
}
@@ -931,9 +950,9 @@ bool Console::cmdShowInstruments(int argc, const char **argv) {
instrumentsSongs[i][j] = false;
if (songNumber == -1) {
- DebugPrintf("%d sounds found, checking their instrument mappings...\n", resources.size());
- DebugPrintf("Instruments:\n");
- DebugPrintf("============\n");
+ debugPrintf("%d sounds found, checking their instrument mappings...\n", resources.size());
+ debugPrintf("Instruments:\n");
+ debugPrintf("============\n");
}
Common::List<ResourceId>::iterator itr;
@@ -956,7 +975,7 @@ bool Console::cmdShowInstruments(int argc, const char **argv) {
bool endOfTrack = false;
bool firstOneShown = false;
- DebugPrintf("Song %d: ", itr->getNumber());
+ debugPrintf("Song %d: ", itr->getNumber());
do {
while (*channelData == 0xF8)
@@ -984,9 +1003,9 @@ bool Console::cmdShowInstruments(int argc, const char **argv) {
if (!firstOneShown)
firstOneShown = true;
else
- DebugPrintf(",");
+ debugPrintf(",");
- DebugPrintf(" %d", instrument);
+ debugPrintf(" %d", instrument);
instruments[instrument]++;
instrumentsSongs[instrument][itr->getNumber()] = true;
} else {
@@ -1024,44 +1043,44 @@ bool Console::cmdShowInstruments(int argc, const char **argv) {
}
} while (!endOfTrack);
- DebugPrintf("\n");
+ debugPrintf("\n");
}
delete parser;
delete player;
- DebugPrintf("\n");
+ debugPrintf("\n");
if (songNumber == -1) {
- DebugPrintf("Used instruments: ");
+ debugPrintf("Used instruments: ");
for (int i = 0; i < 128; i++) {
if (instruments[i] > 0)
- DebugPrintf("%d, ", i);
+ debugPrintf("%d, ", i);
}
- DebugPrintf("\n\n");
+ debugPrintf("\n\n");
}
- DebugPrintf("Instruments not mapped in the MT32->GM map: ");
+ debugPrintf("Instruments not mapped in the MT32->GM map: ");
for (int i = 0; i < 128; i++) {
if (instruments[i] > 0 && getGmInstrument(Mt32MemoryTimbreMaps[i]) == MIDI_UNMAPPED)
- DebugPrintf("%d, ", i);
+ debugPrintf("%d, ", i);
}
- DebugPrintf("\n\n");
+ debugPrintf("\n\n");
if (songNumber == -1) {
- DebugPrintf("Used instruments in songs:\n");
+ debugPrintf("Used instruments in songs:\n");
for (int i = 0; i < 128; i++) {
if (instruments[i] > 0) {
- DebugPrintf("Instrument %d: ", i);
+ debugPrintf("Instrument %d: ", i);
for (int j = 0; j < 1000; j++) {
if (instrumentsSongs[i][j])
- DebugPrintf("%d, ", j);
+ debugPrintf("%d, ", j);
}
- DebugPrintf("\n");
+ debugPrintf("\n");
}
}
- DebugPrintf("\n\n");
+ debugPrintf("\n\n");
}
return true;
@@ -1069,13 +1088,13 @@ bool Console::cmdShowInstruments(int argc, const char **argv) {
bool Console::cmdMapInstrument(int argc, const char **argv) {
if (argc != 4) {
- DebugPrintf("Maps an MT-32 custom instrument to a GM instrument on the fly\n\n");
- DebugPrintf("Usage %s <MT-32 instrument name> <GM instrument> <GM rhythm key>\n", argv[0]);
- DebugPrintf("Each MT-32 instrument is always 10 characters and is mapped to either a GM instrument, or a GM rhythm key\n");
- DebugPrintf("A value of 255 (0xff) signifies an unmapped instrument\n");
- DebugPrintf("Please replace the spaces in the instrument name with underscores (\"_\"). They'll be converted to spaces afterwards\n\n");
- DebugPrintf("Example: %s test_0__XX 1 255\n", argv[0]);
- DebugPrintf("The above example will map the MT-32 instrument \"test 0 XX\" to GM instrument 1\n\n");
+ debugPrintf("Maps an MT-32 custom instrument to a GM instrument on the fly\n\n");
+ debugPrintf("Usage %s <MT-32 instrument name> <GM instrument> <GM rhythm key>\n", argv[0]);
+ debugPrintf("Each MT-32 instrument is always 10 characters and is mapped to either a GM instrument, or a GM rhythm key\n");
+ debugPrintf("A value of 255 (0xff) signifies an unmapped instrument\n");
+ debugPrintf("Please replace the spaces in the instrument name with underscores (\"_\"). They'll be converted to spaces afterwards\n\n");
+ debugPrintf("Example: %s test_0__XX 1 255\n", argv[0]);
+ debugPrintf("The above example will map the MT-32 instrument \"test 0 XX\" to GM instrument 1\n\n");
} else {
if (Mt32dynamicMappings != NULL) {
Mt32ToGmMap newMapping;
@@ -1093,11 +1112,11 @@ bool Console::cmdMapInstrument(int argc, const char **argv) {
}
}
- DebugPrintf("Current dynamic mappings:\n");
+ debugPrintf("Current dynamic mappings:\n");
if (Mt32dynamicMappings != NULL) {
const Mt32ToGmMapList::iterator end = Mt32dynamicMappings->end();
for (Mt32ToGmMapList::iterator it = Mt32dynamicMappings->begin(); it != end; ++it) {
- DebugPrintf("\"%s\" -> %d / %d\n", (*it).name, (*it).gmInstr, (*it).gmRhythmKey);
+ debugPrintf("\"%s\" -> %d / %d\n", (*it).name, (*it).gmInstr, (*it).gmRhythmKey);
}
}
@@ -1106,7 +1125,7 @@ bool Console::cmdMapInstrument(int argc, const char **argv) {
bool Console::cmdList(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Lists all the resources of a given type\n");
+ debugPrintf("Lists all the resources of a given type\n");
cmdResourceTypes(argc, argv);
return true;
}
@@ -1114,13 +1133,13 @@ bool Console::cmdList(int argc, const char **argv) {
ResourceType res = parseResourceType(argv[1]);
if (res == kResourceTypeInvalid)
- DebugPrintf("Unknown resource type: '%s'\n", argv[1]);
+ debugPrintf("Unknown resource type: '%s'\n", argv[1]);
else {
int number = -1;
if ((res == kResourceTypeAudio36) || (res == kResourceTypeSync36)) {
if (argc != 3) {
- DebugPrintf("Please specify map number (-1: all maps)\n");
+ debugPrintf("Please specify map number (-1: all maps)\n");
return true;
}
number = atoi(argv[2]);
@@ -1133,18 +1152,18 @@ bool Console::cmdList(int argc, const char **argv) {
Common::List<ResourceId>::iterator itr;
for (itr = resources.begin(); itr != resources.end(); ++itr) {
if (number == -1) {
- DebugPrintf("%8i", itr->getNumber());
+ debugPrintf("%8i", itr->getNumber());
if (++cnt % 10 == 0)
- DebugPrintf("\n");
+ debugPrintf("\n");
} else if (number == (int)itr->getNumber()) {
const uint32 tuple = itr->getTuple();
- DebugPrintf("(%3i, %3i, %3i, %3i) ", (tuple >> 24) & 0xff, (tuple >> 16) & 0xff,
+ debugPrintf("(%3i, %3i, %3i, %3i) ", (tuple >> 24) & 0xff, (tuple >> 16) & 0xff,
(tuple >> 8) & 0xff, tuple & 0xff);
if (++cnt % 4 == 0)
- DebugPrintf("\n");
+ debugPrintf("\n");
}
}
- DebugPrintf("\n");
+ debugPrintf("\n");
}
return true;
@@ -1152,8 +1171,8 @@ bool Console::cmdList(int argc, const char **argv) {
bool Console::cmdSaveGame(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Saves the current game state to the hard disk\n");
- DebugPrintf("Usage: %s <filename>\n", argv[0]);
+ debugPrintf("Saves the current game state to the hard disk\n");
+ debugPrintf("Usage: %s <filename>\n", argv[0]);
return true;
}
@@ -1163,19 +1182,19 @@ bool Console::cmdSaveGame(int argc, const char **argv) {
result++;
if (result)
- DebugPrintf("Note: Game state has %d open file handles.\n", result);
+ debugPrintf("Note: Game state has %d open file handles.\n", result);
Common::SaveFileManager *saveFileMan = g_engine->getSaveFileManager();
Common::OutSaveFile *out = saveFileMan->openForSaving(argv[1]);
const char *version = "";
if (!out) {
- DebugPrintf("Error opening savegame \"%s\" for writing\n", argv[1]);
+ debugPrintf("Error opening savegame \"%s\" for writing\n", argv[1]);
return true;
}
// TODO: enable custom descriptions? force filename into a specific format?
if (!gamestate_save(_engine->_gamestate, out, "debugging", version)) {
- DebugPrintf("Saving the game state to '%s' failed\n", argv[1]);
+ debugPrintf("Saving the game state to '%s' failed\n", argv[1]);
} else {
out->finalize();
if (out->err()) {
@@ -1189,8 +1208,8 @@ bool Console::cmdSaveGame(int argc, const char **argv) {
bool Console::cmdRestoreGame(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Restores a saved game from the hard disk\n");
- DebugPrintf("Usage: %s <filename>\n", argv[0]);
+ debugPrintf("Restores a saved game from the hard disk\n");
+ debugPrintf("Usage: %s <filename>\n", argv[0]);
return true;
}
@@ -1203,17 +1222,17 @@ bool Console::cmdRestoreGame(int argc, const char **argv) {
}
if (_engine->_gamestate->r_acc == make_reg(0, 1)) {
- DebugPrintf("Restoring gamestate '%s' failed.\n", argv[1]);
+ debugPrintf("Restoring gamestate '%s' failed.\n", argv[1]);
return true;
}
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdRestartGame(int argc, const char **argv) {
_engine->_gamestate->abortScriptProcessing = kAbortRestartGame;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
// The scripts get IDs ranging from 100->199, because the scripts require us to assign unique ids THAT EVEN STAY BETWEEN
@@ -1231,25 +1250,25 @@ bool Console::cmdListSaves(int argc, const char **argv) {
for (uint i = 0; i < saves.size(); i++) {
Common::String filename = g_sci->getSavegameName(saves[i].id);
- DebugPrintf("%s: '%s'\n", filename.c_str(), saves[i].name);
+ debugPrintf("%s: '%s'\n", filename.c_str(), saves[i].name);
}
return true;
}
bool Console::cmdClassTable(int argc, const char **argv) {
- DebugPrintf("Available classes (parse a parameter to filter the table by a specific class):\n");
+ debugPrintf("Available classes (parse a parameter to filter the table by a specific class):\n");
for (uint i = 0; i < _engine->_gamestate->_segMan->classTableSize(); i++) {
Class temp = _engine->_gamestate->_segMan->_classTable[i];
if (temp.reg.getSegment()) {
const char *className = _engine->_gamestate->_segMan->getObjectName(temp.reg);
if (argc == 1 || (argc == 2 && !strcmp(className, argv[1]))) {
- DebugPrintf(" Class 0x%x (%s) at %04x:%04x (script %d)\n", i,
+ debugPrintf(" Class 0x%x (%s) at %04x:%04x (script %d)\n", i,
className,
PRINT_REG(temp.reg),
temp.script);
- } else DebugPrintf(" Class 0x%x (not loaded; can't get name) (script %d)\n", i, temp.script);
+ } else debugPrintf(" Class 0x%x (not loaded; can't get name) (script %d)\n", i, temp.script);
}
}
@@ -1257,52 +1276,52 @@ bool Console::cmdClassTable(int argc, const char **argv) {
}
bool Console::cmdSentenceFragments(int argc, const char **argv) {
- DebugPrintf("Sentence fragments (used to build Parse trees)\n");
+ debugPrintf("Sentence fragments (used to build Parse trees)\n");
for (uint i = 0; i < _engine->getVocabulary()->getParserBranchesSize(); i++) {
int j = 0;
const parse_tree_branch_t &branch = _engine->getVocabulary()->getParseTreeBranch(i);
- DebugPrintf("R%02d: [%x] ->", i, branch.id);
+ debugPrintf("R%02d: [%x] ->", i, branch.id);
while ((j < 10) && branch.data[j]) {
int dat = branch.data[j++];
switch (dat) {
case VOCAB_TREE_NODE_COMPARE_TYPE:
dat = branch.data[j++];
- DebugPrintf(" C(%x)", dat);
+ debugPrintf(" C(%x)", dat);
break;
case VOCAB_TREE_NODE_COMPARE_GROUP:
dat = branch.data[j++];
- DebugPrintf(" WG(%x)", dat);
+ debugPrintf(" WG(%x)", dat);
break;
case VOCAB_TREE_NODE_FORCE_STORAGE:
dat = branch.data[j++];
- DebugPrintf(" FORCE(%x)", dat);
+ debugPrintf(" FORCE(%x)", dat);
break;
default:
if (dat > VOCAB_TREE_NODE_LAST_WORD_STORAGE) {
int dat2 = branch.data[j++];
- DebugPrintf(" %x[%x]", dat, dat2);
+ debugPrintf(" %x[%x]", dat, dat2);
} else
- DebugPrintf(" ?%x?", dat);
+ debugPrintf(" ?%x?", dat);
}
}
- DebugPrintf("\n");
+ debugPrintf("\n");
}
- DebugPrintf("%d rules.\n", _engine->getVocabulary()->getParserBranchesSize());
+ debugPrintf("%d rules.\n", _engine->getVocabulary()->getParserBranchesSize());
return true;
}
bool Console::cmdParse(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Parses a sequence of words with a GNF rule set and prints the resulting parse tree\n");
- DebugPrintf("Usage: %s <word1> <word2> ... <wordn>\n", argv[0]);
+ debugPrintf("Parses a sequence of words with a GNF rule set and prints the resulting parse tree\n");
+ debugPrintf("Usage: %s <word1> <word2> ... <wordn>\n", argv[0]);
return true;
}
@@ -1316,7 +1335,7 @@ bool Console::cmdParse(int argc, const char **argv) {
strcat(string, argv[i]);
}
- DebugPrintf("Parsing '%s'\n", string);
+ debugPrintf("Parsing '%s'\n", string);
ResultWordListList words;
bool res = _engine->getVocabulary()->tokenizeString(words, string, &error);
@@ -1325,26 +1344,26 @@ bool Console::cmdParse(int argc, const char **argv) {
_engine->getVocabulary()->synonymizeTokens(words);
- DebugPrintf("Parsed to the following blocks:\n");
+ debugPrintf("Parsed to the following blocks:\n");
for (ResultWordListList::const_iterator i = words.begin(); i != words.end(); ++i) {
- DebugPrintf(" ");
+ debugPrintf(" ");
for (ResultWordList::const_iterator j = i->begin(); j != i->end(); ++j) {
- DebugPrintf("%sType[%04x] Group[%04x]", j == i->begin() ? "" : " / ", j->_class, j->_group);
+ debugPrintf("%sType[%04x] Group[%04x]", j == i->begin() ? "" : " / ", j->_class, j->_group);
}
- DebugPrintf("\n");
+ debugPrintf("\n");
}
if (_engine->getVocabulary()->parseGNF(words, true))
syntax_fail = 1; // Building a tree failed
if (syntax_fail)
- DebugPrintf("Building a tree failed.\n");
+ debugPrintf("Building a tree failed.\n");
else
_engine->getVocabulary()->dumpParseTree();
} else {
- DebugPrintf("Unknown word: '%s'\n", error);
+ debugPrintf("Unknown word: '%s'\n", error);
free(error);
}
@@ -1353,10 +1372,10 @@ bool Console::cmdParse(int argc, const char **argv) {
bool Console::cmdSaid(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Matches a string against a said spec\n");
- DebugPrintf("Usage: %s <string> > & <said spec>\n", argv[0]);
- DebugPrintf("<string> is a sequence of actual words.\n");
- DebugPrintf("<said spec> is a sequence of hex tokens.\n");
+ debugPrintf("Matches a string against a said spec\n");
+ debugPrintf("Usage: %s <string> > & <said spec>\n", argv[0]);
+ debugPrintf("<string> is a sequence of actual words.\n");
+ debugPrintf("<said spec> is a sequence of hex tokens.\n");
return true;
}
@@ -1373,10 +1392,10 @@ bool Console::cmdSaid(int argc, const char **argv) {
}
if (p >= argc-1) {
- DebugPrintf("Matches a string against a said spec\n");
- DebugPrintf("Usage: %s <string> > & <said spec>\n", argv[0]);
- DebugPrintf("<string> is a sequence of actual words.\n");
- DebugPrintf("<said spec> is a sequence of hex tokens.\n");
+ debugPrintf("Matches a string against a said spec\n");
+ debugPrintf("Usage: %s <string> > & <said spec>\n", argv[0]);
+ debugPrintf("<string> is a sequence of actual words.\n");
+ debugPrintf("<said spec> is a sequence of hex tokens.\n");
return true;
}
@@ -1440,14 +1459,14 @@ bool Console::cmdSaid(int argc, const char **argv) {
_engine->getVocabulary()->synonymizeTokens(words);
- DebugPrintf("Parsed to the following blocks:\n");
+ debugPrintf("Parsed to the following blocks:\n");
for (ResultWordListList::const_iterator i = words.begin(); i != words.end(); ++i) {
- DebugPrintf(" ");
+ debugPrintf(" ");
for (ResultWordList::const_iterator j = i->begin(); j != i->end(); ++j) {
- DebugPrintf("%sType[%04x] Group[%04x]", j == i->begin() ? "" : " / ", j->_class, j->_group);
+ debugPrintf("%sType[%04x] Group[%04x]", j == i->begin() ? "" : " / ", j->_class, j->_group);
}
- DebugPrintf("\n");
+ debugPrintf("\n");
}
@@ -1456,17 +1475,17 @@ bool Console::cmdSaid(int argc, const char **argv) {
syntax_fail = 1; // Building a tree failed
if (syntax_fail)
- DebugPrintf("Building a tree failed.\n");
+ debugPrintf("Building a tree failed.\n");
else {
_engine->getVocabulary()->dumpParseTree();
_engine->getVocabulary()->parserIsValid = true;
int ret = said((byte *)spec, true);
- DebugPrintf("kSaid: %s\n", (ret == SAID_NO_MATCH ? "No match" : "Match"));
+ debugPrintf("kSaid: %s\n", (ret == SAID_NO_MATCH ? "No match" : "Match"));
}
} else {
- DebugPrintf("Unknown word: '%s'\n", error);
+ debugPrintf("Unknown word: '%s'\n", error);
free(error);
}
@@ -1476,9 +1495,9 @@ bool Console::cmdSaid(int argc, const char **argv) {
bool Console::cmdParserNodes(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Shows the specified number of nodes from the parse node tree\n");
- DebugPrintf("Usage: %s <nr>\n", argv[0]);
- DebugPrintf("where <nr> is the number of nodes to show from the parse node tree\n");
+ debugPrintf("Shows the specified number of nodes from the parse node tree\n");
+ debugPrintf("Usage: %s <nr>\n", argv[0]);
+ debugPrintf("where <nr> is the number of nodes to show from the parse node tree\n");
return true;
}
@@ -1491,9 +1510,9 @@ bool Console::cmdParserNodes(int argc, const char **argv) {
bool Console::cmdSetPalette(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Sets a palette resource\n");
- DebugPrintf("Usage: %s <resourceId>\n", argv[0]);
- DebugPrintf("where <resourceId> is the number of the palette resource to set\n");
+ debugPrintf("Sets a palette resource\n");
+ debugPrintf("Usage: %s <resourceId>\n", argv[0]);
+ debugPrintf("where <resourceId> is the number of the palette resource to set\n");
return true;
}
@@ -1505,9 +1524,9 @@ bool Console::cmdSetPalette(int argc, const char **argv) {
bool Console::cmdDrawPic(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Draws a pic resource\n");
- DebugPrintf("Usage: %s <resourceId>\n", argv[0]);
- DebugPrintf("where <resourceId> is the number of the pic resource to draw\n");
+ debugPrintf("Draws a pic resource\n");
+ debugPrintf("Usage: %s <resourceId>\n", argv[0]);
+ debugPrintf("where <resourceId> is the number of the pic resource to draw\n");
return true;
}
@@ -1532,9 +1551,9 @@ bool Console::cmdDrawPic(int argc, const char **argv) {
bool Console::cmdDrawCel(int argc, const char **argv) {
if (argc < 4) {
- DebugPrintf("Draws a cel from a view resource\n");
- DebugPrintf("Usage: %s <resourceId> <loopNr> <celNr> \n", argv[0]);
- DebugPrintf("where <resourceId> is the number of the view resource to draw\n");
+ debugPrintf("Draws a cel from a view resource\n");
+ debugPrintf("Usage: %s <resourceId> <loopNr> <celNr> \n", argv[0]);
+ debugPrintf("where <resourceId> is the number of the view resource to draw\n");
return true;
}
@@ -1555,24 +1574,24 @@ bool Console::cmdDrawCel(int argc, const char **argv) {
bool Console::cmdUndither(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Enable/disable undithering.\n");
- DebugPrintf("Usage: %s <0/1>\n", argv[0]);
+ debugPrintf("Enable/disable undithering.\n");
+ debugPrintf("Usage: %s <0/1>\n", argv[0]);
return true;
}
bool flag = atoi(argv[1]) ? true : false;
_engine->_gfxScreen->enableUndithering(flag);
if (flag)
- DebugPrintf("undithering ENABLED\n");
+ debugPrintf("undithering ENABLED\n");
else
- DebugPrintf("undithering DISABLED\n");
+ debugPrintf("undithering DISABLED\n");
return true;
}
bool Console::cmdPicVisualize(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Enable/disable picture visualization (EGA only)\n");
- DebugPrintf("Usage: %s <0/1>\n", argv[0]);
+ debugPrintf("Enable/disable picture visualization (EGA only)\n");
+ debugPrintf("Usage: %s <0/1>\n", argv[0]);
return true;
}
@@ -1581,21 +1600,21 @@ bool Console::cmdPicVisualize(int argc, const char **argv) {
if (_engine->_resMan->getViewType() == kViewEga) {
_engine->_gfxPaint16->debugSetEGAdrawingVisualize(state);
if (state)
- DebugPrintf("picture visualization ENABLED\n");
+ debugPrintf("picture visualization ENABLED\n");
else
- DebugPrintf("picture visualization DISABLED\n");
+ debugPrintf("picture visualization DISABLED\n");
} else {
- DebugPrintf("picture visualization only available for EGA games\n");
+ debugPrintf("picture visualization only available for EGA games\n");
}
return true;
}
bool Console::cmdPlayVideo(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Plays a SEQ, AVI, VMD, RBT or DUK video.\n");
- DebugPrintf("Usage: %s <video file name> <delay>\n", argv[0]);
- DebugPrintf("The video file name should include the extension\n");
- DebugPrintf("Delay is only used in SEQ videos and is measured in ticks (default: 10)\n");
+ debugPrintf("Plays a SEQ, AVI, VMD, RBT or DUK video.\n");
+ debugPrintf("Usage: %s <video file name> <delay>\n", argv[0]);
+ debugPrintf("The video file name should include the extension\n");
+ debugPrintf("Delay is only used in SEQ videos and is measured in ticks (default: 10)\n");
return true;
}
@@ -1606,29 +1625,29 @@ bool Console::cmdPlayVideo(int argc, const char **argv) {
filename.hasSuffix(".rbt") || filename.hasSuffix(".duk")) {
_videoFile = filename;
_videoFrameDelay = (argc == 2) ? 10 : atoi(argv[2]);
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
} else {
- DebugPrintf("Unknown video file type\n");
+ debugPrintf("Unknown video file type\n");
return true;
}
}
bool Console::cmdAnimateList(int argc, const char **argv) {
if (_engine->_gfxAnimate) {
- DebugPrintf("Animate list:\n");
+ debugPrintf("Animate list:\n");
_engine->_gfxAnimate->printAnimateList(this);
} else {
- DebugPrintf("This SCI version does not have an animate list\n");
+ debugPrintf("This SCI version does not have an animate list\n");
}
return true;
}
bool Console::cmdWindowList(int argc, const char **argv) {
if (_engine->_gfxPorts) {
- DebugPrintf("Window list:\n");
+ debugPrintf("Window list:\n");
_engine->_gfxPorts->printWindowList(this);
} else {
- DebugPrintf("This SCI version does not have a list of ports\n");
+ debugPrintf("This SCI version does not have a list of ports\n");
}
return true;
}
@@ -1636,41 +1655,41 @@ bool Console::cmdWindowList(int argc, const char **argv) {
bool Console::cmdPlaneList(int argc, const char **argv) {
#ifdef ENABLE_SCI32
if (_engine->_gfxFrameout) {
- DebugPrintf("Plane list:\n");
+ debugPrintf("Plane list:\n");
_engine->_gfxFrameout->printPlaneList(this);
} else {
- DebugPrintf("This SCI version does not have a list of planes\n");
+ debugPrintf("This SCI version does not have a list of planes\n");
}
#else
- DebugPrintf("SCI32 isn't included in this compiled executable\n");
+ debugPrintf("SCI32 isn't included in this compiled executable\n");
#endif
return true;
}
bool Console::cmdPlaneItemList(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Shows the list of items for a plane\n");
- DebugPrintf("Usage: %s <plane address>\n", argv[0]);
+ debugPrintf("Shows the list of items for a plane\n");
+ debugPrintf("Usage: %s <plane address>\n", argv[0]);
return true;
}
reg_t planeObject = NULL_REG;
if (parse_reg_t(_engine->_gamestate, argv[1], &planeObject, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
#ifdef ENABLE_SCI32
if (_engine->_gfxFrameout) {
- DebugPrintf("Plane item list:\n");
+ debugPrintf("Plane item list:\n");
_engine->_gfxFrameout->printPlaneItemList(this, planeObject);
} else {
- DebugPrintf("This SCI version does not have a list of plane items\n");
+ debugPrintf("This SCI version does not have a list of plane items\n");
}
#else
- DebugPrintf("SCI32 isn't included in this compiled executable\n");
+ debugPrintf("SCI32 isn't included in this compiled executable\n");
#endif
return true;
}
@@ -1680,7 +1699,7 @@ bool Console::cmdSavedBits(int argc, const char **argv) {
SegmentId id = segman->findSegmentByType(SEG_TYPE_HUNK);
HunkTable* hunks = (HunkTable *)segman->getSegmentObj(id);
if (!hunks) {
- DebugPrintf("No hunk segment found.\n");
+ debugPrintf("No hunk segment found.\n");
return true;
}
@@ -1693,7 +1712,7 @@ bool Console::cmdSavedBits(int argc, const char **argv) {
byte* memoryPtr = (byte *)h.mem;
if (memoryPtr) {
- DebugPrintf("%04x:%04x:", PRINT_REG(entries[i]));
+ debugPrintf("%04x:%04x:", PRINT_REG(entries[i]));
Common::Rect rect;
byte mask;
@@ -1702,17 +1721,17 @@ bool Console::cmdSavedBits(int argc, const char **argv) {
memcpy((void *)&rect, memoryPtr, sizeof(rect));
memcpy((void *)&mask, memoryPtr + sizeof(rect), sizeof(mask));
- DebugPrintf(" %d,%d - %d,%d", rect.top, rect.left,
+ debugPrintf(" %d,%d - %d,%d", rect.top, rect.left,
rect.bottom, rect.right);
if (mask & GFX_SCREEN_MASK_VISUAL)
- DebugPrintf(" visual");
+ debugPrintf(" visual");
if (mask & GFX_SCREEN_MASK_PRIORITY)
- DebugPrintf(" priority");
+ debugPrintf(" priority");
if (mask & GFX_SCREEN_MASK_CONTROL)
- DebugPrintf(" control");
+ debugPrintf(" control");
if (mask & GFX_SCREEN_MASK_DISPLAY)
- DebugPrintf(" display");
- DebugPrintf("\n");
+ debugPrintf(" display");
+ debugPrintf("\n");
}
}
}
@@ -1723,22 +1742,22 @@ bool Console::cmdSavedBits(int argc, const char **argv) {
bool Console::cmdShowSavedBits(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Display saved bits.\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Display saved bits.\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t memoryHandle = NULL_REG;
if (parse_reg_t(_engine->_gamestate, argv[1], &memoryHandle, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
if (memoryHandle.isNull()) {
- DebugPrintf("Invalid address.\n");
+ debugPrintf("Invalid address.\n");
return true;
}
@@ -1746,26 +1765,26 @@ bool Console::cmdShowSavedBits(int argc, const char **argv) {
SegmentId id = segman->findSegmentByType(SEG_TYPE_HUNK);
HunkTable* hunks = (HunkTable *)segman->getSegmentObj(id);
if (!hunks) {
- DebugPrintf("No hunk segment found.\n");
+ debugPrintf("No hunk segment found.\n");
return true;
}
if (memoryHandle.getSegment() != id || !hunks->isValidOffset(memoryHandle.getOffset())) {
- DebugPrintf("Invalid address.\n");
+ debugPrintf("Invalid address.\n");
return true;
}
const Hunk& h = hunks->_table[memoryHandle.getOffset()];
if (strcmp(h.type, "SaveBits()") != 0) {
- DebugPrintf("Invalid address.\n");
+ debugPrintf("Invalid address.\n");
return true;
}
byte *memoryPtr = segman->getHunkPointer(memoryHandle);
if (!memoryPtr) {
- DebugPrintf("Invalid or freed bits.\n");
+ debugPrintf("Invalid or freed bits.\n");
return true;
}
@@ -1783,17 +1802,17 @@ bool Console::cmdShowSavedBits(int argc, const char **argv) {
Common::Point bl(rect.left, rect.bottom-1);
Common::Point br(rect.right-1, rect.bottom-1);
- DebugPrintf(" %d,%d - %d,%d", rect.top, rect.left,
+ debugPrintf(" %d,%d - %d,%d", rect.top, rect.left,
rect.bottom, rect.right);
if (mask & GFX_SCREEN_MASK_VISUAL)
- DebugPrintf(" visual");
+ debugPrintf(" visual");
if (mask & GFX_SCREEN_MASK_PRIORITY)
- DebugPrintf(" priority");
+ debugPrintf(" priority");
if (mask & GFX_SCREEN_MASK_CONTROL)
- DebugPrintf(" control");
+ debugPrintf(" control");
if (mask & GFX_SCREEN_MASK_DISPLAY)
- DebugPrintf(" display");
- DebugPrintf("\n");
+ debugPrintf(" display");
+ debugPrintf("\n");
if (!_engine->_gfxPaint16 || !_engine->_gfxScreen)
return true;
@@ -1843,7 +1862,7 @@ bool Console::cmdShowSavedBits(int argc, const char **argv) {
bool Console::cmdParseGrammar(int argc, const char **argv) {
- DebugPrintf("Parse grammar, in strict GNF:\n");
+ debugPrintf("Parse grammar, in strict GNF:\n");
_engine->getVocabulary()->buildGNF(true);
@@ -1851,71 +1870,71 @@ bool Console::cmdParseGrammar(int argc, const char **argv) {
}
bool Console::cmdPrintSegmentTable(int argc, const char **argv) {
- DebugPrintf("Segment table:\n");
+ debugPrintf("Segment table:\n");
for (uint i = 0; i < _engine->_gamestate->_segMan->_heap.size(); i++) {
SegmentObj *mobj = _engine->_gamestate->_segMan->_heap[i];
if (mobj && mobj->getType()) {
- DebugPrintf(" [%04x] ", i);
+ debugPrintf(" [%04x] ", i);
switch (mobj->getType()) {
case SEG_TYPE_SCRIPT:
- DebugPrintf("S script.%03d l:%d ", (*(Script *)mobj).getScriptNumber(), (*(Script *)mobj).getLockers());
+ debugPrintf("S script.%03d l:%d ", (*(Script *)mobj).getScriptNumber(), (*(Script *)mobj).getLockers());
break;
case SEG_TYPE_CLONES:
- DebugPrintf("C clones (%d allocd)", (*(CloneTable *)mobj).entries_used);
+ debugPrintf("C clones (%d allocd)", (*(CloneTable *)mobj).entries_used);
break;
case SEG_TYPE_LOCALS:
- DebugPrintf("V locals %03d", (*(LocalVariables *)mobj).script_id);
+ debugPrintf("V locals %03d", (*(LocalVariables *)mobj).script_id);
break;
case SEG_TYPE_STACK:
- DebugPrintf("D data stack (%d)", (*(DataStack *)mobj)._capacity);
+ debugPrintf("D data stack (%d)", (*(DataStack *)mobj)._capacity);
break;
case SEG_TYPE_LISTS:
- DebugPrintf("L lists (%d)", (*(ListTable *)mobj).entries_used);
+ debugPrintf("L lists (%d)", (*(ListTable *)mobj).entries_used);
break;
case SEG_TYPE_NODES:
- DebugPrintf("N nodes (%d)", (*(NodeTable *)mobj).entries_used);
+ debugPrintf("N nodes (%d)", (*(NodeTable *)mobj).entries_used);
break;
case SEG_TYPE_HUNK:
- DebugPrintf("H hunk (%d)", (*(HunkTable *)mobj).entries_used);
+ debugPrintf("H hunk (%d)", (*(HunkTable *)mobj).entries_used);
break;
case SEG_TYPE_DYNMEM:
- DebugPrintf("M dynmem: %d bytes", (*(DynMem *)mobj)._size);
+ debugPrintf("M dynmem: %d bytes", (*(DynMem *)mobj)._size);
break;
#ifdef ENABLE_SCI32
case SEG_TYPE_ARRAY:
- DebugPrintf("A SCI32 arrays (%d)", (*(ArrayTable *)mobj).entries_used);
+ debugPrintf("A SCI32 arrays (%d)", (*(ArrayTable *)mobj).entries_used);
break;
case SEG_TYPE_STRING:
- DebugPrintf("T SCI32 strings (%d)", (*(StringTable *)mobj).entries_used);
+ debugPrintf("T SCI32 strings (%d)", (*(StringTable *)mobj).entries_used);
break;
#endif
default:
- DebugPrintf("I Invalid (type = %x)", mobj->getType());
+ debugPrintf("I Invalid (type = %x)", mobj->getType());
break;
}
- DebugPrintf(" \n");
+ debugPrintf(" \n");
}
}
- DebugPrintf("\n");
+ debugPrintf("\n");
return true;
}
bool Console::segmentInfo(int nr) {
- DebugPrintf("[%04x] ", nr);
+ debugPrintf("[%04x] ", nr);
if ((nr < 0) || ((uint)nr >= _engine->_gamestate->_segMan->_heap.size()) || !_engine->_gamestate->_segMan->_heap[nr])
return false;
@@ -1926,30 +1945,30 @@ bool Console::segmentInfo(int nr) {
case SEG_TYPE_SCRIPT: {
Script *scr = (Script *)mobj;
- DebugPrintf("script.%03d locked by %d, bufsize=%d (%x)\n", scr->getScriptNumber(), scr->getLockers(), (uint)scr->getBufSize(), (uint)scr->getBufSize());
+ debugPrintf("script.%03d locked by %d, bufsize=%d (%x)\n", scr->getScriptNumber(), scr->getLockers(), (uint)scr->getBufSize(), (uint)scr->getBufSize());
if (scr->getExportTable())
- DebugPrintf(" Exports: %4d at %d\n", scr->getExportsNr(), (int)(((const byte *)scr->getExportTable()) - ((const byte *)scr->getBuf())));
+ debugPrintf(" Exports: %4d at %d\n", scr->getExportsNr(), (int)(((const byte *)scr->getExportTable()) - ((const byte *)scr->getBuf())));
else
- DebugPrintf(" Exports: none\n");
+ debugPrintf(" Exports: none\n");
- DebugPrintf(" Synonyms: %4d\n", scr->getSynonymsNr());
+ debugPrintf(" Synonyms: %4d\n", scr->getSynonymsNr());
if (scr->getLocalsCount() > 0)
- DebugPrintf(" Locals : %4d in segment 0x%x\n", scr->getLocalsCount(), scr->getLocalsSegment());
+ debugPrintf(" Locals : %4d in segment 0x%x\n", scr->getLocalsCount(), scr->getLocalsSegment());
else
- DebugPrintf(" Locals : none\n");
+ debugPrintf(" Locals : none\n");
ObjMap objects = scr->getObjectMap();
- DebugPrintf(" Objects: %4d\n", objects.size());
+ debugPrintf(" Objects: %4d\n", objects.size());
ObjMap::iterator it;
const ObjMap::iterator end = objects.end();
for (it = objects.begin(); it != end; ++it) {
- DebugPrintf(" ");
+ debugPrintf(" ");
// Object header
const Object *obj = _engine->_gamestate->_segMan->getObject(it->_value.getPos());
if (obj)
- DebugPrintf("[%04x:%04x] %s : %3d vars, %3d methods\n", PRINT_REG(it->_value.getPos()),
+ debugPrintf("[%04x:%04x] %s : %3d vars, %3d methods\n", PRINT_REG(it->_value.getPos()),
_engine->_gamestate->_segMan->getObjectName(it->_value.getPos()),
obj->getVarCount(), obj->getMethodCount());
}
@@ -1958,31 +1977,31 @@ bool Console::segmentInfo(int nr) {
case SEG_TYPE_LOCALS: {
LocalVariables *locals = (LocalVariables *)mobj;
- DebugPrintf("locals for script.%03d\n", locals->script_id);
- DebugPrintf(" %d (0x%x) locals\n", locals->_locals.size(), locals->_locals.size());
+ debugPrintf("locals for script.%03d\n", locals->script_id);
+ debugPrintf(" %d (0x%x) locals\n", locals->_locals.size(), locals->_locals.size());
}
break;
case SEG_TYPE_STACK: {
DataStack *stack = (DataStack *)mobj;
- DebugPrintf("stack\n");
- DebugPrintf(" %d (0x%x) entries\n", stack->_capacity, stack->_capacity);
+ debugPrintf("stack\n");
+ debugPrintf(" %d (0x%x) entries\n", stack->_capacity, stack->_capacity);
}
break;
case SEG_TYPE_CLONES: {
CloneTable *ct = (CloneTable *)mobj;
- DebugPrintf("clones\n");
+ debugPrintf("clones\n");
for (uint i = 0; i < ct->_table.size(); i++)
if (ct->isValidEntry(i)) {
reg_t objpos = make_reg(nr, i);
- DebugPrintf(" [%04x] %s; copy of ", i, _engine->_gamestate->_segMan->getObjectName(objpos));
+ debugPrintf(" [%04x] %s; copy of ", i, _engine->_gamestate->_segMan->getObjectName(objpos));
// Object header
const Object *obj = _engine->_gamestate->_segMan->getObject(ct->_table[i].getPos());
if (obj)
- DebugPrintf("[%04x:%04x] %s : %3d vars, %3d methods\n", PRINT_REG(ct->_table[i].getPos()),
+ debugPrintf("[%04x:%04x] %s : %3d vars, %3d methods\n", PRINT_REG(ct->_table[i].getPos()),
_engine->_gamestate->_segMan->getObjectName(ct->_table[i].getPos()),
obj->getVarCount(), obj->getMethodCount());
}
@@ -1992,34 +2011,34 @@ bool Console::segmentInfo(int nr) {
case SEG_TYPE_LISTS: {
ListTable *lt = (ListTable *)mobj;
- DebugPrintf("lists\n");
+ debugPrintf("lists\n");
for (uint i = 0; i < lt->_table.size(); i++)
if (lt->isValidEntry(i)) {
- DebugPrintf(" [%04x]: ", i);
+ debugPrintf(" [%04x]: ", i);
printList(&(lt->_table[i]));
}
}
break;
case SEG_TYPE_NODES: {
- DebugPrintf("nodes (total %d)\n", (*(NodeTable *)mobj).entries_used);
+ debugPrintf("nodes (total %d)\n", (*(NodeTable *)mobj).entries_used);
break;
}
case SEG_TYPE_HUNK: {
HunkTable *ht = (HunkTable *)mobj;
- DebugPrintf("hunk (total %d)\n", ht->entries_used);
+ debugPrintf("hunk (total %d)\n", ht->entries_used);
for (uint i = 0; i < ht->_table.size(); i++)
if (ht->isValidEntry(i)) {
- DebugPrintf(" [%04x] %d bytes at %p, type=%s\n",
+ debugPrintf(" [%04x] %d bytes at %p, type=%s\n",
i, ht->_table[i].size, ht->_table[i].mem, ht->_table[i].type);
}
}
break;
case SEG_TYPE_DYNMEM: {
- DebugPrintf("dynmem (%s): %d bytes\n",
+ debugPrintf("dynmem (%s): %d bytes\n",
(*(DynMem *)mobj)._description.c_str(), (*(DynMem *)mobj)._size);
Common::hexdump((*(DynMem *)mobj)._buf, (*(DynMem *)mobj)._size, 16, 0);
@@ -2028,28 +2047,28 @@ bool Console::segmentInfo(int nr) {
#ifdef ENABLE_SCI32
case SEG_TYPE_STRING:
- DebugPrintf("SCI32 strings\n");
+ debugPrintf("SCI32 strings\n");
break;
case SEG_TYPE_ARRAY:
- DebugPrintf("SCI32 arrays\n");
+ debugPrintf("SCI32 arrays\n");
break;
#endif
default :
- DebugPrintf("Invalid type %d\n", mobj->getType());
+ debugPrintf("Invalid type %d\n", mobj->getType());
break;
}
- DebugPrintf("\n");
+ debugPrintf("\n");
return true;
}
bool Console::cmdSegmentInfo(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Provides information on the specified segment(s)\n");
- DebugPrintf("Usage: %s <segment number>\n", argv[0]);
- DebugPrintf("<segment number> can be a number, which shows the information of the segment with\n");
- DebugPrintf("the specified number, or \"all\" to show information on all active segments\n");
+ debugPrintf("Provides information on the specified segment(s)\n");
+ debugPrintf("Usage: %s <segment number>\n", argv[0]);
+ debugPrintf("<segment number> can be a number, which shows the information of the segment with\n");
+ debugPrintf("the specified number, or \"all\" to show information on all active segments\n");
return true;
}
@@ -2061,7 +2080,7 @@ bool Console::cmdSegmentInfo(int argc, const char **argv) {
if (!parseInteger(argv[1], segmentNr))
return true;
if (!segmentInfo(segmentNr))
- DebugPrintf("Segment %04xh does not exist\n", segmentNr);
+ debugPrintf("Segment %04xh does not exist\n", segmentNr);
}
return true;
@@ -2070,8 +2089,8 @@ bool Console::cmdSegmentInfo(int argc, const char **argv) {
bool Console::cmdKillSegment(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Deletes the specified segment\n");
- DebugPrintf("Usage: %s <segment number>\n", argv[0]);
+ debugPrintf("Deletes the specified segment\n");
+ debugPrintf("Usage: %s <segment number>\n", argv[0]);
return true;
}
int segmentNumber;
@@ -2084,13 +2103,13 @@ bool Console::cmdKillSegment(int argc, const char **argv) {
bool Console::cmdShowMap(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Switches to one of the following screen maps\n");
- DebugPrintf("Usage: %s <screen map>\n", argv[0]);
- DebugPrintf("Screen maps:\n");
- DebugPrintf("- 0: visual map\n");
- DebugPrintf("- 1: priority map\n");
- DebugPrintf("- 2: control map\n");
- DebugPrintf("- 3: display screen\n");
+ debugPrintf("Switches to one of the following screen maps\n");
+ debugPrintf("Usage: %s <screen map>\n", argv[0]);
+ debugPrintf("Screen maps:\n");
+ debugPrintf("- 0: visual map\n");
+ debugPrintf("- 1: priority map\n");
+ debugPrintf("- 2: control map\n");
+ debugPrintf("- 3: display screen\n");
return true;
}
@@ -2105,14 +2124,14 @@ bool Console::cmdShowMap(int argc, const char **argv) {
break;
default:
- DebugPrintf("Map %d is not available.\n", map);
+ debugPrintf("Map %d is not available.\n", map);
return true;
}
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdSongLib(int argc, const char **argv) {
- DebugPrintf("Song library:\n");
+ debugPrintf("Song library:\n");
g_sci->_soundCmd->printPlayList(this);
return true;
@@ -2120,16 +2139,16 @@ bool Console::cmdSongLib(int argc, const char **argv) {
bool Console::cmdSongInfo(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Shows information about a given song in the playlist\n");
- DebugPrintf("Usage: %s <song object>\n", argv[0]);
+ debugPrintf("Shows information about a given song in the playlist\n");
+ debugPrintf("Usage: %s <song object>\n", argv[0]);
return true;
}
reg_t addr;
if (parse_reg_t(_engine->_gamestate, argv[1], &addr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2140,38 +2159,38 @@ bool Console::cmdSongInfo(int argc, const char **argv) {
bool Console::cmdStartSound(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Adds the requested sound resource to the playlist, and starts playing it\n");
- DebugPrintf("Usage: %s <sound resource id>\n", argv[0]);
+ debugPrintf("Adds the requested sound resource to the playlist, and starts playing it\n");
+ debugPrintf("Usage: %s <sound resource id>\n", argv[0]);
return true;
}
int16 number = atoi(argv[1]);
if (!_engine->getResMan()->testResource(ResourceId(kResourceTypeSound, number))) {
- DebugPrintf("Unable to load this sound resource, most probably it has an equivalent audio resource (SCI1.1)\n");
+ debugPrintf("Unable to load this sound resource, most probably it has an equivalent audio resource (SCI1.1)\n");
return true;
}
g_sci->_soundCmd->startNewSound(number);
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdToggleSound(int argc, const char **argv) {
if (argc != 3) {
- DebugPrintf("Plays or stops the specified sound in the playlist\n");
- DebugPrintf("Usage: %s <address> <state>\n", argv[0]);
- DebugPrintf("Where:\n");
- DebugPrintf("- <address> is the address of the sound to play or stop.\n");
- DebugPrintf("- <state> is the new state (play or stop).\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Plays or stops the specified sound in the playlist\n");
+ debugPrintf("Usage: %s <address> <state>\n", argv[0]);
+ debugPrintf("Where:\n");
+ debugPrintf("- <address> is the address of the sound to play or stop.\n");
+ debugPrintf("- <state> is the new state (play or stop).\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t id;
if (parse_reg_t(_engine->_gamestate, argv[1], &id, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2183,7 +2202,7 @@ bool Console::cmdToggleSound(int argc, const char **argv) {
else if (newState == "stop")
g_sci->_soundCmd->processStopSound(id, false);
else
- DebugPrintf("New state can either be 'play' or 'stop'");
+ debugPrintf("New state can either be 'play' or 'stop'");
return true;
}
@@ -2191,40 +2210,40 @@ bool Console::cmdToggleSound(int argc, const char **argv) {
bool Console::cmdStopAllSounds(int argc, const char **argv) {
g_sci->_soundCmd->stopAllSounds();
- DebugPrintf("All sounds have been stopped\n");
+ debugPrintf("All sounds have been stopped\n");
return true;
}
bool Console::cmdIsSample(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Tests whether a given sound resource is a PCM sample, \n");
- DebugPrintf("and displays information on it if it is.\n");
- DebugPrintf("Usage: %s <sample id>\n", argv[0]);
+ debugPrintf("Tests whether a given sound resource is a PCM sample, \n");
+ debugPrintf("and displays information on it if it is.\n");
+ debugPrintf("Usage: %s <sample id>\n", argv[0]);
return true;
}
int16 number = atoi(argv[1]);
if (!_engine->getResMan()->testResource(ResourceId(kResourceTypeSound, number))) {
- DebugPrintf("Unable to load this sound resource, most probably it has an equivalent audio resource (SCI1.1)\n");
+ debugPrintf("Unable to load this sound resource, most probably it has an equivalent audio resource (SCI1.1)\n");
return true;
}
SoundResource *soundRes = new SoundResource(number, _engine->getResMan(), _engine->_features->detectDoSoundType());
if (!soundRes) {
- DebugPrintf("Not a sound resource!\n");
+ debugPrintf("Not a sound resource!\n");
return true;
}
SoundResource::Track *track = soundRes->getDigitalTrack();
if (!track || track->digitalChannelNr == -1) {
- DebugPrintf("Valid song, but not a sample.\n");
+ debugPrintf("Valid song, but not a sample.\n");
delete soundRes;
return true;
}
- DebugPrintf("Sample size: %d, sample rate: %d, channels: %d, digital channel number: %d\n",
+ debugPrintf("Sample size: %d, sample rate: %d, channels: %d, digital channel number: %d\n",
track->digitalSampleSize, track->digitalSampleRate, track->channelCount, track->digitalChannelNr);
delete soundRes;
@@ -2232,7 +2251,7 @@ bool Console::cmdIsSample(int argc, const char **argv) {
}
bool Console::cmdGCInvoke(int argc, const char **argv) {
- DebugPrintf("Performing garbage collection...\n");
+ debugPrintf("Performing garbage collection...\n");
run_gc(_engine->_gamestate);
return true;
}
@@ -2240,9 +2259,9 @@ bool Console::cmdGCInvoke(int argc, const char **argv) {
bool Console::cmdGCObjects(int argc, const char **argv) {
AddrSet *use_map = findAllActiveReferences(_engine->_gamestate);
- DebugPrintf("Reachable object references (normalised):\n");
+ debugPrintf("Reachable object references (normalised):\n");
for (AddrSet::iterator i = use_map->begin(); i != use_map->end(); ++i) {
- DebugPrintf(" - %04x:%04x\n", PRINT_REG(i->_key));
+ debugPrintf(" - %04x:%04x\n", PRINT_REG(i->_key));
}
delete use_map;
@@ -2252,93 +2271,93 @@ bool Console::cmdGCObjects(int argc, const char **argv) {
bool Console::cmdGCShowReachable(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Prints all addresses directly reachable from the memory object specified as parameter.\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Prints all addresses directly reachable from the memory object specified as parameter.\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t addr;
if (parse_reg_t(_engine->_gamestate, argv[1], &addr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
SegmentObj *mobj = _engine->_gamestate->_segMan->getSegmentObj(addr.getSegment());
if (!mobj) {
- DebugPrintf("Unknown segment : %x\n", addr.getSegment());
+ debugPrintf("Unknown segment : %x\n", addr.getSegment());
return 1;
}
- DebugPrintf("Reachable from %04x:%04x:\n", PRINT_REG(addr));
+ debugPrintf("Reachable from %04x:%04x:\n", PRINT_REG(addr));
const Common::Array<reg_t> tmp = mobj->listAllOutgoingReferences(addr);
for (Common::Array<reg_t>::const_iterator it = tmp.begin(); it != tmp.end(); ++it)
if (it->getSegment())
- g_sci->getSciDebugger()->DebugPrintf(" %04x:%04x\n", PRINT_REG(*it));
+ g_sci->getSciDebugger()->debugPrintf(" %04x:%04x\n", PRINT_REG(*it));
return true;
}
bool Console::cmdGCShowFreeable(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Prints all addresses freeable in the segment associated with the\n");
- DebugPrintf("given address (offset is ignored).\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Prints all addresses freeable in the segment associated with the\n");
+ debugPrintf("given address (offset is ignored).\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t addr;
if (parse_reg_t(_engine->_gamestate, argv[1], &addr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
SegmentObj *mobj = _engine->_gamestate->_segMan->getSegmentObj(addr.getSegment());
if (!mobj) {
- DebugPrintf("Unknown segment : %x\n", addr.getSegment());
+ debugPrintf("Unknown segment : %x\n", addr.getSegment());
return true;
}
- DebugPrintf("Freeable in segment %04x:\n", addr.getSegment());
+ debugPrintf("Freeable in segment %04x:\n", addr.getSegment());
const Common::Array<reg_t> tmp = mobj->listAllDeallocatable(addr.getSegment());
for (Common::Array<reg_t>::const_iterator it = tmp.begin(); it != tmp.end(); ++it)
if (it->getSegment())
- g_sci->getSciDebugger()->DebugPrintf(" %04x:%04x\n", PRINT_REG(*it));
+ g_sci->getSciDebugger()->debugPrintf(" %04x:%04x\n", PRINT_REG(*it));
return true;
}
bool Console::cmdGCNormalize(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Prints the \"normal\" address of a given address,\n");
- DebugPrintf("i.e. the address we would free in order to free\n");
- DebugPrintf("the object associated with the original address.\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Prints the \"normal\" address of a given address,\n");
+ debugPrintf("i.e. the address we would free in order to free\n");
+ debugPrintf("the object associated with the original address.\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t addr;
if (parse_reg_t(_engine->_gamestate, argv[1], &addr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
SegmentObj *mobj = _engine->_gamestate->_segMan->getSegmentObj(addr.getSegment());
if (!mobj) {
- DebugPrintf("Unknown segment : %x\n", addr.getSegment());
+ debugPrintf("Unknown segment : %x\n", addr.getSegment());
return true;
}
addr = mobj->findCanonicAddress(_engine->_gamestate->_segMan, addr);
- DebugPrintf(" %04x:%04x\n", PRINT_REG(addr));
+ debugPrintf(" %04x:%04x\n", PRINT_REG(addr));
return true;
}
@@ -2347,12 +2366,12 @@ bool Console::cmdVMVarlist(int argc, const char **argv) {
EngineState *s = _engine->_gamestate;
const char *varnames[] = {"global", "local", "temp", "param"};
- DebugPrintf("Addresses of variables in the VM:\n");
+ debugPrintf("Addresses of variables in the VM:\n");
for (int i = 0; i < 4; i++) {
- DebugPrintf("%s vars at %04x:%04x ", varnames[i], PRINT_REG(make_reg(s->variablesSegment[i], s->variables[i] - s->variablesBase[i])));
- DebugPrintf(" total %d", s->variablesMax[i]);
- DebugPrintf("\n");
+ debugPrintf("%s vars at %04x:%04x ", varnames[i], PRINT_REG(make_reg(s->variablesSegment[i], s->variables[i] - s->variablesBase[i])));
+ debugPrintf(" total %d", s->variablesMax[i]);
+ debugPrintf("\n");
}
return true;
@@ -2360,12 +2379,12 @@ bool Console::cmdVMVarlist(int argc, const char **argv) {
bool Console::cmdVMVars(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Displays or changes variables in the VM\n");
- DebugPrintf("Usage: %s <type> <varnum> [<value>]\n", argv[0]);
- DebugPrintf("First parameter is either g(lobal), l(ocal), t(emp), p(aram) or a(cc).\n");
- DebugPrintf("Second parameter is the var number (not specified on acc)\n");
- DebugPrintf("Third parameter (if specified) is the value to set the variable to, in address form\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Displays or changes variables in the VM\n");
+ debugPrintf("Usage: %s <type> <varnum> [<value>]\n", argv[0]);
+ debugPrintf("First parameter is either g(lobal), l(ocal), t(emp), p(aram) or a(cc).\n");
+ debugPrintf("Second parameter is the var number (not specified on acc)\n");
+ debugPrintf("Third parameter (if specified) is the value to set the variable to, in address form\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2379,7 +2398,7 @@ bool Console::cmdVMVars(int argc, const char **argv) {
const char *setValue = NULL;
if (!varType_pre) {
- DebugPrintf("Invalid variable type '%c'\n", *argv[1]);
+ debugPrintf("Invalid variable type '%c'\n", *argv[1]);
return true;
}
@@ -2392,11 +2411,11 @@ bool Console::cmdVMVars(int argc, const char **argv) {
case 3: {
// for global, local, temp and param, we need an index
if (argc < 3) {
- DebugPrintf("Variable number must be specified for requested type\n");
+ debugPrintf("Variable number must be specified for requested type\n");
return true;
}
if (argc > 4) {
- DebugPrintf("Too many arguments\n");
+ debugPrintf("Too many arguments\n");
return true;
}
@@ -2404,12 +2423,12 @@ bool Console::cmdVMVars(int argc, const char **argv) {
return true;
if (varIndex < 0) {
- DebugPrintf("Variable number may not be negative\n");
+ debugPrintf("Variable number may not be negative\n");
return true;
}
if (s->variablesMax[varType] <= varIndex) {
- DebugPrintf("Maximum variable number for this type is %d (0x%x)\n", s->variablesMax[varType], s->variablesMax[varType]);
+ debugPrintf("Maximum variable number for this type is %d (0x%x)\n", s->variablesMax[varType], s->variablesMax[varType]);
return true;
}
curValue = &s->variables[varType][varIndex];
@@ -2421,7 +2440,7 @@ bool Console::cmdVMVars(int argc, const char **argv) {
case 4:
// acc
if (argc > 3) {
- DebugPrintf("Too many arguments\n");
+ debugPrintf("Too many arguments\n");
return true;
}
curValue = &s->r_acc;
@@ -2435,16 +2454,16 @@ bool Console::cmdVMVars(int argc, const char **argv) {
if (!setValue) {
if (varType == 4)
- DebugPrintf("%s == %04x:%04x", varNames[varType], PRINT_REG(*curValue));
+ debugPrintf("%s == %04x:%04x", varNames[varType], PRINT_REG(*curValue));
else
- DebugPrintf("%s var %d == %04x:%04x", varNames[varType], varIndex, PRINT_REG(*curValue));
+ debugPrintf("%s var %d == %04x:%04x", varNames[varType], varIndex, PRINT_REG(*curValue));
printBasicVarInfo(*curValue);
- DebugPrintf("\n");
+ debugPrintf("\n");
} else {
if (parse_reg_t(s, setValue, curValue, true)) {
- DebugPrintf("Invalid value/address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
- DebugPrintf("Or pass a decimal or hexadecimal value directly (e.g. 12, 1Ah)\n");
+ debugPrintf("Invalid value/address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Or pass a decimal or hexadecimal value directly (e.g. 12, 1Ah)\n");
return true;
}
}
@@ -2453,13 +2472,13 @@ bool Console::cmdVMVars(int argc, const char **argv) {
bool Console::cmdStack(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Lists the specified number of stack elements.\n");
- DebugPrintf("Usage: %s <elements>\n", argv[0]);
+ debugPrintf("Lists the specified number of stack elements.\n");
+ debugPrintf("Usage: %s <elements>\n", argv[0]);
return true;
}
if (_engine->_gamestate->_executionStack.empty()) {
- DebugPrintf("No exec stack!");
+ debugPrintf("No exec stack!");
return true;
}
@@ -2468,9 +2487,9 @@ bool Console::cmdStack(int argc, const char **argv) {
for (int i = nr; i > 0; i--) {
if ((xs.sp - xs.fp - i) == 0)
- DebugPrintf("-- temp variables --\n");
+ debugPrintf("-- temp variables --\n");
if (xs.sp - i >= _engine->_gamestate->stack_base)
- DebugPrintf("ST:%04x = %04x:%04x\n", (unsigned)(xs.sp - i - _engine->_gamestate->stack_base), PRINT_REG(xs.sp[-i]));
+ debugPrintf("ST:%04x = %04x:%04x\n", (unsigned)(xs.sp - i - _engine->_gamestate->stack_base), PRINT_REG(xs.sp[-i]));
}
return true;
@@ -2478,19 +2497,19 @@ bool Console::cmdStack(int argc, const char **argv) {
bool Console::cmdValueType(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Determines the type of a value.\n");
- DebugPrintf("The type can be one of the following:\n");
- DebugPrintf("Invalid, list, object, reference or arithmetic\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Determines the type of a value.\n");
+ debugPrintf("The type can be one of the following:\n");
+ debugPrintf("Invalid, list, object, reference or arithmetic\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t val;
if (parse_reg_t(_engine->_gamestate, argv[1], &val, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2498,22 +2517,22 @@ bool Console::cmdValueType(int argc, const char **argv) {
switch (t) {
case SIG_TYPE_LIST:
- DebugPrintf("List");
+ debugPrintf("List");
break;
case SIG_TYPE_OBJECT:
- DebugPrintf("Object");
+ debugPrintf("Object");
break;
case SIG_TYPE_REFERENCE:
- DebugPrintf("Reference");
+ debugPrintf("Reference");
break;
case SIG_TYPE_INTEGER:
- DebugPrintf("Integer");
+ debugPrintf("Integer");
break;
case SIG_TYPE_INTEGER | SIG_TYPE_NULL:
- DebugPrintf("Null");
+ debugPrintf("Null");
break;
default:
- DebugPrintf("Erroneous unknown type 0x%02x (%d decimal)\n", t, t);
+ debugPrintf("Erroneous unknown type 0x%02x (%d decimal)\n", t, t);
}
return true;
@@ -2521,17 +2540,17 @@ bool Console::cmdValueType(int argc, const char **argv) {
bool Console::cmdViewListNode(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Examines the list node at the given address.\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Examines the list node at the given address.\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t addr;
if (parse_reg_t(_engine->_gamestate, argv[1], &addr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2541,11 +2560,11 @@ bool Console::cmdViewListNode(int argc, const char **argv) {
bool Console::cmdViewReference(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Examines an arbitrary reference.\n");
- DebugPrintf("Usage: %s <start address> [<end address>]\n", argv[0]);
- DebugPrintf("Where <start address> is the starting address to examine\n");
- DebugPrintf("<end address>, if provided, is the address where examining ends at\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Examines an arbitrary reference.\n");
+ debugPrintf("Usage: %s <start address> [<end address>]\n", argv[0]);
+ debugPrintf("Where <start address> is the starting address to examine\n");
+ debugPrintf("<end address>, if provided, is the address where examining ends at\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2553,15 +2572,15 @@ bool Console::cmdViewReference(int argc, const char **argv) {
reg_t reg_end = NULL_REG;
if (parse_reg_t(_engine->_gamestate, argv[1], &reg, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
if (argc > 2) {
if (parse_reg_t(_engine->_gamestate, argv[2], &reg_end, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
}
@@ -2570,15 +2589,15 @@ bool Console::cmdViewReference(int argc, const char **argv) {
int filter;
int found = 0;
- DebugPrintf("%04x:%04x is of type 0x%x: ", PRINT_REG(reg), type_mask);
+ debugPrintf("%04x:%04x is of type 0x%x: ", PRINT_REG(reg), type_mask);
if (reg.getSegment() == 0 && reg.getOffset() == 0) {
- DebugPrintf("Null.\n");
+ debugPrintf("Null.\n");
return true;
}
if (reg_end.getSegment() != reg.getSegment() && reg_end != NULL_REG) {
- DebugPrintf("Ending segment different from starting segment. Assuming no bound on dump.\n");
+ debugPrintf("Ending segment different from starting segment. Assuming no bound on dump.\n");
reg_end = NULL_REG;
}
@@ -2586,7 +2605,7 @@ bool Console::cmdViewReference(int argc, const char **argv) {
int type = type_mask & filter;
if (found && type) {
- DebugPrintf("--- Alternatively, it could be a ");
+ debugPrintf("--- Alternatively, it could be a ");
}
@@ -2596,33 +2615,33 @@ bool Console::cmdViewReference(int argc, const char **argv) {
case SIG_TYPE_LIST: {
List *list = _engine->_gamestate->_segMan->lookupList(reg);
- DebugPrintf("list\n");
+ debugPrintf("list\n");
if (list)
printList(list);
else
- DebugPrintf("Invalid list.\n");
+ debugPrintf("Invalid list.\n");
}
break;
case SIG_TYPE_NODE:
- DebugPrintf("list node\n");
+ debugPrintf("list node\n");
printNode(reg);
break;
case SIG_TYPE_OBJECT:
- DebugPrintf("object\n");
+ debugPrintf("object\n");
printObject(reg);
break;
case SIG_TYPE_REFERENCE: {
switch (_engine->_gamestate->_segMan->getSegmentType(reg.getSegment())) {
#ifdef ENABLE_SCI32
case SEG_TYPE_STRING: {
- DebugPrintf("SCI32 string\n");
+ debugPrintf("SCI32 string\n");
const SciString *str = _engine->_gamestate->_segMan->lookupString(reg);
Common::hexdump((const byte *) str->getRawData(), str->getSize(), 16, 0);
break;
}
case SEG_TYPE_ARRAY: {
- DebugPrintf("SCI32 array:\n");
+ debugPrintf("SCI32 array:\n");
const SciArray<reg_t> *array = _engine->_gamestate->_segMan->lookupArray(reg);
hexDumpReg(array->getRawData(), array->getSize(), 4, 0, true);
break;
@@ -2632,10 +2651,10 @@ bool Console::cmdViewReference(int argc, const char **argv) {
const SegmentRef block = _engine->_gamestate->_segMan->dereference(reg);
uint16 size = block.maxSize;
- DebugPrintf("raw data\n");
+ debugPrintf("raw data\n");
if (reg_end.getSegment() != 0 && (size < reg_end.getOffset() - reg.getOffset())) {
- DebugPrintf("Block end out of bounds (size %d). Resetting.\n", size);
+ debugPrintf("Block end out of bounds (size %d). Resetting.\n", size);
reg_end = NULL_REG;
}
@@ -2643,7 +2662,7 @@ bool Console::cmdViewReference(int argc, const char **argv) {
size = reg_end.getOffset() - reg.getOffset();
if (reg_end.getSegment() != 0)
- DebugPrintf("Block size less than or equal to %d\n", size);
+ debugPrintf("Block size less than or equal to %d\n", size);
if (block.isRaw)
Common::hexdump(block.raw, size, 16, 0);
@@ -2654,14 +2673,14 @@ bool Console::cmdViewReference(int argc, const char **argv) {
break;
}
case SIG_TYPE_INTEGER:
- DebugPrintf("arithmetic value\n %d (%04x)\n", (int16) reg.getOffset(), reg.getOffset());
+ debugPrintf("arithmetic value\n %d (%04x)\n", (int16) reg.getOffset(), reg.getOffset());
break;
default:
- DebugPrintf("unknown type %d.\n", type);
+ debugPrintf("unknown type %d.\n", type);
}
if (type) {
- DebugPrintf("\n");
+ debugPrintf("\n");
found = 1;
}
}
@@ -2671,47 +2690,47 @@ bool Console::cmdViewReference(int argc, const char **argv) {
bool Console::cmdViewObject(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Examines the object at the given address.\n");
- DebugPrintf("Usage: %s <address>\n", argv[0]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Examines the object at the given address.\n");
+ debugPrintf("Usage: %s <address>\n", argv[0]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
reg_t addr;
if (parse_reg_t(_engine->_gamestate, argv[1], &addr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
- DebugPrintf("Information on the object at the given address:\n");
+ debugPrintf("Information on the object at the given address:\n");
printObject(addr);
return true;
}
bool Console::cmdViewActiveObject(int argc, const char **argv) {
- DebugPrintf("Information on the currently active object or class:\n");
+ debugPrintf("Information on the currently active object or class:\n");
printObject(_engine->_gamestate->xs->objp);
return true;
}
bool Console::cmdViewAccumulatorObject(int argc, const char **argv) {
- DebugPrintf("Information on the currently active object or class at the address indexed by the accumulator:\n");
+ debugPrintf("Information on the currently active object or class at the address indexed by the accumulator:\n");
printObject(_engine->_gamestate->r_acc);
return true;
}
bool Console::cmdScriptSteps(int argc, const char **argv) {
- DebugPrintf("Number of executed SCI operations: %d\n", _engine->_gamestate->scriptStepCounter);
+ debugPrintf("Number of executed SCI operations: %d\n", _engine->_gamestate->scriptStepCounter);
return true;
}
bool Console::cmdBacktrace(int argc, const char **argv) {
- DebugPrintf("Call stack (current base: 0x%x):\n", _engine->_gamestate->executionStackBase);
+ debugPrintf("Call stack (current base: 0x%x):\n", _engine->_gamestate->executionStackBase);
Common::List<ExecStack>::const_iterator iter;
uint i = 0;
@@ -2724,22 +2743,22 @@ bool Console::cmdBacktrace(int argc, const char **argv) {
switch (call.type) {
case EXEC_STACK_TYPE_CALL: // Normal function
if (call.type == EXEC_STACK_TYPE_CALL)
- DebugPrintf(" %x: script %d - ", i, (*(Script *)_engine->_gamestate->_segMan->_heap[call.addr.pc.getSegment()]).getScriptNumber());
+ debugPrintf(" %x: script %d - ", i, (*(Script *)_engine->_gamestate->_segMan->_heap[call.addr.pc.getSegment()]).getScriptNumber());
if (call.debugSelector != -1) {
- DebugPrintf("%s::%s(", objname, _engine->getKernel()->getSelectorName(call.debugSelector).c_str());
+ debugPrintf("%s::%s(", objname, _engine->getKernel()->getSelectorName(call.debugSelector).c_str());
} else if (call.debugExportId != -1) {
- DebugPrintf("export %d (", call.debugExportId);
+ debugPrintf("export %d (", call.debugExportId);
} else if (call.debugLocalCallOffset != -1) {
- DebugPrintf("call %x (", call.debugLocalCallOffset);
+ debugPrintf("call %x (", call.debugLocalCallOffset);
}
break;
case EXEC_STACK_TYPE_KERNEL: // Kernel function
- DebugPrintf(" %x:[%x] k%s(", i, call.debugOrigin, _engine->getKernel()->getKernelName(call.debugSelector).c_str());
+ debugPrintf(" %x:[%x] k%s(", i, call.debugOrigin, _engine->getKernel()->getKernelName(call.debugSelector).c_str());
break;
case EXEC_STACK_TYPE_VARSELECTOR:
- DebugPrintf(" %x:[%x] vs%s %s::%s (", i, call.debugOrigin, (call.argc) ? "write" : "read",
+ debugPrintf(" %x:[%x] vs%s %s::%s (", i, call.debugOrigin, (call.argc) ? "write" : "read",
objname, _engine->getKernel()->getSelectorName(call.debugSelector).c_str());
break;
}
@@ -2750,32 +2769,32 @@ bool Console::cmdBacktrace(int argc, const char **argv) {
totalparamc = 16;
for (paramc = 1; paramc <= totalparamc; paramc++) {
- DebugPrintf("%04x:%04x", PRINT_REG(call.variables_argp[paramc]));
+ debugPrintf("%04x:%04x", PRINT_REG(call.variables_argp[paramc]));
if (paramc < call.argc)
- DebugPrintf(", ");
+ debugPrintf(", ");
}
if (call.argc > 16)
- DebugPrintf("...");
+ debugPrintf("...");
- DebugPrintf(")\n ");
+ debugPrintf(")\n ");
if (call.debugOrigin != -1)
- DebugPrintf("by %x ", call.debugOrigin);
- DebugPrintf("obj@%04x:%04x", PRINT_REG(call.objp));
+ debugPrintf("by %x ", call.debugOrigin);
+ debugPrintf("obj@%04x:%04x", PRINT_REG(call.objp));
if (call.type == EXEC_STACK_TYPE_CALL) {
- DebugPrintf(" pc=%04x:%04x", PRINT_REG(call.addr.pc));
+ debugPrintf(" pc=%04x:%04x", PRINT_REG(call.addr.pc));
if (call.sp == CALL_SP_CARRY)
- DebugPrintf(" sp,fp:carry");
+ debugPrintf(" sp,fp:carry");
else {
- DebugPrintf(" sp=ST:%04x", (unsigned)(call.sp - _engine->_gamestate->stack_base));
- DebugPrintf(" fp=ST:%04x", (unsigned)(call.fp - _engine->_gamestate->stack_base));
+ debugPrintf(" sp=ST:%04x", (unsigned)(call.sp - _engine->_gamestate->stack_base));
+ debugPrintf(" fp=ST:%04x", (unsigned)(call.fp - _engine->_gamestate->stack_base));
}
} else
- DebugPrintf(" pc:none");
+ debugPrintf(" pc:none");
- DebugPrintf(" argp:ST:%04x", (unsigned)(call.variables_argp - _engine->_gamestate->stack_base));
- DebugPrintf("\n");
+ debugPrintf(" argp:ST:%04x", (unsigned)(call.variables_argp - _engine->_gamestate->stack_base));
+ debugPrintf("\n");
}
return true;
@@ -2786,7 +2805,7 @@ bool Console::cmdTrace(int argc, const char **argv) {
_debugState.runningStep = atoi(argv[1]) - 1;
_debugState.debugging = true;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdStepOver(int argc, const char **argv) {
@@ -2794,14 +2813,14 @@ bool Console::cmdStepOver(int argc, const char **argv) {
_debugState.seekLevel = _engine->_gamestate->_executionStack.size();
_debugState.debugging = true;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdStepEvent(int argc, const char **argv) {
_debugState.stopOnEvent = true;
_debugState.debugging = true;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdStepRet(int argc, const char **argv) {
@@ -2809,13 +2828,13 @@ bool Console::cmdStepRet(int argc, const char **argv) {
_debugState.seekLevel = _engine->_gamestate->_executionStack.size() - 1;
_debugState.debugging = true;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdStepGlobal(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Steps until the global variable with the specified index is modified.\n");
- DebugPrintf("Usage: %s <global variable index>\n", argv[0]);
+ debugPrintf("Steps until the global variable with the specified index is modified.\n");
+ debugPrintf("Usage: %s <global variable index>\n", argv[0]);
return true;
}
@@ -2823,7 +2842,7 @@ bool Console::cmdStepGlobal(int argc, const char **argv) {
_debugState.seekSpecial = atoi(argv[1]);
_debugState.debugging = true;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdStepCallk(int argc, const char **argv) {
@@ -2844,7 +2863,7 @@ bool Console::cmdStepCallk(int argc, const char **argv) {
}
if (callk_index == -1) {
- DebugPrintf("Unknown kernel function '%s'\n", argv[1]);
+ debugPrintf("Unknown kernel function '%s'\n", argv[1]);
return true;
}
}
@@ -2856,16 +2875,16 @@ bool Console::cmdStepCallk(int argc, const char **argv) {
}
_debugState.debugging = true;
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdDisassemble(int argc, const char **argv) {
if (argc < 3) {
- DebugPrintf("Disassembles a method by name.\n");
- DebugPrintf("Usage: %s <object> <method> <options>\n", argv[0]);
- DebugPrintf("Valid options are:\n");
- DebugPrintf(" bwt : Print byte/word tag\n");
- DebugPrintf(" bc : Print bytecode\n");
+ debugPrintf("Disassembles a method by name.\n");
+ debugPrintf("Usage: %s <object> <method> <options>\n", argv[0]);
+ debugPrintf("Valid options are:\n");
+ debugPrintf(" bwt : Print byte/word tag\n");
+ debugPrintf(" bc : Print bytecode\n");
return true;
}
@@ -2874,8 +2893,8 @@ bool Console::cmdDisassemble(int argc, const char **argv) {
bool printBWTag = false;
if (parse_reg_t(_engine->_gamestate, argv[1], &objAddr, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2884,17 +2903,17 @@ bool Console::cmdDisassemble(int argc, const char **argv) {
reg_t addr = NULL_REG;
if (!obj) {
- DebugPrintf("Not an object.\n");
+ debugPrintf("Not an object.\n");
return true;
}
if (selectorId < 0) {
- DebugPrintf("Not a valid selector name.\n");
+ debugPrintf("Not a valid selector name.\n");
return true;
}
if (lookupSelector(_engine->_gamestate->_segMan, objAddr, selectorId, NULL, &addr) != kSelectorMethod) {
- DebugPrintf("Not a method.\n");
+ debugPrintf("Not a method.\n");
return true;
}
@@ -2924,12 +2943,12 @@ bool Console::cmdDisassemble(int argc, const char **argv) {
bool Console::cmdDisassembleAddress(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Disassembles one or more commands.\n");
- DebugPrintf("Usage: %s [startaddr] <options>\n", argv[0]);
- DebugPrintf("Valid options are:\n");
- DebugPrintf(" bwt : Print byte/word tag\n");
- DebugPrintf(" c<x> : Disassemble <x> bytes\n");
- DebugPrintf(" bc : Print bytecode\n");
+ debugPrintf("Disassembles one or more commands.\n");
+ debugPrintf("Usage: %s [startaddr] <options>\n", argv[0]);
+ debugPrintf("Valid options are:\n");
+ debugPrintf(" bwt : Print byte/word tag\n");
+ debugPrintf(" c<x> : Disassemble <x> bytes\n");
+ debugPrintf(" bc : Print bytecode\n");
return true;
}
@@ -2940,8 +2959,8 @@ bool Console::cmdDisassembleAddress(int argc, const char **argv) {
uint16 size;
if (parse_reg_t(_engine->_gamestate, argv[1], &vpc, false)) {
- DebugPrintf("Invalid address passed.\n");
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address passed.\n");
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -2956,7 +2975,7 @@ bool Console::cmdDisassembleAddress(int argc, const char **argv) {
else if (toupper(argv[i][0]) == 'C')
opCount = atoi(argv[i] + 1);
else {
- DebugPrintf("Invalid option '%s'\n", argv[i]);
+ debugPrintf("Invalid option '%s'\n", argv[i]);
return true;
}
}
@@ -2974,13 +2993,13 @@ void Console::printKernelCallsFound(int kernelFuncNum, bool showFoundScripts) {
Common::sort(resources.begin(), resources.end());
if (showFoundScripts)
- DebugPrintf("%d scripts found, dissassembling...\n", resources.size());
+ debugPrintf("%d scripts found, dissassembling...\n", resources.size());
int scriptSegment;
Script *script;
// Create a custom segment manager here, so that the game's segment
// manager won't be affected by loading and unloading scripts here.
- SegManager *customSegMan = new SegManager(_engine->getResMan());
+ SegManager *customSegMan = new SegManager(_engine->getResMan(), _engine->getScriptPatcher());
Common::List<ResourceId>::iterator itr;
for (itr = resources.begin(); itr != resources.end(); ++itr) {
@@ -3023,7 +3042,7 @@ void Console::printKernelCallsFound(int kernelFuncNum, bool showFoundScripts) {
uint16 argc2 = opparams[1];
if (kFuncNum == kernelFuncNum) {
- DebugPrintf("Called from script %d, object %s, method %s(%d) with %d bytes for arguments\n",
+ debugPrintf("Called from script %d, object %s, method %s(%d) with %d bytes for arguments\n",
itr->getNumber(), objName,
_engine->getKernel()->getSelectorName(obj->getFuncSelector(i)).c_str(), i, argc2);
}
@@ -3055,19 +3074,19 @@ void Console::printKernelCallsFound(int kernelFuncNum, bool showFoundScripts) {
bool Console::cmdFindKernelFunctionCall(int argc, const char **argv) {
if (argc < 2) {
- DebugPrintf("Finds the scripts and methods that call a specific kernel function.\n");
- DebugPrintf("Usage: %s <kernel function>\n", argv[0]);
- DebugPrintf("Example: %s Display\n", argv[0]);
- DebugPrintf("Special usage:\n");
- DebugPrintf("%s Dummy - find all calls to actual dummy functions "
+ debugPrintf("Finds the scripts and methods that call a specific kernel function.\n");
+ debugPrintf("Usage: %s <kernel function>\n", argv[0]);
+ debugPrintf("Example: %s Display\n", argv[0]);
+ debugPrintf("Special usage:\n");
+ debugPrintf("%s Dummy - find all calls to actual dummy functions "
"(mapped to kDummy, and dummy in the kernel table). "
"There shouldn't be calls to these (apart from a known "
"one in Shivers)\n", argv[0]);
- DebugPrintf("%s Unused - find all calls to unused functions (mapped to "
+ debugPrintf("%s Unused - find all calls to unused functions (mapped to "
"kDummy - i.e. mapped in SSCI but dummy in ScummVM, thus "
"they'll error out when called). Only debug scripts should "
"be calling these\n", argv[0]);
- DebugPrintf("%s Unmapped - find all calls to currently unmapped or "
+ debugPrintf("%s Unmapped - find all calls to currently unmapped or "
"unimplemented functions (mapped to kStub/kStubNull)\n", argv[0]);
return true;
}
@@ -3080,7 +3099,7 @@ bool Console::cmdFindKernelFunctionCall(int argc, const char **argv) {
int kernelFuncNum = kernel->findKernelFuncPos(argv[1]);
if (kernelFuncNum < 0) {
- DebugPrintf("Invalid kernel function requested\n");
+ debugPrintf("Invalid kernel function requested\n");
return true;
}
@@ -3090,7 +3109,7 @@ bool Console::cmdFindKernelFunctionCall(int argc, const char **argv) {
// in the kernel table)
for (uint i = 0; i < kernel->_kernelFuncs.size(); i++) {
if (kernel->_kernelFuncs[i].function == &kDummy && kernel->getKernelName(i) == "Dummy") {
- DebugPrintf("Searching for kernel function %d (%s)...\n", i, kernel->getKernelName(i).c_str());
+ debugPrintf("Searching for kernel function %d (%s)...\n", i, kernel->getKernelName(i).c_str());
printKernelCallsFound(i, false);
}
}
@@ -3100,7 +3119,7 @@ bool Console::cmdFindKernelFunctionCall(int argc, const char **argv) {
// called)
for (uint i = 0; i < kernel->_kernelFuncs.size(); i++) {
if (kernel->_kernelFuncs[i].function == &kDummy && kernel->getKernelName(i) != "Dummy") {
- DebugPrintf("Searching for kernel function %d (%s)...\n", i, kernel->getKernelName(i).c_str());
+ debugPrintf("Searching for kernel function %d (%s)...\n", i, kernel->getKernelName(i).c_str());
printKernelCallsFound(i, false);
}
}
@@ -3109,7 +3128,7 @@ bool Console::cmdFindKernelFunctionCall(int argc, const char **argv) {
for (uint i = 0; i < kernel->_kernelFuncs.size(); i++) {
if (kernel->_kernelFuncs[i].function == &kStub ||
kernel->_kernelFuncs[i].function == &kStubNull) {
- DebugPrintf("Searching for kernel function %d (%s)...\n", i, kernel->getKernelName(i).c_str());
+ debugPrintf("Searching for kernel function %d (%s)...\n", i, kernel->getKernelName(i).c_str());
printKernelCallsFound(i, false);
}
}
@@ -3120,17 +3139,17 @@ bool Console::cmdFindKernelFunctionCall(int argc, const char **argv) {
bool Console::cmdSend(int argc, const char **argv) {
if (argc < 3) {
- DebugPrintf("Sends a message to an object.\n");
- DebugPrintf("Usage: %s <object> <selector name> <param1> <param2> ... <paramn>\n", argv[0]);
- DebugPrintf("Example: %s ?fooScript cue\n", argv[0]);
+ debugPrintf("Sends a message to an object.\n");
+ debugPrintf("Usage: %s <object> <selector name> <param1> <param2> ... <paramn>\n", argv[0]);
+ debugPrintf("Example: %s ?fooScript cue\n", argv[0]);
return true;
}
reg_t object;
if (parse_reg_t(_engine->_gamestate, argv[1], &object, false)) {
- DebugPrintf("Invalid address \"%s\" passed.\n", argv[1]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address \"%s\" passed.\n", argv[1]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
@@ -3138,20 +3157,20 @@ bool Console::cmdSend(int argc, const char **argv) {
int selectorId = _engine->getKernel()->findSelector(selectorName);
if (selectorId < 0) {
- DebugPrintf("Unknown selector: \"%s\"\n", selectorName);
+ debugPrintf("Unknown selector: \"%s\"\n", selectorName);
return true;
}
const Object *o = _engine->_gamestate->_segMan->getObject(object);
if (o == NULL) {
- DebugPrintf("Address \"%04x:%04x\" is not an object\n", PRINT_REG(object));
+ debugPrintf("Address \"%04x:%04x\" is not an object\n", PRINT_REG(object));
return true;
}
SelectorType selector_type = lookupSelector(_engine->_gamestate->_segMan, object, selectorId, NULL, NULL);
if (selector_type == kSelectorNone) {
- DebugPrintf("Object does not support selector: \"%s\"\n", selectorName);
+ debugPrintf("Object does not support selector: \"%s\"\n", selectorName);
return true;
}
@@ -3165,8 +3184,8 @@ bool Console::cmdSend(int argc, const char **argv) {
stackframe[1] = make_reg(0, send_argc);
for (int i = 0; i < send_argc; i++) {
if (parse_reg_t(_engine->_gamestate, argv[3+i], &stackframe[2+i], false)) {
- DebugPrintf("Invalid address \"%s\" passed.\n", argv[3+i]);
- DebugPrintf("Check the \"addresses\" command on how to use addresses\n");
+ debugPrintf("Invalid address \"%s\" passed.\n", argv[3+i]);
+ debugPrintf("Check the \"addresses\" command on how to use addresses\n");
return true;
}
}
@@ -3184,7 +3203,7 @@ bool Console::cmdSend(int argc, const char **argv) {
if (old_xstack != xstack) {
_engine->_gamestate->_executionStackPosChanged = true;
- DebugPrintf("Message scheduled for execution\n");
+ debugPrintf("Message scheduled for execution\n");
// We call run_engine explictly so we can restore the value of r_acc
// after execution.
@@ -3194,7 +3213,7 @@ bool Console::cmdSend(int argc, const char **argv) {
if (restore_acc) {
// varselector read or message executed
- DebugPrintf("Message completed. Value returned: %04x:%04x\n", PRINT_REG(_engine->_gamestate->r_acc));
+ debugPrintf("Message completed. Value returned: %04x:%04x\n", PRINT_REG(_engine->_gamestate->r_acc));
_engine->_gamestate->r_acc = old_acc;
}
@@ -3205,14 +3224,14 @@ bool Console::cmdGo(int argc, const char **argv) {
// CHECKME: is this necessary?
_debugState.seeking = kDebugSeekNothing;
- return Cmd_Exit(argc, argv);
+ return cmdExit(argc, argv);
}
bool Console::cmdLogKernel(int argc, const char **argv) {
if (argc < 3) {
- DebugPrintf("Logs calls to specified kernel function.\n");
- DebugPrintf("Usage: %s <kernel function/*> <on/off>\n", argv[0]);
- DebugPrintf("Example: %s StrCpy on\n", argv[0]);
+ debugPrintf("Logs calls to specified kernel function.\n");
+ debugPrintf("Usage: %s <kernel function/*> <on/off>\n", argv[0]);
+ debugPrintf("Example: %s StrCpy on\n", argv[0]);
return true;
}
@@ -3222,14 +3241,14 @@ bool Console::cmdLogKernel(int argc, const char **argv) {
else if (strcmp(argv[2], "off") == 0)
logging = false;
else {
- DebugPrintf("2nd parameter must be either on or off\n");
+ debugPrintf("2nd parameter must be either on or off\n");
return true;
}
if (g_sci->getKernel()->debugSetFunction(argv[1], logging, -1))
- DebugPrintf("Logging %s for k%s\n", logging ? "enabled" : "disabled", argv[1]);
+ debugPrintf("Logging %s for k%s\n", logging ? "enabled" : "disabled", argv[1]);
else
- DebugPrintf("Unknown kernel function %s\n", argv[1]);
+ debugPrintf("Unknown kernel function %s\n", argv[1]);
return true;
}
@@ -3237,25 +3256,25 @@ bool Console::cmdBreakpointList(int argc, const char **argv) {
int i = 0;
int bpdata;
- DebugPrintf("Breakpoint list:\n");
+ debugPrintf("Breakpoint list:\n");
Common::List<Breakpoint>::const_iterator bp = _debugState._breakpoints.begin();
Common::List<Breakpoint>::const_iterator end = _debugState._breakpoints.end();
for (; bp != end; ++bp) {
- DebugPrintf(" #%i: ", i);
+ debugPrintf(" #%i: ", i);
switch (bp->type) {
case BREAK_SELECTOREXEC:
- DebugPrintf("Execute %s\n", bp->name.c_str());
+ debugPrintf("Execute %s\n", bp->name.c_str());
break;
case BREAK_SELECTORREAD:
- DebugPrintf("Read %s\n", bp->name.c_str());
+ debugPrintf("Read %s\n", bp->name.c_str());
break;
case BREAK_SELECTORWRITE:
- DebugPrintf("Write %s\n", bp->name.c_str());
+ debugPrintf("Write %s\n", bp->name.c_str());
break;
case BREAK_EXPORT:
bpdata = bp->address;
- DebugPrintf("Execute script %d, export %d\n", bpdata >> 16, bpdata & 0xFFFF);
+ debugPrintf("Execute script %d, export %d\n", bpdata >> 16, bpdata & 0xFFFF);
break;
}
@@ -3263,16 +3282,16 @@ bool Console::cmdBreakpointList(int argc, const char **argv) {
}
if (!i)
- DebugPrintf(" No breakpoints defined.\n");
+ debugPrintf(" No breakpoints defined.\n");
return true;
}
bool Console::cmdBreakpointDelete(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Deletes a breakpoint with the specified index.\n");
- DebugPrintf("Usage: %s <breakpoint index>\n", argv[0]);
- DebugPrintf("<index> * will remove all breakpoints\n");
+ debugPrintf("Deletes a breakpoint with the specified index.\n");
+ debugPrintf("Usage: %s <breakpoint index>\n", argv[0]);
+ debugPrintf("<index> * will remove all breakpoints\n");
return true;
}
@@ -3292,7 +3311,7 @@ bool Console::cmdBreakpointDelete(int argc, const char **argv) {
}
if (bp == end) {
- DebugPrintf("Invalid breakpoint index %i\n", idx);
+ debugPrintf("Invalid breakpoint index %i\n", idx);
return true;
}
@@ -3312,11 +3331,11 @@ bool Console::cmdBreakpointDelete(int argc, const char **argv) {
bool Console::cmdBreakpointMethod(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Sets a breakpoint on execution of a specified method/selector.\n");
- DebugPrintf("Usage: %s <name>\n", argv[0]);
- DebugPrintf("Example: %s ego::doit\n", argv[0]);
- DebugPrintf("May also be used to set a breakpoint that applies whenever an object\n");
- DebugPrintf("of a specific type is touched: %s foo::\n", argv[0]);
+ debugPrintf("Sets a breakpoint on execution of a specified method/selector.\n");
+ debugPrintf("Usage: %s <name>\n", argv[0]);
+ debugPrintf("Example: %s ego::doit\n", argv[0]);
+ debugPrintf("May also be used to set a breakpoint that applies whenever an object\n");
+ debugPrintf("of a specific type is touched: %s foo::\n", argv[0]);
return true;
}
@@ -3334,9 +3353,9 @@ bool Console::cmdBreakpointMethod(int argc, const char **argv) {
bool Console::cmdBreakpointRead(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Sets a breakpoint on reading of a specified selector.\n");
- DebugPrintf("Usage: %s <name>\n", argv[0]);
- DebugPrintf("Example: %s ego::view\n", argv[0]);
+ debugPrintf("Sets a breakpoint on reading of a specified selector.\n");
+ debugPrintf("Usage: %s <name>\n", argv[0]);
+ debugPrintf("Example: %s ego::view\n", argv[0]);
return true;
}
@@ -3351,9 +3370,9 @@ bool Console::cmdBreakpointRead(int argc, const char **argv) {
bool Console::cmdBreakpointWrite(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Sets a breakpoint on writing of a specified selector.\n");
- DebugPrintf("Usage: %s <name>\n", argv[0]);
- DebugPrintf("Example: %s ego::view\n", argv[0]);
+ debugPrintf("Sets a breakpoint on writing of a specified selector.\n");
+ debugPrintf("Usage: %s <name>\n", argv[0]);
+ debugPrintf("Example: %s ego::view\n", argv[0]);
return true;
}
@@ -3368,9 +3387,9 @@ bool Console::cmdBreakpointWrite(int argc, const char **argv) {
bool Console::cmdBreakpointKernel(int argc, const char **argv) {
if (argc < 3) {
- DebugPrintf("Sets a breakpoint on execution of a kernel function.\n");
- DebugPrintf("Usage: %s <name> <on/off>\n", argv[0]);
- DebugPrintf("Example: %s DrawPic on\n", argv[0]);
+ debugPrintf("Sets a breakpoint on execution of a kernel function.\n");
+ debugPrintf("Usage: %s <name> <on/off>\n", argv[0]);
+ debugPrintf("Example: %s DrawPic on\n", argv[0]);
return true;
}
@@ -3380,22 +3399,22 @@ bool Console::cmdBreakpointKernel(int argc, const char **argv) {
else if (strcmp(argv[2], "off") == 0)
breakpoint = false;
else {
- DebugPrintf("2nd parameter must be either on or off\n");
+ debugPrintf("2nd parameter must be either on or off\n");
return true;
}
if (g_sci->getKernel()->debugSetFunction(argv[1], -1, breakpoint))
- DebugPrintf("Breakpoint %s for k%s\n", (breakpoint ? "enabled" : "disabled"), argv[1]);
+ debugPrintf("Breakpoint %s for k%s\n", (breakpoint ? "enabled" : "disabled"), argv[1]);
else
- DebugPrintf("Unknown kernel function %s\n", argv[1]);
+ debugPrintf("Unknown kernel function %s\n", argv[1]);
return true;
}
bool Console::cmdBreakpointFunction(int argc, const char **argv) {
if (argc != 3) {
- DebugPrintf("Sets a breakpoint on the execution of the specified exported function.\n");
- DebugPrintf("Usage: %s <script number> <export number\n", argv[0]);
+ debugPrintf("Sets a breakpoint on the execution of the specified exported function.\n");
+ debugPrintf("Usage: %s <script number> <export number\n", argv[0]);
return true;
}
@@ -3415,21 +3434,21 @@ bool Console::cmdBreakpointFunction(int argc, const char **argv) {
bool Console::cmdSfx01Header(int argc, const char **argv) {
if (argc != 2) {
- DebugPrintf("Dumps the header of a SCI01 song\n");
- DebugPrintf("Usage: %s <track>\n", argv[0]);
+ debugPrintf("Dumps the header of a SCI01 song\n");
+ debugPrintf("Usage: %s <track>\n", argv[0]);
return true;
}
Resource *song = _engine->getResMan()->findResource(ResourceId(kResourceTypeSound, atoi(argv[1])), 0);
if (!song) {
- DebugPrintf("Doesn't exist\n");
+ debugPrintf("Doesn't exist\n");
return true;
}
uint32 offset = 0;
- DebugPrintf("SCI01 song track mappings:\n");
+ debugPrintf("SCI01 song track mappings:\n");
if (*song->data == 0xf0) // SCI1 priority spec
offset = 8;
@@ -3439,7 +3458,7 @@ bool Console::cmdSfx01Header(int argc, const char **argv) {
while (song->data[offset] != 0xff) {
byte device_id = song->data[offset];
- DebugPrintf("* Device %02x:\n", device_id);
+ debugPrintf("* Device %02x:\n", device_id);
offset++;
if (offset + 1 >= song->size)
@@ -3461,12 +3480,12 @@ bool Console::cmdSfx01Header(int argc, const char **argv) {
track_offset += 2;
end = READ_LE_UINT16(song->data + offset + 2);
- DebugPrintf(" - %04x -- %04x", track_offset, track_offset + end);
+ debugPrintf(" - %04x -- %04x", track_offset, track_offset + end);
if (track_offset == 0xfe)
- DebugPrintf(" (PCM data)\n");
+ debugPrintf(" (PCM data)\n");
else
- DebugPrintf(" (channel %d, special %d, %d playing notes, %d foo)\n",
+ debugPrintf(" (channel %d, special %d, %d playing notes, %d foo)\n",
header1 & 0xf, header1 >> 4, header2 & 0xf, header2 >> 4);
offset += 4;
}
@@ -3580,8 +3599,8 @@ static void midi_hexdump(byte *data, int size, int notational_offset) {
bool Console::cmdSfx01Track(int argc, const char **argv) {
if (argc != 3) {
- DebugPrintf("Dumps a track of a SCI01 song\n");
- DebugPrintf("Usage: %s <track> <offset>\n", argv[0]);
+ debugPrintf("Dumps a track of a SCI01 song\n");
+ debugPrintf("Usage: %s <track> <offset>\n", argv[0]);
return true;
}
@@ -3590,7 +3609,7 @@ bool Console::cmdSfx01Track(int argc, const char **argv) {
int offset = atoi(argv[2]);
if (!song) {
- DebugPrintf("Doesn't exist\n");
+ debugPrintf("Doesn't exist\n");
return true;
}
@@ -3614,29 +3633,29 @@ bool Console::cmdQuit(int argc, const char **argv) {
_debugState.runningStep = 0;
} else {
- DebugPrintf("%s [game] - exit gracefully\n", argv[0]);
- DebugPrintf("%s now - exit ungracefully\n", argv[0]);
+ debugPrintf("%s [game] - exit gracefully\n", argv[0]);
+ debugPrintf("%s now - exit ungracefully\n", argv[0]);
return true;
}
- return Cmd_Exit(0, 0);
+ return cmdExit(0, 0);
}
bool Console::cmdAddresses(int argc, const char **argv) {
- DebugPrintf("Address parameters may be passed in one of three forms:\n");
- DebugPrintf(" - ssss:oooo -- where 'ssss' denotes a segment and 'oooo' an offset.\n");
- DebugPrintf(" Example: \"a:c5\" would address something in segment 0xa at offset 0xc5.\n");
- DebugPrintf(" - &scr:oooo -- where 'scr' is a script number and oooo an offset within that script; will\n");
- DebugPrintf(" fail if the script is not currently loaded\n");
- DebugPrintf(" - $REG -- where 'REG' is one of 'PC', 'ACC', 'PREV' or 'OBJ': References the address\n");
- DebugPrintf(" indicated by the register of this name.\n");
- DebugPrintf(" - $REG+n (or -n) -- Like $REG, but modifies the offset part by a specific amount (which\n");
- DebugPrintf(" is specified in hexadecimal).\n");
- DebugPrintf(" - ?obj -- Looks up an object with the specified name, uses its address. This will abort if\n");
- DebugPrintf(" the object name is ambiguous; in that case, a list of addresses and indices is provided.\n");
- DebugPrintf(" ?obj.idx may be used to disambiguate 'obj' by the index 'idx'.\n");
- DebugPrintf(" Underscores are used as substitute characters for spaces in object names.\n");
- DebugPrintf(" For example, an object named \"Glass Jar\" can be accessed as \"Glass_Jar\".\n");
+ debugPrintf("Address parameters may be passed in one of three forms:\n");
+ debugPrintf(" - ssss:oooo -- where 'ssss' denotes a segment and 'oooo' an offset.\n");
+ debugPrintf(" Example: \"a:c5\" would address something in segment 0xa at offset 0xc5.\n");
+ debugPrintf(" - &scr:oooo -- where 'scr' is a script number and oooo an offset within that script; will\n");
+ debugPrintf(" fail if the script is not currently loaded\n");
+ debugPrintf(" - $REG -- where 'REG' is one of 'PC', 'ACC', 'PREV' or 'OBJ': References the address\n");
+ debugPrintf(" indicated by the register of this name.\n");
+ debugPrintf(" - $REG+n (or -n) -- Like $REG, but modifies the offset part by a specific amount (which\n");
+ debugPrintf(" is specified in hexadecimal).\n");
+ debugPrintf(" - ?obj -- Looks up an object with the specified name, uses its address. This will abort if\n");
+ debugPrintf(" the object name is ambiguous; in that case, a list of addresses and indices is provided.\n");
+ debugPrintf(" ?obj.idx may be used to disambiguate 'obj' by the index 'idx'.\n");
+ debugPrintf(" Underscores are used as substitute characters for spaces in object names.\n");
+ debugPrintf(" For example, an object named \"Glass Jar\" can be accessed as \"Glass_Jar\".\n");
return true;
}
@@ -3840,10 +3859,15 @@ static int parse_reg_t(EngineState *s, const char *str, reg_t *dest, bool mayBeV
const char *tmp = Common::find(str_objname.begin(), str_objname.end(), '.');
if (tmp != str_objname.end()) {
index = strtol(tmp + 1, &endptr, 16);
- if (*endptr)
- return -1;
- // Chop off the index
- str_objname = Common::String(str_objname.c_str(), tmp);
+ if (*endptr) {
+ // The characters after the dot do not represent an index.
+ // This can happen if an object contains a dot in its name,
+ // like 'dominoes.opt' in Hoyle 3.
+ index = -1;
+ } else {
+ // Valid index found, chop it off
+ str_objname = Common::String(str_objname.c_str(), tmp);
+ }
}
// Replace all underscores in the name with spaces
@@ -3882,14 +3906,14 @@ bool Console::parseInteger(const char *argument, int &result) {
// hexadecimal number
result = strtol(argument, &endPtr, 16);
if ((*endPtr != 0) && (*endPtr != 'h')) {
- DebugPrintf("Invalid hexadecimal number '%s'\n", argument);
+ debugPrintf("Invalid hexadecimal number '%s'\n", argument);
return false;
}
} else {
// decimal number
result = strtol(argument, &endPtr, 10);
if (*endPtr != 0) {
- DebugPrintf("Invalid decimal number '%s'\n", argument);
+ debugPrintf("Invalid decimal number '%s'\n", argument);
return false;
}
}
@@ -3907,57 +3931,57 @@ void Console::printBasicVarInfo(reg_t variable) {
case SIG_TYPE_INTEGER: {
uint16 content = variable.toUint16();
if (content >= 10)
- DebugPrintf(" (%dd)", content);
+ debugPrintf(" (%dd)", content);
break;
}
case SIG_TYPE_OBJECT:
- DebugPrintf(" (object '%s')", segMan->getObjectName(variable));
+ debugPrintf(" (object '%s')", segMan->getObjectName(variable));
break;
case SIG_TYPE_REFERENCE:
- DebugPrintf(" (reference)");
+ debugPrintf(" (reference)");
break;
case SIG_TYPE_NODE:
- DebugPrintf(" (node)");
+ debugPrintf(" (node)");
break;
case SIG_TYPE_LIST:
- DebugPrintf(" (list)");
+ debugPrintf(" (list)");
break;
case SIG_TYPE_UNINITIALIZED:
- DebugPrintf(" (uninitialized)");
+ debugPrintf(" (uninitialized)");
break;
case SIG_TYPE_ERROR:
- DebugPrintf(" (error)");
+ debugPrintf(" (error)");
break;
default:
- DebugPrintf(" (??\?)");
+ debugPrintf(" (??\?)");
}
if (regType & SIG_IS_INVALID)
- DebugPrintf(" IS INVALID!");
+ debugPrintf(" IS INVALID!");
}
void Console::printList(List *list) {
reg_t pos = list->first;
reg_t my_prev = NULL_REG;
- DebugPrintf("\t<\n");
+ debugPrintf("\t<\n");
while (!pos.isNull()) {
Node *node;
NodeTable *nt = (NodeTable *)_engine->_gamestate->_segMan->getSegment(pos.getSegment(), SEG_TYPE_NODES);
if (!nt || !nt->isValidEntry(pos.getOffset())) {
- DebugPrintf(" WARNING: %04x:%04x: Doesn't contain list node!\n",
+ debugPrintf(" WARNING: %04x:%04x: Doesn't contain list node!\n",
PRINT_REG(pos));
return;
}
node = &(nt->_table[pos.getOffset()]);
- DebugPrintf("\t%04x:%04x : %04x:%04x -> %04x:%04x\n", PRINT_REG(pos), PRINT_REG(node->key), PRINT_REG(node->value));
+ debugPrintf("\t%04x:%04x : %04x:%04x -> %04x:%04x\n", PRINT_REG(pos), PRINT_REG(node->key), PRINT_REG(node->value));
if (my_prev != node->pred)
- DebugPrintf(" WARNING: current node gives %04x:%04x as predecessor!\n",
+ debugPrintf(" WARNING: current node gives %04x:%04x as predecessor!\n",
PRINT_REG(node->pred));
my_prev = pos;
@@ -3965,9 +3989,9 @@ void Console::printList(List *list) {
}
if (my_prev != list->last)
- DebugPrintf(" WARNING: Last node was expected to be %04x:%04x, was %04x:%04x!\n",
+ debugPrintf(" WARNING: Last node was expected to be %04x:%04x, was %04x:%04x!\n",
PRINT_REG(list->last), PRINT_REG(my_prev));
- DebugPrintf("\t>\n");
+ debugPrintf("\t>\n");
}
int Console::printNode(reg_t addr) {
@@ -3978,32 +4002,32 @@ int Console::printNode(reg_t addr) {
List *list;
if (!lt->isValidEntry(addr.getOffset())) {
- DebugPrintf("Address does not contain a list\n");
+ debugPrintf("Address does not contain a list\n");
return 1;
}
list = &(lt->_table[addr.getOffset()]);
- DebugPrintf("%04x:%04x : first x last = (%04x:%04x, %04x:%04x)\n", PRINT_REG(addr), PRINT_REG(list->first), PRINT_REG(list->last));
+ debugPrintf("%04x:%04x : first x last = (%04x:%04x, %04x:%04x)\n", PRINT_REG(addr), PRINT_REG(list->first), PRINT_REG(list->last));
} else {
NodeTable *nt;
Node *node;
mobj = _engine->_gamestate->_segMan->getSegment(addr.getSegment(), SEG_TYPE_NODES);
if (!mobj) {
- DebugPrintf("Segment #%04x is not a list or node segment\n", addr.getSegment());
+ debugPrintf("Segment #%04x is not a list or node segment\n", addr.getSegment());
return 1;
}
nt = (NodeTable *)mobj;
if (!nt->isValidEntry(addr.getOffset())) {
- DebugPrintf("Address does not contain a node\n");
+ debugPrintf("Address does not contain a node\n");
return 1;
}
node = &(nt->_table[addr.getOffset()]);
- DebugPrintf("%04x:%04x : prev x next = (%04x:%04x, %04x:%04x); maps %04x:%04x -> %04x:%04x\n",
+ debugPrintf("%04x:%04x : prev x next = (%04x:%04x, %04x:%04x); maps %04x:%04x -> %04x:%04x\n",
PRINT_REG(addr), PRINT_REG(node->pred), PRINT_REG(node->succ), PRINT_REG(node->key), PRINT_REG(node->value));
}
@@ -4017,44 +4041,44 @@ int Console::printObject(reg_t pos) {
uint i;
if (!obj) {
- DebugPrintf("[%04x:%04x]: Not an object.", PRINT_REG(pos));
+ debugPrintf("[%04x:%04x]: Not an object.", PRINT_REG(pos));
return 1;
}
// Object header
- DebugPrintf("[%04x:%04x] %s : %3d vars, %3d methods\n", PRINT_REG(pos), s->_segMan->getObjectName(pos),
+ debugPrintf("[%04x:%04x] %s : %3d vars, %3d methods\n", PRINT_REG(pos), s->_segMan->getObjectName(pos),
obj->getVarCount(), obj->getMethodCount());
if (!obj->isClass() && getSciVersion() != SCI_VERSION_3)
var_container = s->_segMan->getObject(obj->getSuperClassSelector());
- DebugPrintf(" -- member variables:\n");
+ debugPrintf(" -- member variables:\n");
for (i = 0; (uint)i < obj->getVarCount(); i++) {
- DebugPrintf(" ");
+ debugPrintf(" ");
if (var_container && i < var_container->getVarCount()) {
uint16 varSelector = var_container->getVarSelector(i);
- DebugPrintf("[%03x] %s = ", varSelector, _engine->getKernel()->getSelectorName(varSelector).c_str());
+ debugPrintf("[%03x] %s = ", varSelector, _engine->getKernel()->getSelectorName(varSelector).c_str());
} else
- DebugPrintf("p#%x = ", i);
+ debugPrintf("p#%x = ", i);
reg_t val = obj->getVariable(i);
- DebugPrintf("%04x:%04x", PRINT_REG(val));
+ debugPrintf("%04x:%04x", PRINT_REG(val));
if (!val.getSegment())
- DebugPrintf(" (%d)", val.getOffset());
+ debugPrintf(" (%d)", val.getOffset());
const Object *ref = s->_segMan->getObject(val);
if (ref)
- DebugPrintf(" (%s)", s->_segMan->getObjectName(val));
+ debugPrintf(" (%s)", s->_segMan->getObjectName(val));
- DebugPrintf("\n");
+ debugPrintf("\n");
}
- DebugPrintf(" -- methods:\n");
+ debugPrintf(" -- methods:\n");
for (i = 0; i < obj->getMethodCount(); i++) {
reg_t fptr = obj->getFunction(i);
- DebugPrintf(" [%03x] %s = %04x:%04x\n", obj->getFuncSelector(i), _engine->getKernel()->getSelectorName(obj->getFuncSelector(i)).c_str(), PRINT_REG(fptr));
+ debugPrintf(" [%03x] %s = %04x:%04x\n", obj->getFuncSelector(i), _engine->getKernel()->getSelectorName(obj->getFuncSelector(i)).c_str(), PRINT_REG(fptr));
}
if (s->_segMan->_heap[pos.getSegment()]->getType() == SEG_TYPE_SCRIPT)
- DebugPrintf("\nOwner script: %d\n", s->_segMan->getScript(pos.getSegment())->getScriptNumber());
+ debugPrintf("\nOwner script: %d\n", s->_segMan->getScript(pos.getSegment())->getScriptNumber());
return 0;
}
diff --git a/engines/sci/console.h b/engines/sci/console.h
index 37cf35a471..c8e99f78f7 100644
--- a/engines/sci/console.h
+++ b/engines/sci/console.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/debug.h b/engines/sci/debug.h
index 765ceca07d..4fcb757c10 100644
--- a/engines/sci/debug.h
+++ b/engines/sci/debug.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/decompressor.cpp b/engines/sci/decompressor.cpp
index 306825008d..e65ff148de 100644
--- a/engines/sci/decompressor.cpp
+++ b/engines/sci/decompressor.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/decompressor.h b/engines/sci/decompressor.h
index 5753026709..dab35fa41c 100644
--- a/engines/sci/decompressor.h
+++ b/engines/sci/decompressor.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/detection.cpp b/engines/sci/detection.cpp
index 883a4d965b..4f28738508 100644
--- a/engines/sci/detection.cpp
+++ b/engines/sci/detection.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/detection_tables.h b/engines/sci/detection_tables.h
index 5ad49acf5c..344298ce9a 100644
--- a/engines/sci/detection_tables.h
+++ b/engines/sci/detection_tables.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -50,7 +50,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "f3d1be7752d30ba60614533d531e2e98", 474},
{"resource.001", 0, "6fd05926c2199af0af6f72f90d0d7260", 126895},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.005.000"
@@ -62,7 +62,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "d226d7d3b4f77c4a566913fc310487fc", 792380},
{"resource.003", 0, "d226d7d3b4f77c4a566913fc310487fc", 464348},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - German Amiga (from www.back2roots.org, also includes English language)
// Executable scanning reports "1.005.001"
@@ -74,7 +74,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "85e51acb5f9c539d66e3c8fe40e17da5", 826309},
{"resource.003", 0, "85e51acb5f9c539d66e3c8fe40e17da5", 493638},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain Macintosh (from omer_mor, bug report #3328251)
{"castlebrain", "", {
@@ -84,7 +84,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "e1a6b6f1060f60be9dcb6d28ad7a2a20", 1168310},
{"resource.003", 0, "6c3d1bb26ad532c94046bc9ac49b5ff4", 891295},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS Non-Interactive Demo
// SCI interpreter version 1.000.005
@@ -93,7 +93,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "9780f040d58182994e22d2e34fab85b0", 67367},
{"resource.001", 0, "2af49dbd8f2e1db4ab09f9310dc91259", 570553},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS 5.25" Floppy EGA (from omer_mor, bug report #3035349)
{"castlebrain", "EGA", {
@@ -106,7 +106,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "8a5ed3ba96e2eaf18e36fedfaab89419", 297838},
{"resource.006", 0, "dceed92e709cad1bd9582809a235b0a0", 266682},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS 3.5" Floppy EGA (from nozomi77, bug report #3405307)
{"castlebrain", "EGA", {
@@ -116,7 +116,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "de2f182529efaad2c4b510b452ab77ac", 633662},
{"resource.003", 0, "38b4b37febc6b4f5061c461a283df148", 430388},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS Floppy (from jvprat)
// Executable scanning reports "1.000.044", Floppy label reports "1.0, 10.30.91", VERSION file reports "1.000"
@@ -127,7 +127,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "d2f5a1be74ed963fa849a76892be5290", 794832},
{"resource.002", 0, "c0c29c51af66d65cb53f49e785a2d978", 1280907},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS 5.25" Floppy VGA 1.1 (from rnjacobs, bug report #3578286)
{"castlebrain", "", {
@@ -137,7 +137,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "583d348c908f89f94f8551d7fe0a2eca", 991752},
{"resource.003", 0, "6c3d1bb26ad532c94046bc9ac49b5ff4", 728315},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS Floppy 1.1
{"castlebrain", "", {
@@ -146,7 +146,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "13e81e1839cd7b216d2bb5615c1ca160", 796776},
{"resource.002", 0, "930e416bec196b9703a331d81b3d66f2", 1283812},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - English DOS Floppy 1.000
// Reported by graxer in bug report #3037942
@@ -161,7 +161,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "1d778a0c65cac9ddbab65495e50a94ee", 335281},
{"resource.007", 0, "063bb8ce4157c778cf30d1c912c006f1", 335631},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Castle of Dr. Brain - Spanish DOS (also includes english language)
// SCI interpreter version 1.000.510
@@ -170,7 +170,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "27ec5fa09cd12a7fd16e86d96a2ed245", 1197694},
{"resource.001", 0, "735be4e58957180cfc807d5e18fdffcd", 1433302},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Inside the Chest / Behind the Developer's Shield
@@ -179,7 +179,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "9dd015e79cac4f91e7de805448f39775", 1912},
{"resource.000", 0, "e4efcd042f86679dd4e1834bb3a38edb", 3770943},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO3(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO3(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI) },
#endif
// Christmas Card 1988 - English DOS
@@ -188,7 +188,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "39485580d34a72997f3d5b3aba4d24f1", 426},
{"resource.001", 0, "11391434f41c834090d7a1e9488ce936", 129739},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Christmas Card 1990: The Seasoned Professional - English DOS (16 Colors)
// SCI interpreter version 1.000.172
@@ -196,7 +196,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8f656714a05b94423ac6eb10ee8797d0", 600},
{"resource.001", 0, "acde93e58fca4f7a2a5a220558a94aa8", 272629},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Christmas Card 1990: The Seasoned Professional - English DOS (256 Colors)
// SCI interpreter version 1.000.174
@@ -204,7 +204,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "44b8f45b841b9b5e17e939a35e443988", 600},
{"resource.001", 0, "acde93e58fca4f7a2a5a220558a94aa8", 335362},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Christmas Card 1992 - English DOS
// SCI interpreter version 1.001.055
@@ -212,7 +212,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "f1f8c8a8443f523422af70b4ec85b71c", 318},
{"resource.000", 0, "62fb9256f8e7e6e65a6875efdb7939ac", 203396},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Codename: Iceman - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.002.031"
@@ -226,7 +226,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "8613c45fc771d658e5a505b9a4a54f31", 713382},
{"resource.005", 0, "605b67a9ef199a9bb015745e7c004cf4", 478384},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Codename: Iceman - English DOS Non-Interactive Demo
// Executable scanning reports "0.000.685"
@@ -234,7 +234,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "782974f29d8a824782d2d4aea39964e3", 1056},
{"resource.001", 0, "d4b75e280d1c3a97cfef1b0bebff387c", 573647},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Codename: Iceman - English DOS (from jvprat)
// Executable scanning reports "0.000.685", Floppy label reports "1.033, 6.8.90", VERSION file reports "1.033"
@@ -247,7 +247,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "d97a96f1ab91b41cf46a02cc89b0a04e", 624303},
{"resource.004", 0, "8613c45fc771d658e5a505b9a4a54f31", 670883},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Codename: Iceman - English DOS (from FRG)
// SCI interpreter version 0.000.668
@@ -259,7 +259,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "dc7c5280e7acfaffe6ef2a6c963c5f94", 622118},
{"resource.004", 0, "64f342463f6f35ba71b3509ef696ae3f", 669188},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Codename: Iceman - English DOS (supplied by ssburnout in bug report #3049193)
// 1.022 9x5.25" (label: Int#0.000.668)
@@ -274,7 +274,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "08050329aa113a9f14ed99cbfe3536ec", 232942},
{"resource.007", 0, "64f342463f6f35ba71b3509ef696ae3f", 267811},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Codename: Iceman - English DOS 1.023 (from abevi, bug report #2612718)
{"iceman", "", {
@@ -288,7 +288,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "08050329aa113a9f14ed99cbfe3536ec", 232942},
{"resource.007", 0, "64f342463f6f35ba71b3509ef696ae3f", 267702},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of Camelot - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.002.030"
@@ -303,7 +303,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "c6e551bdc24f0acc193159038d4ca767", 605882},
{"resource.006", 0, "8f880a536908ab496bbc552f7f5c3738", 585255},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of Camelot - English DOS Non-Interactive Demo
// SCI interpreter version 0.000.668
@@ -311,7 +311,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "f4cd75c15be75e04cdca3acda2c0b0ea", 468},
{"resource.001", 0, "4930708722f34bfbaa4945fb08f55f61", 232523},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of Camelot - English DOS (from jvprat)
// Executable scanning reports "0.000.685", Floppy label reports "1.001, 0.000.685", VERSION file reports "1.001.000"
@@ -323,7 +323,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "8e1a3a8c588007404b532b8dfacc1460", 723712},
{"resource.004", 0, "8e1a3a8c588007404b532b8dfacc1460", 729143},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of Camelot - English DOS
// SCI interpreter version 0.000.685
@@ -337,7 +337,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "8e1a3a8c588007404b532b8dfacc1460", 332446},
{"resource.007", 0, "8e1a3a8c588007404b532b8dfacc1460", 358182},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.005.001"
@@ -352,7 +352,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "1c3804e56b114028c5873a35c2f06d13", 653002},
{"resource.006", 0, "f9487732289a4f4966b4e34eea413325", 842817},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow - English DOS
// SCI interpreter version 1.000.510
@@ -366,7 +366,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "d036df0872f2db19bca34601276be2d7", 1154950},
{"resource.006", 0, "b367a6a59f29ee30dde1d88a5a41152d", 1042966},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow - English DOS Floppy (from jvprat)
// Executable scanning reports "1.000.168", Floppy label reports "1.1, 1.13.92", VERSION file reports "1.1"
@@ -380,7 +380,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "9cfce07e204a329e94fda8b5657621da", 1261462},
{"resource.005", 0, "21ebe6b39b57a73fc449f67f013765aa", 1284720},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow - English DOS
// SCI interpreter version 1.000.510
@@ -393,30 +393,32 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "9cfce07e204a329e94fda8b5657621da", 1260237},
{"resource.005", 0, "21ebe6b39b57a73fc449f67f013765aa", 1284609},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow EGA - English DOS
// SCI interpreter version 1.000.510
{"longbow", "EGA", {
- {"resource.map", 0, "7676ec9f08967d7a9a7724f5170456e0", 6261},
- {"resource.000", 0, "36e8fda5d0b8c49e587c8a9617959f72", 718161},
- {"resource.001", 0, "3c3735caa34fa3f261a9552831bb43ed", 705680},
- {"resource.002", 0, "7025b87e735b1df3f0e9488a621f4333", 700633},
- {"resource.003", 0, "eaca7933e8e56bea22b42f7fd5d7a8a7", 686510},
- {"resource.004", 0, "b7bb35c027bb424ecefcd122768e5e60", 705631},
- {"resource.005", 0, "58942b1aa6d6ffeb66e9f8897fd4435f", 469243},
- {"resource.006", 0, "8c767b3939add63d11274065e46aad04", 713158},
- AD_LISTEND}, Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ {"resource.map", 0, "7676ec9f08967d7a9a7724f5170456e0", 6261},
+ {"resource.000", 0, "36e8fda5d0b8c49e587c8a9617959f72", 718161},
+ {"resource.001", 0, "3c3735caa34fa3f261a9552831bb43ed", 705680},
+ {"resource.002", 0, "7025b87e735b1df3f0e9488a621f4333", 700633},
+ {"resource.003", 0, "eaca7933e8e56bea22b42f7fd5d7a8a7", 686510},
+ {"resource.004", 0, "b7bb35c027bb424ecefcd122768e5e60", 705631},
+ {"resource.005", 0, "58942b1aa6d6ffeb66e9f8897fd4435f", 469243},
+ {"resource.006", 0, "8c767b3939add63d11274065e46aad04", 713158},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow DOS 1.0 EGA (4 x 5.25" disks)
// Provided by ssburnout in bug report #3046802
{"longbow", "EGA", {
- {"resource.map", 0, "0517ca368ec844df0cb21a05020fae01", 6021},
- {"resource.000", 0, "36e8fda5d0b8c49e587c8a9617959f72", 934643},
- {"resource.001", 0, "76c729e563809170e6cc8b2f3f6cf0a4", 1196133},
- {"resource.002", 0, "8c767b3939add63d11274065e46aad04", 1152478},
- {"resource.003", 0, "7025b87e735b1df3f0e9488a621f4333", 1171439},
- AD_LISTEND}, Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ {"resource.map", 0, "0517ca368ec844df0cb21a05020fae01", 6021},
+ {"resource.000", 0, "36e8fda5d0b8c49e587c8a9617959f72", 934643},
+ {"resource.001", 0, "76c729e563809170e6cc8b2f3f6cf0a4", 1196133},
+ {"resource.002", 0, "8c767b3939add63d11274065e46aad04", 1152478},
+ {"resource.003", 0, "7025b87e735b1df3f0e9488a621f4333", 1171439},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow - English DOS Non-Interactive Demo
// SCI interpreter version 1.000.510
@@ -424,7 +426,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "cbc5cb73341de1bff1b1e20a640af220", 588},
{"resource.001", 0, "f05a20cc07eee85da8e999d0ac0f596b", 869916},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Conquests of the Longbow - German DOS (suplied by markcoolio in bug report #2727681, also includes english language)
// SCI interpreter version 1.000.510
@@ -438,7 +440,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "d036df0872f2db19bca34601276be2d7", 1176914},
{"resource.006", 0, "b367a6a59f29ee30dde1d88a5a41152d", 1123585},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - English DOS Non-Interactive Demo (from FRG)
// Executable scanning reports "x.yyy.zzz"
@@ -447,7 +449,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "c819e171359b7c95f4c13b846d5c034e", 873},
{"resource.001", 0, "baf9393a9bfa73098adb501e5bc5487b", 657518},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - English DOS CD 1.1
// SCI interpreter version 1.001.064
@@ -455,7 +457,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a4b73d5d2b55bdb6e44345e99c8fbdd0", 4804},
{"resource.000", 0, "d908dbef56816ac6c60dd145fdeafb2b", 3536046},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - English DOS CD 1.1
// SCI interpreter version 1.001.064
@@ -465,7 +467,15 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a4b73d5d2b55bdb6e44345e99c8fbdd0", 4804},
{"resource.000", 0, "d908dbef56816ac6c60dd145fdeafb2b", 3536046},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Eco Quest - English DOS Floppy (reported by misterhands in bug #6599)
+ // Game v1.10, interpreter 2.000.286, INT #6.12.92
+ {"ecoquest", "Floppy", {
+ {"resource.map", 0, "acb10c12bf15ffa7d0fac36124b20c8e", 4890},
+ {"resource.000", 0, "89cf7c8eed99afd0a9f4188170b81ebe", 3428654},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - English DOS Floppy
// SCI interpreter version 1.000.510
@@ -476,7 +486,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "28fe9b4f0567e71feb198bc9f3a2c605", 1241816},
{"resource.003", 0, "f3146df0ad4297f5ce35aa8c4753bf6c", 586832},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - English DOS Floppy
// SCI interpreter version 1.000.510
@@ -487,7 +497,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "323b3b12f43d53f27d259beb225f0aa7", 1129316},
{"resource.003", 0, "83ac03e4bddb2c1ac2d36d2a587d0536", 1145616},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - German DOS Floppy (supplied by markcoolio in bug report #2723744, also includes english language)
// SCI interpreter version 1.000.510
@@ -498,7 +508,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "02d7d0411f7903aacb3bc8b0f8ca8a9a", 1202581},
{"resource.003", 0, "84dd11b6825255671c703aee5ceff620", 1175835},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - Spanish DOS Floppy (from jvprat, also includes english language)
// Executable scanning reports "1.ECO.013", VERSION file reports "1.000, 11.12.92"
@@ -510,7 +520,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "2d21a1d2dcbffa551552e3e0725d2284", 1186033},
{"resource.003", 0, "84dd11b6825255671c703aee5ceff620", 1174993},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest - French DOS Floppy (from Strangerke, also includes english language)
// SCI interpreter version 1.ECO.013
@@ -521,7 +531,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "b836c6ee9de67d814ac5d1b05f5b9858", 1173872},
{"resource.003", 0, "f8f767f9d6351432621c6e54c1b2ba8c", 1141520},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest 2 - English DOS Non-Interactive Demo
// SCI interpreter version 1.001.055
@@ -529,7 +539,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "607cfa0d8a03b7d348c06ee727e3d939", 1321},
{"resource.000", 0, "dd6f614c43c029f063e93cd243af90a4", 525992},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest 2 - English DOS Floppy (supplied by markcoolio in bug report #2723761)
// SCI interpreter version 1.001.065
@@ -537,7 +547,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "28fb7b6abb9fc1cb8882d7c2e701b63f", 5658},
{"resource.000", 0, "cc1d17e5637528dbe4a812699e1cbfc6", 4208192},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest 2 - French DOS Floppy (from Strangerke)
// SCI interpreter version 1.001.081
@@ -545,7 +555,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "c22ab8b33c339c138b6b1697b77b9e79", 5588},
{"resource.000", 0, "1c4093f7248240329121fdf8c0d59152", 4231946},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest 2 - Spanish DOS Floppy (supplied by umbrio in bug report #3313962)
{"ecoquest2", "Floppy", {
@@ -553,7 +563,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "1c4093f7248240329121fdf8c0d59152", 4209150},
{"resource.msg", 0, "eff8be1925d42288de55e405983e9314", 117810},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Eco Quest 2 - German DOS Floppy (supplied by frankenbuam in bug report #3615072)
{"ecoquest2", "Floppy", {
@@ -569,7 +579,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "97aa9fcfe84c9993a64debd28c32393a", 1909},
{"resource.000", 0, "5ea8e7a3ea10cce6efd5c106dc62fd8c", 867724},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - English CD DOS (from FRG)
// SCI interpreter version 1.001.132
@@ -577,7 +587,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "d46b282f228a67ba13bd4b4009e95f8f", 6058},
{"resource.000", 0, "ee3c64ffff0ba9fb08bea2624631c598", 5490246},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - English DOS Floppy (updated information from markcoolio in bug reports #2723773 and #2724720)
// Executable scanning reports "1.cfs.081"
@@ -587,7 +597,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "96b07e9b914dba1c8dc6c78a176326df", 5233230},
{"resource.msg", 0, "554f65315d851184f6e38211489fdd8f", -1},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - French DOS Floppy (supplied by misterhands in bug report #3589449)
// Executable scanning reports "1.cfs.081"
@@ -596,7 +606,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "fed4808fdb72486908ac7ad0044b14d8", 5233230},
{"resource.msg", 0, "4dc478f5c73b57e5d690bdfffdcf1c44", 816518},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - Windows (supplied by abevi in bug report #2612718)
// Executable scanning reports "1.cfs.081"
@@ -605,7 +615,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a32674e7fbf7b213b4a066c8037f16b6", 5816},
{"resource.000", 0, "fed4808fdb72486908ac7ad0044b14d8", 5233230},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - German DOS Floppy (from Tobis87, updated information from markcoolio in bug reports #2723772 and #2724720)
// Executable scanning reports "1.cfs.081"
@@ -615,7 +625,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "96b07e9b914dba1c8dc6c78a176326df", 5233230},
{"resource.msg", 0, "304b5a5781800affd2235152a5794fa8", -1},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - Spanish DOS (from jvprat)
// Executable scanning reports "1.cfs.081", VERSION file reports "1.000, March 30, 1995"
@@ -628,7 +638,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "05acdc256c742e79c50b9fe7ec2cc898", 863310},
{"resource.msg", 0, "45b5bf74933ac3727e4cc844446dc052", 796156},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - Spanish DOS (from jvprat)
// Executable scanning reports "1.cfs.081", VERSION file reports "1.000, March 30, 1995"
@@ -638,7 +648,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "96b07e9b914dba1c8dc6c78a176326df", 5233230},
{"resource.msg", 0, "45b5bf74933ac3727e4cc844446dc052", 796156},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - English DOS CD Demo
// SCI interpreter version 1.001.095
@@ -646,14 +656,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a62a7eae85dd1e6b07f39662b278437e", 1918},
{"resource.000", 0, "4962a3c4dd44e36e78ea4a7a374c2220", 957382},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Freddy Pharkas - English Macintosh
{"freddypharkas", "", {
{"Data1", 0, "ef7cbd62727989818f1cfae69c9fd61d", 3038492},
{"Data2", 0, "2424b418f7d52c385cea4701f529c69a", 4721732},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Fun Seeker's Guide - English DOS
// SCI interpreter version 0.000.506
@@ -661,7 +671,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "7ee6859ef74314f6d91938c3595348a9", 282},
{"resource.001", 0, "f1e680095424e31f7fae1255d36bacba", 40692},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English DOS CD Demo
// SCI interpreter version 1.001.092
@@ -669,7 +679,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "39645952ae0ed8072c7e838f31b75464", 2490},
{"resource.000", 0, "eb3ed7477ca4110813fe1fcf35928561", 1718450},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English DOS CD Demo (from DrMcCoy)
// SCI interpreter version 1.001.092
@@ -677,7 +687,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8cad2a256f41463030cbb7ea1bfb2857", 2490},
{"resource.000", 0, "eb3ed7477ca4110813fe1fcf35928561", 1718450},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Gabriel Knight - English DOS Floppy
@@ -686,7 +696,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "372d059f75856afa6d73dd84cbb8913d", 10783},
{"resource.000", 0, "69b7516962510f780d38519cc15fcc7c", 13022630},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English DOS Floppy (supplied my markcoolio in bug report #2723777)
// SCI interpreter version 2.000.000
@@ -694,7 +704,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "65e8c14092e4c9b3b3538b7602c8c5ec", 10783},
{"resource.000", 0, "69b7516962510f780d38519cc15fcc7c", 13022630},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English DOS Floppy
// SCI interpreter version 2.000.000, VERSION file reports "1.0\nGabriel Knight\n11/22/10:33 pm\n\x1A"
@@ -702,7 +712,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "ef41df08cf2c1f680216cdbeed0f8311", 10783},
{"resource.000", 0, "69b7516962510f780d38519cc15fcc7c", 13022630},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - German DOS Floppy (supplied my markcoolio in bug report #2723775)
// SCI interpreter version 2.000.000
@@ -710,7 +720,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "ad6508b0296b25c07b1f58828dc33696", 10789},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13077029},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - French DOS Floppy (supplied my kervala in bug report #3611487)
// SCI interpreter version 2.000.000
@@ -718,7 +728,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "236e36cc847cdeafdd5e5fa8cba916ed", 10801},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13033072},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English DOS CD (from jvprat)
// Executable scanning reports "2.000.000", VERSION file reports "01.100.000"
@@ -726,7 +736,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "372d059f75856afa6d73dd84cbb8913d", 10996},
{"resource.000", 0, "69b7516962510f780d38519cc15fcc7c", 12581736},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English Windows CD (from jvprat)
// Executable scanning reports "2.000.000", VERSION file reports "01.100.000"
@@ -734,7 +744,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "372d059f75856afa6d73dd84cbb8913d", 10996},
{"resource.000", 0, "69b7516962510f780d38519cc15fcc7c", 12581736},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - German DOS CD (from Tobis87)
// SCI interpreter version 2.000.000
@@ -742,7 +752,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a7d3e55114c65647310373cb390815ba", 11392},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13400497},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - Spanish DOS CD (from jvprat)
// Executable scanning reports "2.000.000", VERSION file reports "1.000.000, April 13, 1995"
@@ -750,7 +760,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "7cb6e9bba15b544ec7a635c45bde9953", 11404},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13381599},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - French DOS CD (from Hkz)
// VERSION file reports "1.000.000, May 3, 1994"
@@ -758,7 +768,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "55f909ba93a2515042a08d8a2da8414e", 11392},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13325145},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - German Windows CD (from Tobis87)
// SCI interpreter version 2.000.000
@@ -766,7 +776,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a7d3e55114c65647310373cb390815ba", 11392},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13400497},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformWindows, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformWindows, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - Spanish Windows CD (from jvprat)
// Executable scanning reports "2.000.000", VERSION file reports "1.000.000, April 13, 1995"
@@ -774,7 +784,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "7cb6e9bba15b544ec7a635c45bde9953", 11404},
{"resource.000", 0, "091cf08910780feabc56f8551b09cb36", 13381599},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformWindows, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformWindows, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight - English Macintosh
{"gk1", "", {
@@ -783,7 +793,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"Data3", 0, "f25068b408b09275d8b698866462f578", 3677599},
{"Data4", 0, "1cceebbe411b26c860a74f91c337fdf3", 3230086},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight 2 - English Windows Non-Interactive Demo
// Executable scanning reports "2.100.002"
@@ -791,7 +801,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "e0effce11c4908f4b91838741716c83d", 1351},
{"resource.000", 0, "d04cfc7f04b6f74d13025378be49ec2b", 4640330},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight 2 - English DOS (GOG version) - ressci.* merged in ressci.000
// using Enrico Rolfi's HD/DVD installer: http://gkpatches.vogons.zetafleet.com/
@@ -799,7 +809,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "b996fa1e57389a1e179a00a0049de1f4", 8110},
{"ressci.000", 0, "a19fc3604c6e5407abcf03d59ee87217", 168522221},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight 2 - English DOS (from jvprat)
// Executable scanning reports "2.100.002", VERSION file reports "1.1"
@@ -817,7 +827,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.006", 0, "ce9359037277b7d7976da185c2fa0aad", 2977},
{"ressci.006", 0, "8e44e03890205a7be12f45aaba9644b4", 60659424},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight 2 - French DOS (6-CDs Sierra Originals reedition)
// Executable scanning reports "2.100.002", VERSION file reports "1.0"
@@ -835,7 +845,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.006", 0, "11b2e722170b8c93fdaa5428e2c7676f", 3001},
{"ressci.006", 0, "4037d941aec39d2e654e20960429aefc", 60568486},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Gabriel Knight 2 - English Macintosh
// NOTE: This only contains disc 1 files (as well as the persistent file:
@@ -847,7 +857,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"Data4", 0, "8b843c62eb53136a855d6e0087e3cb0d", 5889553},
{"Data5", 0, "f9fcf9ab2eb13b2125c33a1cda03a093", 14349984},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI32
@@ -859,7 +869,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "e0dd44069a62a463fd124974b915f10d", 342149},
{"resource.003", 0, "e0dd44069a62a463fd124974b915f10d", 328925},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 1 - English DOS (supplied by wibble92 in bug report #2644547)
// SCI interpreter version 0.000.530
@@ -869,7 +879,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "e0dd44069a62a463fd124974b915f10d", 342309},
{"resource.003", 0, "e0dd44069a62a463fd124974b915f10d", 328912},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 1 - English DOS (supplied by merkur in bug report #2719227)
// SCI interpreter version 0.000.530
@@ -877,14 +887,22 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "1034a218943d12f1f36e753fa10c95b8", 4386},
{"resource.001", 0, "e0dd44069a62a463fd124974b915f10d", 518308},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 1 3.5' - English DOS (supplied by eddydrama in bug report #3052366 and dinnerx in bug report #3090841)
{"hoyle1", "", {
{"resource.map", 0, "0af9a3dcd72a091960de070432e1f524", 4386},
{"resource.001", 0, "e0dd44069a62a463fd124974b915f10d", 518127},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Hoyle 1 - English DOS v1.000.115 (supplied by misterhands in bug report #6597)
+ // Executable scanning reports "0.000.668"
+ {"hoyle1", "", {
+ {"resource.map", 0, "3ddf55fdbe14eb0e89a27a2cfc1338bd", 4386},
+ {"resource.001", 0, "e0dd44069a62a463fd124974b915f10d", 519525},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#if 0 // TODO: unknown if these files are corrupt
// Hoyle 1 - English Amiga (from www.back2roots.org)
@@ -894,7 +912,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "e0dd44069a62a463fd124974b915f10d", 218755},
{"resource.002", 0, "e0dd44069a62a463fd124974b915f10d", 439502},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif
// Hoyle 2 - English DOS
@@ -904,7 +922,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "8f2dd70abe01112eca464cda818b5eb6", 98138},
{"resource.002", 0, "8f2dd70abe01112eca464cda818b5eb6", 196631},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 2 - English DOS (supplied by ssburnout in bug report #3049193)
// 1.000.011 1x3.5" (label:Int#6.21.90)
@@ -912,7 +930,15 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "db0ba08b953e9904a4960ad99cd29c20", 1356},
{"resource.001", 0, "8f2dd70abe01112eca464cda818b5eb6", 216315},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Hoyle 2 - English DOS (supplied by misterhands in bug report #6598)
+ // Game v1.000.016, interpreter 0.000.668, INT #12.5.90
+ {"hoyle2", "", {
+ {"resource.map", 0, "d8758a4eb6f34f6b3130bf25a496d123", 1356},
+ {"resource.001", 0, "8f2dd70abe01112eca464cda818b5eb6", 217880},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 2 - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.002.032"
@@ -921,15 +947,15 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "62ed48d20c580e5a98f102f7cd93706a", 1356},
{"resource.001", 0, "8f2dd70abe01112eca464cda818b5eb6", 222704},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 2 - English Macintosh
// Executable scanning reports "x.yyy.zzz"
{"hoyle2", "", {
{"resource.map", 0, "1af1d3aa3cf564f93477c9f87e53f495", 1728},
{"resource.001", 0, "b73b8131669d69d41a326415e4519138", 482882},
- {NULL, 0, NULL, 0}},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#if 0 // TODO: unknown if these files are corrupt
// Hoyle 3 - English Amiga (from www.back2roots.org)
@@ -940,7 +966,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "595b6039ea1356e7f96a52c58eedcf22", 355791},
{"resource.001", 0, "143df8aef214a2db34c2d48190742012", 632273},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif
// Hoyle 3 - English DOS Non-Interactive Demo
@@ -950,7 +976,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "0d06cacc87dc21a08cd017e73036f905", 735},
{"resource.001", 0, "24db2bccda0a3c43ac4a7b5edb116c7e", 797678},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 3 - English DOS Floppy (from jvprat)
// Executable scanning reports "x.yyy.zzz", Floppy label reports "1.0, 11.2.91", VERSION file reports "1.000"
@@ -960,7 +986,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "6ef28cac094dcd97fdb461662ead6f92", 541845},
{"resource.001", 0, "0a98a268ee99b92c233a0d7187c1f0fa", 845795},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 3 - English DOS Floppy (supplied by eddydrama in bug report #3038837)
{"hoyle3", "", {
@@ -971,7 +997,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "97cfd72633f8f9b2a0b1d4116cf3ee81", 346116},
{"resource.004", 0, "2884fb91b225fabd9ca87ea231293b48", 351218},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 3 EGA - English DOS Floppy 1.0 (supplied by abevi in bug report #2612718)
{"hoyle3", "EGA", {
@@ -979,14 +1005,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "6ef28cac094dcd97fdb461662ead6f92", 319905},
{"resource.001", 0, "0a98a268ee99b92c233a0d7187c1f0fa", 526438},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 4 (Hoyle Classic Card Games) - English DOS Demo
{"hoyle4", "Demo", {
{"resource.map", 0, "60f764020a6b788bbbe415dbc2ccb9f3", 931},
{"resource.000", 0, "5fe3670e3ddcd4f85c10013b5453141a", 615522},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 4 (Hoyle Classic Card Games) - English DOS Demo
// SCI interpreter version 1.001.200 (just a guess)
@@ -995,7 +1021,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "662087cb383e52e3cc4ae7ecb10e20aa", 938},
{"resource.000", 0, "24c10844792c54d476d272213cbac300", 675252},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 4 (Hoyle Classic Card Games) - English DOS/Win
// Supplied by abevi in bug report #3039291
@@ -1003,7 +1029,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "2b577c975cc8d8d43f61b6a756129fe3", 4352},
{"resource.000", 0, "43e2c15ce436aab611a462ad0603e12d", 2000132},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Hoyle 4 (Hoyle Classic Card Games) - English Macintosh Floppy
// VERSION file reports "2.0"
@@ -1011,7 +1037,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"Data1", 0, "99575fae4579540a314bbedd72d51e8c", 7682887},
{"Data2", 0, "7d4bf5bdf3c02edbf35cb8471c84ec13", 1539134},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Jones in the Fast Lane EGA - English DOS
// SCI interpreter version 1.000.172 (not 100% sure FIXME)
@@ -1020,14 +1046,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "bac3ec6cb3e3920984ab0f32becf5163", 202105},
{"resource.002", 0, "b86daa3ba2784d1502da881eedb80d9b", 341771},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Jones in the Fast Lane EGA - English DOS (supplied by EddyDrama in bug report #3038761)
{"jones", "EGA", {
{"resource.map", 0, "8e92cf319180cc8b5b87b2ce93a4fe22", 1602},
{"resource.001", 0, "bac3ec6cb3e3920984ab0f32becf5163", 511528},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Jones in the Fast Lane VGA - English DOS
// SCI interpreter version 1.000.172
@@ -1036,7 +1062,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "bac3ec6cb3e3920984ab0f32becf5163", 313476},
{"resource.002", 0, "b86daa3ba2784d1502da881eedb80d9b", 719747},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Jones in the Fast Lane VGA - English DOS (supplied by omer_mor in bug report #3037054)
// VERSION file reports "1.000.060"
@@ -1044,14 +1070,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "db175ab494ab0666f19ab8f2597a8e49", 1602},
{"resource.001", 0, "bac3ec6cb3e3920984ab0f32becf5163", 994487},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Jones in the Fast Lane - English DOS CD
{"jones", "CD", {
{"resource.map", 0, "459f5b04467bc2107aec02f5c4b71b37", 4878},
{"resource.001", 0, "3876da2ce16fb7dea2f5d943d946fa84", 1652150},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO1(GAMEOPTION_JONES_CDAUDIO) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO1(GAMEOPTION_JONES_CDAUDIO) },
// Jones in the Fast Lane - English DOS CD
// Same entry as the DOS version above. This one is used for the alternate
@@ -1060,7 +1086,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "459f5b04467bc2107aec02f5c4b71b37", 4878},
{"resource.001", 0, "3876da2ce16fb7dea2f5d943d946fa84", 1652150},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI, GAMEOPTION_JONES_CDAUDIO) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI, GAMEOPTION_JONES_CDAUDIO) },
// Jones in the Fast Lane - English DOS US CD (alternate version)
// Supplied by collector9 in bug #3614668
@@ -1068,7 +1094,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "4344ff3f796707843b992adec2c87663", 4878},
{"resource.001", 0, "3876da2ce16fb7dea2f5d943d946fa84", 1652062},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO1(GAMEOPTION_JONES_CDAUDIO) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO1(GAMEOPTION_JONES_CDAUDIO) },
// Jones in the Fast Lane - English DOS US CD (alternate version)
// Same entry as the DOS version above. This one is used for the alternate
@@ -1077,7 +1103,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "4344ff3f796707843b992adec2c87663", 4878},
{"resource.001", 0, "3876da2ce16fb7dea2f5d943d946fa84", 1652062},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI, GAMEOPTION_JONES_CDAUDIO) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI, GAMEOPTION_JONES_CDAUDIO) },
// King's Quest 1 SCI Remake - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.003.007"
@@ -1089,7 +1115,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "9ae2a13708d691cd42f9129173c4b39d", 763224},
{"resource.004", 0, "9ae2a13708d691cd42f9129173c4b39d", 820443},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 1 SCI Remake - English DOS Non-Interactive Demo
// Executable scanning reports "S.old.010"
@@ -1097,7 +1123,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "59b13619078bd47011421468959ee5d4", 954},
{"resource.001", 0, "4cfb9040db152868f7cb6a1e8151c910", 296555},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 1 SCI Remake - English DOS (from the King's Quest Collection)
// Executable scanning reports "S.old.010", VERSION file reports "1.000.051"
@@ -1108,7 +1134,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "fed9e0072ffd511d248674e60dee2099", 714062},
{"resource.003", 0, "fed9e0072ffd511d248674e60dee2099", 717478},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 1 SCI Remake - English DOS (supplied by ssburnout in bug report #3049193)
// 1.000.051 9x5.25" (label: INT#9.19.90)
@@ -1122,7 +1148,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "fed9e0072ffd511d248674e60dee2099", 351062},
{"resource.007", 0, "fed9e0072ffd511d248674e60dee2099", 330472},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.002.032"
@@ -1135,7 +1161,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "fd16c9c223f7dc5b65f06447615224ff", 683016},
{"resource.004", 0, "3fac034c7d130e055d05bc43a1f8d5f8", 549993},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English DOS Non-Interactive Demo
// Executable scanning reports "0.000.494"
@@ -1143,7 +1169,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "992ac7cc31d3717fe53818a9bb6d1dae", 594},
{"resource.001", 0, "143e1c14f15ad0fbfc714f648a65f661", 205330},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English DOS (original boxed release, 3 1/2" disks)
// SCI interpreter version 0.000.247
@@ -1154,7 +1180,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "851a62d00972dc4002f472cc0d84e71d", 683145},
{"resource.004", 0, "851a62d00972dc4002f472cc0d84e71d", 649441},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English DOS (from the King's Quest Collection)
// Executable scanning reports "0.000.502"
@@ -1166,7 +1192,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "77615c595388acf3d1df8e107bfb6b52", 707591},
{"resource.004", 0, "77615c595388acf3d1df8e107bfb6b52", 479562},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English DOS (supplied by ssburnout in bug report #3049193)
// 1.006.003 8x5.25" (label: Int.#0.000.502)
@@ -1180,7 +1206,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "6db7de6f93c6ea62dca78abee677f8c0", 324789},
{"resource.007", 0, "6db7de6f93c6ea62dca78abee677f8c0", 334441},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English DOS
// SCI interpreter version 0.000.274
@@ -1194,7 +1220,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "851a62d00972dc4002f472cc0d84e71d", 333777},
{"resource.007", 0, "851a62d00972dc4002f472cc0d84e71d", 341038},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English DOS
// SCI interpreter version 0.000.253
@@ -1208,7 +1234,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "0c8566848a76eea19a6d6220914030a7", 337288},
{"resource.007", 0, "0c8566848a76eea19a6d6220914030a7", 343882},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 4 - English Atari ST (double-sided diskettes)
// Game version 1.003.006 (January 12, 1989)
@@ -1221,7 +1247,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "a3cdb4848fb859fdd302976fff56490f", 705074},
{"resource.004", 0, "a3cdb4848fb859fdd302976fff56490f", 478366},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAtariST, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAtariST, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.004.018"
@@ -1237,7 +1263,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "26c0c25399b6715fec03fc3e12544fe3", 823048},
{"resource.007", 0, "b914b5901e786327213e779725d30dd1", 778772},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - German Amiga (also includes english language)
// Executable scanning reports "1.004.024"
@@ -1253,7 +1279,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "56546b20db11a4836f900efa6d3a3e74", 672099},
{"resource.007", 0, "56546b20db11a4836f900efa6d3a3e74", 794194},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - Italian Amiga (also includes english language)
// Executable scanning reports "1.004.024"
@@ -1269,7 +1295,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "11cb750f5f816445ad0f4b9f50a4f59a", 672527},
{"resource.007", 0, "11cb750f5f816445ad0f4b9f50a4f59a", 794259},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English DOS CD (from the King's Quest Collection)
// Executable scanning reports "x.yyy.zzz", VERSION file reports "1.000.052"
@@ -1279,7 +1305,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "449471bfd77be52f18a3773c7f7d843d", 571368},
{"resource.001", 0, "b45a581ff8751e052c7e364f58d3617f", 16800210},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English DOS CD (from the King's Quest Collection)
// Executable scanning reports "x.yyy.zzz", VERSION file reports "1.000.052"
@@ -1291,7 +1317,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "449471bfd77be52f18a3773c7f7d843d", 571368},
{"resource.001", 0, "b45a581ff8751e052c7e364f58d3617f", 16800210},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO4(GUIO_MIDIGM, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English DOS Floppy
// SCI interpreter version 1.000.060
@@ -1306,7 +1332,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "672ede1136e9e401658538e51bd5dc22", 1172619},
{"resource.007", 0, "2f48faf27666b58c276dda20f91f4a93", 1240456},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English DOS Floppy
// VERSION file reports "0.000.051"
@@ -1324,7 +1350,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "da82e4beb744731d0a151f1d4922fafa", 1170456},
{"resource.007", 0, "431def14ca29cdb5e6a5e84d3f38f679", 1240176},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English DOS Floppy (supplied by omer_mor in bug report #3036996)
// VERSION file reports "0.000.051"
@@ -1339,7 +1365,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "06cb3f689836086ebe08b1efc0126592", 921113},
{"resource.007", 0, "252249753c6e850eacceb8af634986d3", 1133608},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 EGA (supplied by markcoolio in bug report #2829470)
// SCI interpreter version 1.000.060
@@ -1355,7 +1381,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "698c698570cde9015e4d51eb8d2e9db1", 666527},
{"resource.007", 0, "703d8df30e89541af337d7706540d5c4", 541743},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 EGA 1.2M disk version (from LordHoto)
// VERSION file reports "0.000.055"
@@ -1367,7 +1393,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "53206afb4fd73871a484e83acab80f31", 7608},
{"resource.004", 0, "83568edf7fde18b3eed988bc5d22ceb1", 1188053},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 EGA (supplied by omer_mor in bug report #3035421)
// VERSION file reports "0.000.062"
@@ -1382,7 +1408,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "698c698570cde9015e4d51eb8d2e9db1", 666541},
{"resource.007", 0, "703d8df30e89541af337d7706540d5c4", 541762},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest V DOS 0.000.062 EGA (5 x 5.25" disks)
// Supplied by ssburnout in bug report #3046780
@@ -1394,7 +1420,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "3cca5b2dae8afe94532edfdc98d7edbe", 1092325},
{"resource.004", 0, "8e5c1bc4d738cf7316ff506f59d265e2", 1187803},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 DOS Spanish Floppy 0.000.062 VGA (5 x 3.5" disks)
// Supplied by dianiu in bug report #3555646
@@ -1409,7 +1435,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "65b520e60c4217e6a6572d9edf77193b", 1141985},
{"resource.007", 0, "f42b0100f0a1c30806814f8648b6bc28", 1145583},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - German DOS Floppy (supplied by markcoolio in bug report #2727101, also includes english language)
// SCI interpreter version 1.000.060
@@ -1424,7 +1450,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "d1a75fdc01840664d00366cff6919366", 1208972},
{"resource.007", 0, "c07494f0cce7c05210893938786a955b", 1337361},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - French DOS Floppy (from the King's Quest Collector's Edition 1994, also includes english language)
// Supplied by aroenai in bug report #2812611
@@ -1440,7 +1466,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "f7dc85307632ef657ceb1651204f6f51", 1210081},
{"resource.007", 0, "7db4d0a1d8d547c0019cb7d2a6acbdd4", 1338473},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - Italian DOS Floppy (from glorifindel, includes english language)
// SCI interpreter version 1.000.060
@@ -1455,7 +1481,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "8eeabd92af71e766e323db2100879102", 1209325},
{"resource.007", 0, "dc10c107e0923b902326a040b9c166b9", 1337859},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - Polish DOS Floppy (supplied by jacek909 in bug report #2725722)
// SCI interpreter version 1.000.060
@@ -1473,7 +1499,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.007", 0, "431def14ca29cdb5e6a5e84d3f38f679", 1240176},
{"text.000", 0, "601aa35a3ddeb558e1280e0963e955a2", 1517},
AD_LISTEND},
- Common::PL_POL, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::PL_POL, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - English Macintosh
// VERSION file reports "1.000.055"
@@ -1488,7 +1514,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "3d22904a374c192f51e5665b74364133", 1264079},
{"resource.007", 0, "ffe17e23d5833a79f3695addfc149a56", 1361965},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 5 - FM-Towns (supplied by abevi in bug report #3038720)
{"kq5", "", {
@@ -1496,7 +1522,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "71afd220d46bde1109c58e6acc0f3a01", 469094},
{"resource.001", 0, "72a569f46f1abf2d9d2b1526ad3799c3", 12808839},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformFMTowns, 0, GUIO2(GUIO_NOASPECT, GUIO_MIDITOWNS) },
+ Common::EN_ANY, Common::kPlatformFMTowns, 0, GUIO2(GUIO_NOASPECT, GUIO_MIDITOWNS) },
{"kq5", "", {
{"resource.map", 0, "20c7cd248ff1a349ed354568eebd972b", 12733},
{"resource.000", 0, "71afd220d46bde1109c58e6acc0f3a01", 469094},
@@ -1514,7 +1540,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "e114ce8f884601c43308fb5cbbea4874", 1174129},
{"resource.005", 0, "349ad9438172265d00680075c5a988d0", 1019669},
AD_LISTEND},
- Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - English DOS Non-Interactive Demo
// Executable scanning reports "1.001.055", VERSION file reports "1.000.000"
@@ -1524,7 +1550,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "535b1b920441ec73f42eaa4ccfd47b89", 264116},
{"resource.msg", 0, "54d1fdc936f98c81f9e4c19e04fb1510", 8260},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - English DOS Floppy
// SCI interpreter version 1.001.054
@@ -1533,7 +1559,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "f2b7f753992c56a0c7a08d6a5077c895", 7863324},
{"resource.msg", 0, "3cf5de44de36191f109d425b8450efc8", 258590},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - French DOS Floppy (supplied by misterhands in bug #3503425)
// SCI interpreter version ???
@@ -1542,7 +1568,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "f2b7f753992c56a0c7a08d6a5077c895", 7863324},
{"resource.msg", 0, "adc2aa8adbdcc97507d44a6f492fbd77", 265194},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - German DOS Floppy (supplied by markcoolio in bug report #2727156)
// SCI interpreter version 1.001.054
@@ -1551,7 +1577,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "f2b7f753992c56a0c7a08d6a5077c895", 7863324},
{"resource.msg", 0, "756297b2155db9e43f621c6f6fb763c3", 282822},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - Spanish DOS Floppy (from jvprat)
// Executable scanning reports "1.cfs.158", VERSION file reports "1.000.000, July 5, 1994"
@@ -1561,7 +1587,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "4da3ad5868a775549a7cc4f72770a58e", 8537260},
{"resource.msg", 0, "41eed2d3893e1ca6c3695deba4e9d2e8", 267102},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - Italian DOS Floppy (supplied by guybrush79 in bug report #3606719)
{"kq6", "", {
@@ -1569,7 +1595,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "d3358ba7306378aed83d02b5c3f11311", 8531908},
{"resource.msg", 0, "b7e8220be596fd6a9287eae5a8fd354a", 279886},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - English DOS CD (from the King's Quest Collection)
// Executable scanning reports "1.cfs.158", VERSION file reports "1.034 9/11/94 - KQ6 version 1.000.00G"
@@ -1578,7 +1604,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "7a550ebfeae2575ca00d47703a6a774c", 9215},
{"resource.000", 0, "233394a5f33b475ae5975e7e9a420865", 8376352},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - English Windows CD (from the King's Quest Collection)
// Executable scanning reports "1.cfs.158", VERSION file reports "1.034 9/11/94 - KQ6 version 1.000.00G"
@@ -1587,7 +1613,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "7a550ebfeae2575ca00d47703a6a774c", 9215},
{"resource.000", 0, "233394a5f33b475ae5975e7e9a420865", 8376352},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO5(GUIO_NOASPECT, GAMEOPTION_KQ6_WINDOWS_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO5(GUIO_NOASPECT, GAMEOPTION_KQ6_WINDOWS_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 6 - English Macintosh Floppy
// VERSION file reports "1.0"
@@ -1595,7 +1621,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"Data1", 0, "a183fc0c22fcbd9be4c8800d974b5599", 3892124},
{"Data2", 0, "b3722460dfd3097a1fbaf99a21ad8ea5", 15031272},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
@@ -1606,7 +1632,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "4948e4e1506f1e1c4e1d47abfa06b7f8", 204385195},
{"resource.map", 0, "40ccafb2195301504eba2e4f4f2c7f3d", 18925},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - English Windows (from the King's Quest Collection)
// Executable scanning reports "2.100.002", VERSION file reports "1.4"
@@ -1614,7 +1640,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "2be9ab94429c721af8e05c507e048a15", 18697},
{"resource.000", 0, "eb63ea3a2c2469dc2d777d351c626404", 203882535},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - English DOS (from FRG)
// SCI interpreter version 2.100.002, VERSION file reports "2.00b"
@@ -1622,7 +1648,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8676b0fbbd7362989a029fe72fea14c6", 18709},
{"resource.000", 0, "51c1ead1163e19a2de8f121c39df7a76", 200764100},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - English Windows (from FRG)
// SCI interpreter version 2.100.002, VERSION file reports "2.00b"
@@ -1630,7 +1656,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8676b0fbbd7362989a029fe72fea14c6", 18709},
{"resource.000", 0, "51c1ead1163e19a2de8f121c39df7a76", 200764100},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - German Windows (supplied by markcoolio in bug report #2727402)
// SCI interpreter version 2.100.002
@@ -1638,7 +1664,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "838b9ff132bd6962026fee832e8a7ddb", 18697},
{"resource.000", 0, "eb63ea3a2c2469dc2d777d351c626404", 206626576},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - Spanish DOS (from jvprat)
// Executable scanning reports "2.100.002", VERSION file reports "2.00"
@@ -1646,7 +1672,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "0b62693cbe87e3aaca3e8655a437f27f", 18709},
{"resource.000", 0, "51c1ead1163e19a2de8f121c39df7a76", 200764100},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - English DOS Non-Interactive Demo
// SCI interpreter version 2.100.002
@@ -1654,7 +1680,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "b44f774108d63faa1d021101221c5a54", 1690},
{"resource.000", 0, "d9659d2cf0c269c6a9dc776707f5bea0", 2433827},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Quest 7 - English Windows Demo (from DrMcCoy)
// SCI interpreter version 2.100.002
@@ -1662,7 +1688,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "38e627a37a975aea40cc72b0518b0709", 18412},
{"resource.000", 0, "bad61d50aaa64298fa57a7c6ccd3bccf", 84020382},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// King's Questions mini-game from the King's Quest Collection
// SCI interpreter version 2.000.000
@@ -1670,7 +1696,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "9b1cddecd4f0720d83661ba7aed28891", 162697},
{"resource.map", 0, "93a2251fa64e729d7a7d2fe56b217c8e", 502},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO3(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO3(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI32
@@ -1686,7 +1712,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "aa553977f7e5804081de293800d3bcce", 695067},
{"resource.005", 0, "bfd870d51dc97729f0914095f58e6957", 676881},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow - English Atari ST (from jvprat)
// Executable scanning reports "1.002.030", Floppy label reports "1.000.062, 9.23.90"
@@ -1698,7 +1724,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "e45c888d9c7c04aec0a20e9f820b79ff", 667365},
{"resource.004", 0, "e45c888d9c7c04aec0a20e9f820b79ff", 683737},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAtariST, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAtariST, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow - English DOS Non-Interactive Demo
// Executable scanning reports "x.yyy.zzz"
@@ -1706,7 +1732,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "e625726268ff4e123ada11f31f0249f3", 768},
{"resource.001", 0, "0c8912290af0890f8d95faeb4ddb2d68", 333031},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow - English DOS 3.5" Floppy (from "The Roberta Williams Anthology"/1996)
// SCI interpreter version 0.000.631
@@ -1717,7 +1743,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "e45c888d9c7c04aec0a20e9f820b79ff", 667468},
{"resource.004", 0, "e45c888d9c7c04aec0a20e9f820b79ff", 683807},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow - English DOS (from FRG)
// SCI interpreter version 0.000.631
@@ -1731,7 +1757,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "e45c888d9c7c04aec0a20e9f820b79ff", 328390},
{"resource.007", 0, "e45c888d9c7c04aec0a20e9f820b79ff", 317687},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow 2 - English DOS Non-Interactive Demo (from FRG)
// Executable scanning reports "x.yyy.zzz"
@@ -1740,16 +1766,25 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "24dffc5db1d88c7999f13e8767ed7346", 855},
{"resource.000", 0, "2b2b1b4f7584f9b38fd13f6ab95634d1", 781912},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
- // Laura Bow 2 - English DOS Floppy
+ // Laura Bow 2 - English DOS Floppy v1.0
// Executable scanning reports "2.000.274"
// SCI interpreter version 1.001.069 (just a guess)
{"laurabow2", "", {
{"resource.map", 0, "610bfd9a852004222f0faaf5fc9e630a", 6489},
{"resource.000", 0, "57084910bc923bff5d6d9bc1b56e9604", 5035964},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Laura Bow 2 v1.1 - English DOS Floppy (supplied by misterhands in bug report #6543)
+ // Executable scanning reports "2.000.274"
+ {"laurabow2", "", {
+ {"resource.map", 0, "3b6dfbcda210bbc3f23fd1927113bf98", 6483},
+ {"resource.000", 0, "57084910bc923bff5d6d9bc1b56e9604", 5028766},
+ {"resource.msg", 0, "d1755fc4f41b5210febc9410503c6a29", 278354},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow 2 - English DOS CD (from "The Roberta Williams Antology"/1996)
// Executable scanning reports "1.001.072", VERSION file reports "1.1" (from jvprat)
@@ -1758,7 +1793,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a70945e61ba7ac7bfea6b7bd72c6aec5", 7274},
{"resource.000", 0, "82578b8d5a7e09c4c58891ca49fae35b", 5598672},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow 2 v1.1 - French DOS Floppy (from Hkz)
{"laurabow2", "", {
@@ -1766,7 +1801,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "57084910bc923bff5d6d9bc1b56e9604", 5028766},
{"resource.msg", 0, "0fceedfbdd85a4bc7851fdd9dd2d2f19", 278253},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow 2 v1.1 - German DOS Floppy (from Tobis87, updated info from markcoolio in bug report #2723787, updated info from #2797962))
// Executable scanning reports "2.000.274"
@@ -1775,7 +1810,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "57084910bc923bff5d6d9bc1b56e9604", 5028766},
{"resource.msg", 0, "795c928cd00dfec9fbc62ebcd12e1f65", 303185},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Laura Bow 2 - Spanish DOS CD (from jvprat)
// Executable scanning reports "2.000.274", VERSION file reports "1.000.000, May 10, 1994"
@@ -1784,7 +1819,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "57084910bc923bff5d6d9bc1b56e9604", 5028766},
{"resource.msg", 0, "71f1f0cd9f082da2e750c793a8ed9d84", 286141},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 EGA Remake - English DOS (from spookypeanut)
// SCI interpreter version 0.000.510 (or 0.000.577?)
@@ -1795,7 +1830,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "24c958bc922b07f91e25e8c93aa01fcf", 491230},
{"resource.003", 0, "685cd6c1e05a695ab1e0db826337ee2a", 553279},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#if 0
// The resource.002 file, contained in disk 3, is broken in this version
@@ -1813,7 +1848,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "5790ac0505f7ca98d4567132b875eb1e", 681041},
{"resource.003", 0, "4a34c3367c2fe7eb380d741374da1989", 572251},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif
// Larry 1 VGA Remake - English DOS (from spookypeanut)
@@ -1824,7 +1859,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "ec20246209d7b19f38989261e5c8f5b8", 1111226},
{"resource.002", 0, "85d6935ef77e6b0e16bc307640a0d913", 1088312},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 VGA Remake - English DOS (from FRG)
// SCI interpreter version 1.000.510
@@ -1834,7 +1869,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "d34cadb11e1aefbb497cf91bc1d3baa7", 1114688},
{"resource.002", 0, "85b030bb66d5342b0a068f1208c431a8", 1078443},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 VGA Remake - English Macintosh (from omer_mor, bug report #3328262)
{"lsl1sci", "SCI", {
@@ -1843,7 +1878,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "aa6f153f70f1e32d1bde465fff08eecf", 1137418},
{"resource.002", 0, "b22c616aa789ebef990290c7ffd86548", 1097477},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 VGA Remake - English DOS Non-Interactive Demo
// SCI interpreter version 1.000.084
@@ -1851,7 +1886,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "434e1f6c39d71647b34f0ee57b2bbd68", 444},
{"resource.001", 0, "0c0768215c562d9dace4a5ca53696cf3", 359913},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 VGA Remake - Spanish DOS (from the Leisure Suit Larry Collection, also includes english language)
// Executable scanning reports "1.SQ4.057", VERSION file reports "1.000"
@@ -1864,7 +1899,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "3fe2a3aec0ed53c7d6db1845a67e3aa2", 1095908},
{"resource.003", 0, "ac175df0ea9a2cba57f0248651856d27", 376556},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 VGA Remake - Russian DOS (also includes english language?!)
// Executable scanning reports "1.000.510", VERSION file reports "2.0"
@@ -1875,7 +1910,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "bc8ca10c807515d959cbd91f9ba47735", 1123759},
{"resource.002", 0, "b7409ab32bc3bee2d6cce887cd33f2b6", 1092160},
AD_LISTEND},
- Common::RU_RUS, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::RU_RUS, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 1 VGA Remake - Polish DOS (from Polish Leisure Suit Larry Collection, official release)
// SCI interpreter version 1.000.577, VERSION file reports "2.1" (this release does NOT include english text)
@@ -1883,7 +1918,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "58330a85767e42a2487129913283ab5b", 3228},
{"resource.000", 0, "b6097ff35cdc8469f02150fe2f824198", 4781210},
AD_LISTEND},
- Common::PL_POL, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::PL_POL, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 2 - English Amiga (from www.back2roots.org)
// Executable scanning reports "x.yyy.zzz"
@@ -1895,7 +1930,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "a0d4a625311d307257da7fc43d00459d", 570356},
{"resource.004", 0, "a0d4a625311d307257da7fc43d00459d", 717844},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 2 - English DOS Non-Interactive Demo
// Executable scanning reports "x.yyy.zzz"
@@ -1904,7 +1939,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "03dba704bb77da55a91ad27b5a3cac09", 528},
{"resource.001", 0, "9f5520f0297206928df0b0b36493cd33", 127532},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 2 - English DOS
// SCI interpreter version 0.000.409
@@ -1917,7 +1952,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "4a24443a25e2b1492462a52809605dc2", 277732},
{"resource.006", 0, "4a24443a25e2b1492462a52809605dc2", 345683},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 2 - English DOS
// SCI interpreter version 0.000.343
@@ -1932,7 +1967,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
//{"resource.006", 0, "96033f57accfca903750413fd09193c8", 345818},
{"resource.006", 0, "96033f57accfca903750413fd09193c8", -1}, // 345818 or 208739
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 2 - English DOS (supplied by ssburnout in bug report #3049193)
// 1.000.011 3x3.5" (label: Int. #0.000.343)
@@ -1942,7 +1977,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "96033f57accfca903750413fd09193c8", 407014},
{"resource.003", 0, "96033f57accfca903750413fd09193c8", 592834},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 2 - English DOS (supplied by ssburnout in bug report #3049193)
// 1.002.000 3x3.5" (label: INT#0.000.409)
@@ -1952,7 +1987,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "4a24443a25e2b1492462a52809605dc2", 406935},
{"resource.003", 0, "4a24443a25e2b1492462a52809605dc2", 592533},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.002.032"
@@ -1966,7 +2001,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "f408e59cbee1457f042e5773b8c53951", 651634},
{"resource.005", 0, "433911eb764089d493aed1f958a5615a", 524259},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - English DOS (supplied by ssburnout in bug report #3049193)
// 1.021 8x5.25" (label: Int#5.15.90)
@@ -1980,7 +2015,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "f18441027154292836b973c655fa3175", 282649},
{"resource.007", 0, "f18441027154292836b973c655fa3175", 257178},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - English DOS
// SCI interpreter version 0.000.572
@@ -1994,7 +2029,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "f18441027154292836b973c655fa3175", 282465},
{"resource.007", 0, "f18441027154292836b973c655fa3175", 257174},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - English DOS
// SCI interpreter version 0.000.572
@@ -2005,7 +2040,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "f18441027154292836b973c655fa3175", 506807},
{"resource.004", 0, "f18441027154292836b973c655fa3175", 513651},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - English DOS (supplied by kervala in bug report #3611488)
{"lsl3", "", {
@@ -2015,7 +2050,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "f18441027154292836b973c655fa3175", 506817},
{"resource.004", 0, "f18441027154292836b973c655fa3175", 513337},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - English DOS Non-Interactive Demo
// SCI interpreter version 0.000.530
@@ -2024,7 +2059,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "f773d79b93dfd4052ec8c1cc64c1e6ab", 76525},
{"resource.002", 0, "f773d79b93dfd4052ec8c1cc64c1e6ab", 268299},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - German DOS (from Tobis87, updated info from markcoolio in bug report #2723832, also includes english language)
// Executable scanning reports "S.old.123"
@@ -2036,7 +2071,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "3827a9b17b926e12dcc336860f50612a", 587036},
{"resource.004", 0, "3827a9b17b926e12dcc336860f50612a", 691932},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 - French DOS (provided by richiefs in bug report #2670691, also includes english language)
// Executable scanning reports "S.old.123"
@@ -2048,7 +2083,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "65f1bdaa20f6d0470e9d969f22473873", 586921},
{"resource.004", 0, "65f1bdaa20f6d0470e9d969f22473873", 690826},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 3 1.050 Fr/En (9 x 5.25" disks)
// Provided by ssburnout in bug report #3046779
@@ -2062,7 +2097,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "65f1bdaa20f6d0470e9d969f22473873", 325292},
{"resource.007", 0, "65f1bdaa20f6d0470e9d969f22473873", 308982},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - English Amiga
// Executable scanning reports "1.004.023"
@@ -2077,7 +2112,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "f8b2d1137bb767e5d232056b99dd69eb", 623621},
{"resource.006", 0, "bafc64e3144f115dc58c6aee02de98fb", 715598},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - German Amiga (also includes english language)
// Executable scanning reports "1.004.024"
@@ -2093,7 +2128,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "bafc64e3144f115dc58c6aee02de98fb", 754966},
{"resource.007", 0, "59eba83ad465b08d763b44f86afa86f6", 683135},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - English DOS Non-Interactive Demo (from FRG)
// SCI interpreter version 1.000.181
@@ -2101,7 +2136,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "efe8d3f45ce4f6bd9a6643e0ac8d2a97", 504},
{"resource.001", 0, "8bd8d9c0b5f455ee1269d63ce86c50dd", 531380},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - English DOS (from spookypeanut)
// SCI interpreter version 1.000.510
@@ -2116,7 +2151,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1024810},
{"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 1030656},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - English Macintosh (from omer_mor, bug report #3328257)
{"lsl5", "", {
@@ -2130,7 +2165,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1110043},
{"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 989801},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - German DOS (from Tobis87)
// SCI interpreter version T.A00.196
@@ -2145,7 +2180,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1021774},
{"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 993408},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - French DOS (provided by richiefs in bug report #2670691)
// Executable scanning reports "1.lsl5.019"
@@ -2161,7 +2196,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 946540},
{"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 958842},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - Spanish DOS (from the Leisure Suit Larry Collection)
// Executable scanning reports "1.ls5.006", VERSION file reports "1.000, 4/21/92"
@@ -2177,7 +2212,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1015136},
{"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 987222},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 - Italian DOS Floppy (from glorifindel)
// SCI interpreter version 1.000.510 (just a guess)
@@ -2185,7 +2220,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a99776df795127f387cb35dae872d4e4", 5919},
{"resource.000", 0, "a8989a5a89e7d4f702b26b378c7a357a", 7001981},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 1.0 EGA DOS (8 x 3.5" disks)
// Provided by ssburnout in bug report #3046806
@@ -2200,7 +2235,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "f6046a8445422f17d40b1b10ab21ebf3", 568551},
{"resource.007", 0, "640ee65595d40372ef95462f2c1ae28a", 593429},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 5 EGA
// Supplied by omer_mor in bug report #3049771
@@ -2211,7 +2246,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "5a55af4e40728b1a8103dc47ad2afa8d", 1100539},
{"resource.003", 0, "16f4d8fb1b526125edaca4fc6cbb7530", 1064563},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - English DOS (from spookypeanut)
// SCI interpreter version 1.001.113
@@ -2219,7 +2254,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "bb8a39d9e2a77ba449a1e591109ad9a8", 6973},
{"resource.000", 0, "4462fe48c7452d98fddcec327a3e738d", 5789138},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - English/German/French DOS CD - LOWRES
// SCI interpreter version 1.001.115
@@ -2227,7 +2262,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "0b91234b7112782962cb480b7791b6e2", 7263},
{"resource.000", 0, "57d5fe8bb9e044158514476ea7678eb0", 5754790},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - German DOS CD - LOWRES (provided by richiefs in bug report #2670691)
// SCI interpreter version 1.001.115
@@ -2235,7 +2270,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "bafe85f32738854135991d4324ad147e", 7268},
{"resource.000", 0, "f6cbc6da7b90ea135883e0759848ca2c", 5773160},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - French DOS CD - LOWRES (provided by richiefs in bug report #2670691)
// SCI interpreter version 1.001.115
@@ -2243,7 +2278,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "97797ea775baaf18a1907d357d3c0ea6", 7268},
{"resource.000", 0, "f6cbc6da7b90ea135883e0759848ca2c", 5776092},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - Spanish DOS - LOWRES (from the Leisure Suit Larry Collection)
// Executable scanning reports "1.001.113", VERSION file reports "1.000, 11.06.93, FIVE PATCHES ADDED TO DISK 6 ON 11-18-93"
@@ -2251,7 +2286,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "633bf8f42170b6271019917c8009989b", 6943},
{"resource.000", 0, "7884a8db9253e29e6b37a2651fd90ba3", 5733116},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Crazy Nick's Software Picks: Leisure Suit Larry's Casino - English DOS (from the Leisure Suit Larry Collection)
// Executable scanning reports "1.001.029", VERSION file reports "1.000"
@@ -2259,35 +2294,35 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "194f1578f2624db813c9072359ad1639", 783},
{"resource.001", 0, "3733433b517ec3d14a3331d9ab3842ae", 344830},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Crazy Nick's Software Picks: King Graham's Board Game Challenge
{"cnick-kq", "", {
{"resource.map", 0, "44bc538a5cd24b39ffccc967c0ebf84d", 1137},
{"resource.001", 0, "470e7a4a3504635e70b623c44461e1ac", 451272},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Crazy Nick's Software Picks: Parlor Games with Laura Bow
{"cnick-laurabow", "", {
{"resource.map", 0, "3b826bfe64f8ff1ccf30eef93cd2f727", 999},
{"resource.001", 0, "985ac8db6f636f2b4334c04b0fbb44fb", 336698},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Crazy Nick's Software Picks: Robin Hood's Game of Skill and Chance
{"cnick-longbow", "", {
{"resource.map", 0, "4a5c81f485a2416bde12978506f2fb5f", 897},
{"resource.001", 0, "ef16dc9e867eb8eeb5b13e110b90bd4b", 571466},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Crazy Nick's Software Picks: Roger Wilco's Spaced Out Game Pack
{"cnick-sq", "", {
{"resource.map", 0, "b4d95b02d84e297441bd999d34eaa6b1", 879},
{"resource.001", 0, "82ff2b64a60117886fbcd6a3a8c977c6", 364921},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Larry 6 - English/German DOS CD - HIRES
@@ -2296,7 +2331,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "0c0804434ea62278dd15032b1947426c", 8872},
{"resource.000", 0, "9a9f4870504444cda863dd14d077a680", 18520872},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - German DOS CD - HIRES (provided by richiefs in bug report #2670691)
// SCI interpreter version 2.100.002
@@ -2304,7 +2339,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "badfdf446ffed569a310d2c63a249421", 8896},
{"resource.000", 0, "bd944d2b06614a5b39f1586906f0ee88", 18534274},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 6 - French DOS CD - HIRES (provided by richiefs in bug report #2670691)
// SCI interpreter version 2.100.002
@@ -2312,7 +2347,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "d184e9aa4f2d4b5670ddb3669db82cda", 8896},
{"resource.000", 0, "bd944d2b06614a5b39f1586906f0ee88", 18538987},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 7 - English DOS Demo (provided by richiefs in bug report #2670691)
// SCI interpreter version 2.100.002
@@ -2320,7 +2355,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"ressci.000", 0, "5cc6159688b2dc03790a67c90ccc67f9", 10195878},
{"resmap.000", 0, "6a2b2811eef82e87cde91cf1de845af8", 2695},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI3_GAMES
// Larry 7 - English DOS CD (from spookypeanut)
@@ -2329,7 +2364,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "eae93e1b1d1ccc58b4691c371281c95d", 8188},
{"ressci.000", 0, "89353723488219e25589165d73ed663e", 66965678},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 7 - German DOS (from Tobis87)
// SCI interpreter version 3.000.000
@@ -2337,7 +2372,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "c11e6bfcfc2f2d05da47e5a7df3e9b1a", 8188},
{"ressci.000", 0, "a8c6817bb94f332ff498a71c8b47f893", 66971724},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 7 - French DOS (provided by richiefs in bug report #2670691)
// SCI interpreter version 3.000.000
@@ -2345,7 +2380,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "4407849fd52fe3efb0c30fba60cd5cd4", 8206},
{"ressci.000", 0, "dc37c3055fffbefb494ff22b145d377b", 66964472},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 7 - Italian DOS CD (from glorifindel)
// SCI interpreter version 3.000.000
@@ -2353,7 +2388,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "9852a97141f789413f29bf956052acdb", 8212},
{"ressci.000", 0, "440b9fed89590abb4e4386ed6f948ee2", 67140181},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Larry 7 - Spanish DOS (from the Leisure Suit Larry Collection)
// Executable scanning reports "3.000.000", VERSION file reports "1.0s"
@@ -2361,7 +2396,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "8f3d603e1acc834a5d598b30cdfc93f3", 8188},
{"ressci.000", 0, "32792f9bc1bf3633a88b382bb3f6e40d", 67071418},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif
// Lighthouse - English Windows Demo (from jvprat)
@@ -2370,7 +2405,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "543124606352bfa5e07696ddf2a669be", 64},
{"resource.000", 0, "5d7714416b612463d750fb9c5690c859", 28952},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI3_GAMES
// Lighthouse - English Windows Demo
@@ -2379,7 +2414,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "3bdee7a16926975a4729f75cf6b80a92", 1525},
{"ressci.000", 0, "3c585827fa4a82f4c04a56a0bc52ccee", 11494351},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Lighthouse - English DOS (from jvprat)
// Executable scanning reports "3.000.000", VERSION file reports "1.1"
@@ -2389,7 +2424,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.002", 0, "c68db5333f152fea6ca2dfc75cad8b34", 7573},
{"ressci.002", 0, "175468431a979b9f317c294ce3bc1430", 94628315},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Lighthouse - Spanish DOS (from jvprat)
// Executable scanning reports "3.000.000", VERSION file reports "1.1"
@@ -2399,7 +2434,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.002", 0, "e7dc85884a2417e2eff9de0c63dd65fa", 7630},
{"ressci.002", 0, "3c8d627c555b0e3e4f1d9955bc0f0df4", 94631127},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI3_GAMES
#endif // ENABLE_SCI32
@@ -2410,7 +2445,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "8be56a3a88c065ee00c02c0e29199f3a", 14643},
{"resource.001", 0, "9e33566515b18bee7915db448063bba2", 871853},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Fairy Tales - English DOS Floppy EGA (from omer_mor, bug report #3035350)
{"fairytales", "EGA", {
@@ -2421,7 +2456,18 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "509b2467ba779100d5933ed51a9ae32f", 560255},
{"resource.004", 0, "93afc85d5ffa60ea555d6cc336d22c03", 651109},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Mixed-Up Fairy Tales - English DOS Floppy EGA (from misterhands, bug report #6596)
+ // Version 1.0, interpreter 1.000.158, INT# 11.23.91
+ {"fairytales", "EGA", {
+ {"resource.map", 0, "de9e151517013af15e0baf7bd8cbfe0b", 3243},
+ {"resource.000", 0, "27ec5fa09cd12a7fd16e86d96a2ed245", 840595},
+ {"resource.001", 0, "6ef4acdab49bdcaccf649640ddb12e9a", 115071},
+ {"resource.002", 0, "020d8c9da753a30899dd10c4463682db", 762020},
+ {"resource.003", 0, "9e0dea6b2bfd6cf0007cceb866bcbfb3", 670688},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Fairy Tales v1.000 - English DOS (supplied by markcoolio in bug report #2723791)
// Executable scanning reports "1.000.145"
@@ -2433,7 +2479,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "b1288e0821ee358d1ffe877e5900c8ec", 1047565},
{"resource.004", 0, "f79daa70390d73746742ffcfc3dc4471", 937580},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Fairy Tales - English DOS Floppy (from jvprat)
// Executable scanning reports "1.000.145", Floppy label reports "1.0, 11.13.91", VERSION file reports "1.000"
@@ -2444,7 +2490,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "564f516d991032e781492592a4eaa275", 1414142},
{"resource.003", 0, "dd6cef0c592eadb7e6be9a25307c57a2", 1344719},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose - English Amiga (from www.back2roots.org)
// Executable scanning reports "1.003.009"
@@ -2454,7 +2500,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "fb552ae550ca1dac19ed8f6a3767612d", 262885},
{"resource.002", 0, "fb552ae550ca1dac19ed8f6a3767612d", 817191},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose - English DOS Floppy EGA (from omer_mor, bug report #3035354)
{"mothergoose", "EGA", {
@@ -2462,7 +2508,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "d893892d62b3f061357291d66775e360", 239906},
{"resource.002", 0, "d893892d62b3f061357291d66775e360", 719398},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose - English DOS Floppy EGA (supplied by ssburnout in bug report #3049193)
// 1.011 5x5.25" (label: Int#8.2.90)
@@ -2475,7 +2521,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "dbbc22f124533ce308bc386b08956326", 146251},
{"resource.005", 0, "2ba5348e7fad641b9c4c7ff7c7cf4e68", 110979},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose v2.000 - English DOS Floppy (supplied by markcoolio in bug report #2723795)
// Executable scanning reports "1.001.031"
@@ -2483,7 +2529,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "52aae15e493cafd1da7e1c9b657a5bb9", 7026},
{"resource.000", 0, "b7ecd8ae9e254e80310b5a668b276e6e", 2948975},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose - English DOS CD (from jvprat)
// Executable scanning reports "x.yyy.zzz"
@@ -2492,7 +2538,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "1c7f311b0a2c927b2fbe81ae341fb2f6", 5790},
{"resource.001", 0, "5a0ed1d745855148364de1b3be099bac", 4369438},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose - English Windows Interactive Demo
// Executable scanning reports "x.yyy.zzz"
@@ -2500,19 +2546,19 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "87f9dc1cafc4d4fa835fb2f00cf3a6ef", 4560},
{"resource.001", 0, "5a0ed1d745855148364de1b3be099bac", 2070072},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose - FM-Towns (supplied by abevi in bug report #3038720)
{"mothergoose256", "", {
{"resource.map", 0, "b11e971ccd2040bebba59dfb409a08ef", 5772},
{"resource.001", 0, "d49625d9b8005ec01c852f8322a82867", 4330713},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformFMTowns, 0, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformFMTowns, 0, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
{"mothergoose256", "", {
{"resource.map", 0, "b11e971ccd2040bebba59dfb409a08ef", 5772},
{"resource.001", 0, "d49625d9b8005ec01c852f8322a82867", 4330713},
AD_LISTEND},
- Common::JA_JPN, Common::kPlatformFMTowns, 0, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::JA_JPN, Common::kPlatformFMTowns, 0, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Mixed-Up Mother Goose Deluxe - English Windows/DOS CD (supplied by markcoolio in bug report #2723810)
@@ -2521,7 +2567,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "5159a1578c4306bfe070a3e4d8c2e1d3", 4741},
{"resource.000", 0, "1926925c95d82f0999590e93b02887c5", 15150768},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Mixed-Up Mother Goose Deluxe - Multilingual Windows CD (English/French/German/Spanish)
// Executable scanning reports "2.100.002"
@@ -2529,7 +2575,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "ef611af561898dcfea87846919ebf3eb", 4969},
{"ressci.000", 0, "227685bc59d90821978d330713e44a7a", 17205800},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI32
// Ms. Astro Chicken - English DOS
@@ -2538,7 +2584,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "5b457cbe5042f557e5b610148171f6c0", 1158},
{"resource.001", 0, "453ea81ef66a50cbe33ce06302afe47f", 229737},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Phantasmagoria - English DOS (from jvprat)
@@ -2559,7 +2605,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.007", 0, "afbd16ea77869a720afa1c5371de107d", 7972},
//{"ressci.007", 0, "3aae6559aa1df273bc542d5ac6330d75", 25859038},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Phantasmagoria - English DOS Demo
// Executable scanning reports "2.100.002"
@@ -2567,7 +2613,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.001", 0, "416138651ea828219ca454cae18341a3", 11518},
{"ressci.001", 0, "3aae6559aa1df273bc542d5ac6330d75", 65844612},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Phantasmagoria - English DOS/Windows (GOG version) - ressci.* merged in ressci.000
// Windows executable scanning reports "2.100.002" - "Sep 19 1995 15:09:43"
@@ -2578,7 +2624,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"ressci.000", 0, "cd5967f9b9586e3380645961c0765be3", 116822037},
{"resmap.000", 0, "3cafc1c6a53945c1f3babbfd6380c64c", 16468},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Phantasmagoria - English Macintosh
// NOTE: This only contains disc 1 files (as well as the two persistent files:
@@ -2611,7 +2657,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.005", 0, "8bd5ceeedcbe16dfe55d1b90dcd4be84", 1942},
{"ressci.005", 0, "05f9fe2bee749659acb3cd2c90252fc5", 67905112},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Phantasmagoria 2 - English DOS (GOG version) - ressci.* merged in ressci.000
// Executable scanning reports "3.000.000" - "Dec 07 1996 09:29:03"
@@ -2621,7 +2667,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"ressci.000", 0, "c54f26d9f43f908151263254b6d97053", 108134481},
{"resmap.000", 0, "de154a223a9ef4ea7358b76adc38ef5b", 2956},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI3_GAMES
#endif // ENABLE_SCI32
@@ -2632,7 +2678,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "72726dc81c1b4c1110c486be77369bc8", 5179},
{"resource.000", 0, "670d0c53622429f4b11275caf7f8d292", 5459574},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Pepper - English DOS Non-Interactive Demo
// Executable scanning reports "1.001.060", VERSION file reports "1.000"
@@ -2640,7 +2686,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "379bb4fb896630b14f2d91ed21e36ba1", 984},
{"resource.000", 0, "118f6c31a93ec7fd9a231c61125229e3", 645494},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Pepper - English DOS/Windows Interactive Demo
// Executable scanning reports "1.001.069", VERSION file reports ".001"
@@ -2648,7 +2694,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "975e8df76106a5c13d12ab674f906a02", 2514},
{"resource.000", 0, "e6a918a2dd7a4bcecd8fb389f43287c2", 1698164},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Pepper - English DOS Interactive Demo
// Executable scanning reports "1.001.072", VERSION file reports "1.000"
@@ -2656,7 +2702,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "9c9b7b900651a370dd3fb38d478b1798", 2524},
{"resource.000", 0, "e6a918a2dd7a4bcecd8fb389f43287c2", 1713544},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 1 VGA Remake - English DOS (from the Police Quest Collection)
// Executable scanning reports "1.001.029", VERSION file reports "2.000"
@@ -2664,7 +2710,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "35efa814fb994b1cbdac9611e401da67", 5013},
{"resource.000", 0, "e0d5ddf34eda903a38f0837e2aa7145b", 6401433},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 - English Amiga (from www.back2roots.org)
// SCI interpreter version 0.000.685 (just a guess)
@@ -2675,7 +2721,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "499737c21a28ac026e11ab817100d610", 511099},
{"resource.003", 0, "e008f5d6e2a7c4d4a0da0173e4fa8f8b", 553970},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 - English DOS Non-Interactive Demo
// Executable scanning reports "0.000.413"
@@ -2683,7 +2729,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8b77d0d4650c2052b356cece28294b58", 576},
{"resource.001", 0, "376ef6d6eaaeed66e1424bd219c4b9ab", 215398},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 - English DOS (provided by richiefs in bug report #2670691)
// SCI interpreter version 0.000.395
@@ -2696,7 +2742,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "77f02def3094af804fd2371db25b7100", 349899},
{"resource.006", 0, "77f02def3094af804fd2371db25b7100", 354991},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 - English DOS (from the Police Quest Collection)
// Executable scanning reports "0.000.490"
@@ -2706,7 +2752,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "77f02def3094af804fd2371db25b7100", 546000},
{"resource.003", 0, "77f02def3094af804fd2371db25b7100", 591851},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 - English DOS (from FRG)
// SCI interpreter version 0.000.395
@@ -2716,7 +2762,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "77f02def3094af804fd2371db25b7100", 542897},
{"resource.003", 0, "77f02def3094af804fd2371db25b7100", 586857},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 English DOS 1.001.006 (supplied by merkur-kun in bug report #3028479)
{"pq2", "", {
@@ -2725,7 +2771,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "77f02def3094af804fd2371db25b7100", 541261},
{"resource.003", 0, "77f02def3094af804fd2371db25b7100", 587511},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 2 - Japanese PC-98 (also includes english language)
// SCI interpreter version unknown
@@ -2735,7 +2781,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "05fdee43a228dd6ea4d1a92ccae3f788", 637662},
{"resource.003", 0, "05fdee43a228dd6ea4d1a92ccae3f788", 684395},
AD_LISTEND},
- Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 - English Amiga
// Executable scanning reports "1.004.024"
@@ -2748,7 +2794,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "630bfa65beb05f743552704ac2899dae", 759891},
{"resource.004", 0, "7b229fbdf30d670d0728cede3e984a7e", 838663},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 - German Amiga (also includes english language)
// Executable scanning reports "1.004.024"
@@ -2762,7 +2808,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "6258d5dd85898d8e218eb8113ebc9059", 722738},
{"resource.005", 0, "6258d5dd85898d8e218eb8113ebc9059", 704485},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 - English DOS (from the Police Quest Collection)
// Executable scanning reports "T.A00.178", VERSION file reports "1.00"
@@ -2775,7 +2821,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "8791b9eef53edf77c2dac950142221d3", 1159791},
{"resource.004", 0, "1b91e891a3c60a941dac0eecdf83375b", 1143606},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 - English DOS Non-Interactive Demo
// Executable scanning reports "T.A00.052"
@@ -2785,7 +2831,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "277f97771f7a6d89677141f02da313d6", 65150},
{"resource.001", 0, "5c5a551b6c86cce2ee75becb90e0b586", 624411},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 - German DOS (supplied by markcoolio in bug report #2723837, also includes english language)
// Executable scanning reports "T.A00.178"
@@ -2798,14 +2844,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "4836f460f4cfc8de61e2df4c45775504", 1180956},
{"resource.004", 0, "0c3eb84b9755852d9e795e0d5c9373c7", 1171760},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 - Spanish DOS v1.000 - Supplied by dianiu in bug report #3555647
{"pq3", "", {
{"resource.map", 0, "ffa0b4631c4e36d69631256d19ba29e7", 5421},
{"resource.000", 0, "5ee460af3d70c06a745cc482b6c783ba", 5410263},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 3 EGA
// Reported by musiclyinspired in bug report #3046573
@@ -2818,7 +2864,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "b96a86ab681769e4cbb439670d967ca6", 449682},
{"resource.005", 0, "9e6c53a0e7eef53694d260fade8b1fc7", 724000},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 4 - English DOS Non-Interactive Demo (from FRG)
// SCI interpreter version 1.001.096
@@ -2826,7 +2872,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "be56f87a1c4a13062a30a362df860c2f", 1472},
{"resource.000", 0, "527d5684016e6816157cd15d9071b11b", 1121310},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Police Quest 4 - English DOS CD (from the Police Quest Collection)
@@ -2835,7 +2881,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "379dfe80ed6bd16c47e4b950c4722eac", 11374},
{"resource.000", 0, "fd316a09b628b7032248139003369022", 18841068},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 4 - German DOS CD (German text, English speech)
// Supplied by markcoolio in bug report #3392955
@@ -2843,7 +2889,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a398076371ed0e1e706c8f9fb9fc7ac5", 11386},
{"resource.000", 0, "6ff21954e0a2c5992279e7eb787c8d56", 18918747},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 4 - English DOS
// SCI interpreter version 2.000.000 (a guess?)
@@ -2851,7 +2897,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "aed9643158ccf01b71f359db33137f82", 9895},
{"resource.000", 0, "da383857b3be1e4514daeba2524359e0", 15141432},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 4 - French DOS (supplied by abevi in bug report #2612718)
// SCI interpreter version 2.000.000
@@ -2859,7 +2905,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "008030846edcc7c5c7a812c7f4ae4ceb", 9256},
{"resource.000", 0, "6ba98bd2e436739d87ecd2a9b99cabb4", 14730153},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest 4 - German DOS (supplied by markcoolio in bug report #2723840)
// SCI interpreter version 2.000.000 (a guess?)
@@ -2867,7 +2913,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "2393ee728ab930b2762cb5889f9b5aff", 9256},
{"resource.000", 0, "6ba98bd2e436739d87ecd2a9b99cabb4", 14730155},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest: SWAT - English DOS/Windows Demo (from jvprat)
// Executable scanning reports "2.100.002", VERSION file reports "0.001.200"
@@ -2875,7 +2921,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8c96733ef94c21526792f7ca4e3f2120", 1648},
{"resource.000", 0, "d8892f1b8c56c8f7704325460f49b300", 3676175},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest: SWAT - English DOS (from GOG.com)
// Executable scanning reports "2.100.002", VERSION file reports "1.0c"
@@ -2883,7 +2929,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "1c2563fee189885e29d9348f37306d94", 12175},
{"ressci.000", 0, "b2e1826ca81ce2e7e764587f5a14eee9", 127149181},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Police Quest: SWAT - English Windows (from the Police Quest Collection)
// Executable scanning reports "2.100.002", VERSION file reports "1.0c"
@@ -2898,7 +2944,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.004", 0, "4228038906f041623e65789500b22285", 6835},
{"ressci.004", 0, "b7e619e6ecf62fe65d5116a3a422e5f0", 46223872},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI32
// Quest for Glory 1 / Hero's Quest - English DOS 3.5" Floppy (supplied by merkur in bug report #2718784)
@@ -2911,7 +2957,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "7ab2bf8e224b57f75e0cd6e4ba790761", 642203},
{"resource.004", 0, "7ab2bf8e224b57f75e0cd6e4ba790761", 641688},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS 3.5" Floppy (supplied by alonzotg in bug report #3206006)
{"qfg1", "", {
@@ -2922,7 +2968,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "7ab2bf8e224b57f75e0cd6e4ba790761", 642203},
{"resource.004", 0, "7ab2bf8e224b57f75e0cd6e4ba790761", 641688},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS 3.5" Floppy v1.102 Int#0.000.629 (suppled by digitoxin1 in bug report #3554611)
{"qfg1", "", {
@@ -2933,7 +2979,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "f0af87c60ec869946da442833aa5afa8", 640502},
{"resource.004", 0, "f0af87c60ec869946da442833aa5afa8", 644575},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS 5.25" Floppy v1.102 Int#0.000.629 (suppled by digitoxin1 in bug report #3554611)
{"qfg1", "", {
@@ -2947,7 +2993,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "48b2b3c964dcbeccb68e984e6d4e97db", 278473},
{"resource.007", 0, "f0af87c60ec869946da442833aa5afa8", 269237},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS 5.25" Floppy (supplied by markcoolio in bug report #2723843)
// Executable scanning reports "0.000.566"
@@ -2962,7 +3008,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "69366c2a2f99917199fe1b60a4fee19d", 267852},
{"resource.007", 0, "7ab2bf8e224b57f75e0cd6e4ba790761", 272747},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS 5.25" Floppy (supplied by ssburnout in bug report #3049193)
// 1.001 10x5.25" (label: INT.#0.000.566)
@@ -2977,7 +3023,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "69366c2a2f99917199fe1b60a4fee19d", 267852},
{"resource.007", 0, "7ab2bf8e224b57f75e0cd6e4ba790761", 272747},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS 5.25" Floppy (supplied by ssburnout in bug report #3049193)
// 1.200 10x5.25" (label: INT#9.10.90)
@@ -2992,7 +3038,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "f46690dca714abc8c89357d30e363dd3", 278387},
{"resource.007", 0, "951299a82a8134ed12c5c18118d45c2f", 269173},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 / Hero's Quest - English DOS Demo
// Executable scanning reports "0.000.685"
@@ -3000,7 +3046,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "df34c758cbb9026da175793ff686b0e6", 882},
{"resource.001", 0, "73fbaafdd313b39aeedb80fbf85ecef1", 389884},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 - Japanese PC-98 5.25" Floppy (also includes English language)
// Executable scanning reports "S.old.201"
@@ -3010,7 +3056,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "a21451ef6fa8179bd4b22c4950004c44", 1136968},
{"resource.003", 0, "a21451ef6fa8179bd4b22c4950004c44", 769897},
AD_LISTEND},
- Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO3(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_EGA_UNDITHER) },
+ Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO3(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_EGA_UNDITHER) },
// Quest for Glory 1 - Japanese PC-98 5.25" Floppy (also includes English language)
// Executable scanning reports "S.old.201"
@@ -3020,7 +3066,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "a21451ef6fa8179bd4b22c4950004c44", 1147121},
{"resource.003", 0, "a21451ef6fa8179bd4b22c4950004c44", 777575},
AD_LISTEND},
- Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO3(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_EGA_UNDITHER) },
+ Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO3(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_EGA_UNDITHER) },
// Quest for Glory 1 - English Amiga
// Executable scanning reports "1.002.020"
@@ -3034,7 +3080,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "16cd4414c37ae3bb6d6da33dce8e25e8", 689124},
{"resource.005", 0, "5f3386ef2f2b1254e4a066f5d9027324", 609529},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 - English DOS
// SCI interpreter version 0.000.629
@@ -3046,7 +3092,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "951299a82a8134ed12c5c18118d45c2f", 640483},
{"resource.004", 0, "951299a82a8134ed12c5c18118d45c2f", 644443},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 VGA Remake - English DOS
// Executable scanning reports "2.000.411"
@@ -3054,7 +3100,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a731fb6c9c0b282443f7027bc8694d4c", 8469},
{"resource.000", 0, "ecace1a2771846b1a8aa1afdd44111a0", 6570147},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 VGA Remake - English DOS Non-Interactive Demo (from FRG)
// SCI interpreter version 1.001.029
@@ -3062,7 +3108,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "ac0257051c95a59c0cdc0be24d9b11fa", 729},
{"resource.000", 0, "ec6f5cf369054dd3e5392995e9975b9e", 768218},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 1 VGA Remake - English Macintosh Floppy
// VERSION file reports "2.0"
@@ -3070,7 +3116,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"Data1", 0, "106527ff8756e4e1a795d63d23e8b833", 1752358},
{"Data2", 0, "5cdd92033231159c6e9c71d43e9f194d", 6574746},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English Amiga
// Executable scanning reports "1.003.004"
@@ -3086,7 +3132,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "ccf5dba33e5cab6d5872838c0f8db44c", 500039},
{"resource.007", 0, "4c9fc1587545879295cb9627f56a2cb8", 575056},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English (supplied by ssburnout in bug report #3049193)
// 1.000 5x5.25" (label: INT#10.31.90)
@@ -3098,7 +3144,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "0790f67d87642132be515cab05026baa", 972144},
{"resource.004", 0, "2ac1e6fea9aa1f5b91a06693a67b9766", 982830},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English (supplied by ssburnout in bug report #3049193)
// 1.000 9x3.5" (label: INT#10.31.90)
@@ -3113,7 +3159,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "5e9deacbdb17198ad844988e04833520", 498593},
{"resource.007", 0, "2ac1e6fea9aa1f5b91a06693a67b9766", 490151},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English (from FRG)
// Executable scanning reports "1.000.072"
@@ -3125,7 +3171,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "b192607c42f6960ecdf2ad2e4f90e9bc", 972804},
{"resource.004", 0, "cd2de58e27665d5853530de93fae7cd6", 983617},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English DOS
// Executable scanning reports "1.000.072"
@@ -3140,7 +3186,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "b1944bd664ddbd2859cdaa0c4a0d6281", 507489},
{"resource.007", 0, "cd2de58e27665d5853530de93fae7cd6", 490794},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English DOS (supplied by digitoxin1 in bug report #3554614)
// v1.102 9x3.5" (label: Int#11.20.90)
@@ -3155,7 +3201,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "b1944bd664ddbd2859cdaa0c4a0d6281", 507489},
{"resource.007", 0, "cd2de58e27665d5853530de93fae7cd6", 490794},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 2 - English DOS Non-Interactive Demo
// Executable scanning reports "1.000.046"
@@ -3163,7 +3209,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "e75eb86bdd517b3ef709058249986a87", 906},
{"resource.001", 0, "9b098f9e1008abe30e56c93b896494e6", 362123},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - English DOS Non-Interactive Demo (from FRG)
// Executable scanning reports "1.001.021", VERSION file reports "1.000, 0.001.059, 6.12.92"
@@ -3171,7 +3217,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "fd71de9b588a45f085317caacf050e91", 687},
{"resource.000", 0, "b6c69bf6c18bf177492249fe81fc6a6d", 648702},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - English DOS
// SCI interpreter version 1.001.050
@@ -3179,7 +3225,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "19e2bf9b693932b5e2bb59b9f9ab86c9", 5958},
{"resource.000", 0, "6178ad2e83e58e4671ca03315f7a6498", 5868000},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - English DOS (supplied by abevi in bug report #2612718)
// SCI interpreter version 1.001.050
@@ -3187,7 +3233,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "62c185d190363d7df06330fa0cc45b36", 5958},
{"resource.000", 0, "6178ad2e83e58e4671ca03315f7a6498", 5867442},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - English DOS (supplied by dknute in bug report #3125559)
{"qfg3", "", {
@@ -3195,7 +3241,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "6178ad2e83e58e4671ca03315f7a6498", 5868042},
{"resource.msg", 0, "27e5419c98ce444253f88c95dced14a9", 246888},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - German DOS (supplied by markcoolio in bug report #2723846)
// Executable scanning reports "L.rry.083"
@@ -3203,7 +3249,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "19e2bf9b693932b5e2bb59b9f9ab86c9", 5958},
{"resource.000", 0, "6178ad2e83e58e4671ca03315f7a6498", 5868042},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - French DOS v1.1 (supplied by misterhands in bug report #3586214)
// Executable scanning reports "L.rry.083"
@@ -3212,7 +3258,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "6178ad2e83e58e4671ca03315f7a6498", 5868000},
{"resource.msg", 0, "0fa1047002df904b8d1807bb7bab4fab", 267210},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - Spanish DOS CD (from jvprat)
// Executable scanning reports "L.rry.083", VERSION file reports "1.000.000, June 30, 1994"
@@ -3221,7 +3267,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "ba7ac86155e4c531e46cd73c86daa80a", 5884098},
{"resource.msg", 0, "a63974730d294dec0bea10057c36e506", 256014},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 3 - Italian DOS
// Supplied by ghoost in bug report #3053457
@@ -3230,7 +3276,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "6178ad2e83e58e4671ca03315f7a6498", 5868000},
{"resource.msg", 0, "5a0a896ff3e4a628db38a75eb6c84114", 259018},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 4 - English DOS Non-Interactive Demo (from FRG)
// SCI interpreter version 1.001.069 (just a guess)
@@ -3238,7 +3284,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "1ba7c7ae1efb315326d45cb931569b1b", 922},
{"resource.000", 0, "41ba03f0b188b029132daa3ece0d3e14", 623154},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Quest for Glory 4 1.1 Floppy - English DOS (supplied by markcool in bug report #2723852)
@@ -3247,7 +3293,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "685bdb1ed47bbbb0e5e25db392da83ce", 9301},
{"resource.000", 0, "f64fd6aa3977939a86ff30783dd677e1", 11004993},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 4 1.1 Floppy - English DOS (supplied by abevi in bug report #2612718)
// SCI interpreter version 2.000.000
@@ -3255,7 +3301,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "d10a4cc177d2091d744e2ad8c049b0ae", 9295},
{"resource.000", 0, "f64fd6aa3977939a86ff30783dd677e1", 11003589},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 4 1.1 Floppy - German DOS (supplied by markcool in bug report #2723850)
// Executable scanning reports "2.000.000", VERSION file reports "1.1"
@@ -3263,7 +3309,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "9e0abba8746f40565bc7eb5720522ecd", 9301},
{"resource.000", 0, "57f22cdc54eeb35fce1f26b31b5c3ee1", 11076197},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_UNSTABLE, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Quest for Glory 4 CD - English DOS/Windows (from jvprat)
// Executable scanning reports "2.100.002", VERSION file reports "1.0"
@@ -3271,7 +3317,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "aba367f2102e81782d961b14fbe3d630", 10246},
{"resource.000", 0, "263dce4aa34c49d3ad29bec889007b1c", 11571394},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// RAMA - English DOS/Windows Demo
// Executable scanning reports "2.100.002", VERSION file reports "000.000.008"
@@ -3279,7 +3325,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.001", 0, "775304e9b2a545156be4d94209550094", 1393},
{"ressci.001", 0, "259437fd75fdf51e8207fda8c01fa4fd", 2334384},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI3_GAMES
// RAMA - English Windows (from jvprat)
@@ -3292,7 +3338,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.003", 0, "31ef4c0621711585d031f0ae81707251", 1636},
{"ressci.003", 0, "2a68edd064e5e4937b5e9c74b38f2082", 6860492},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// RAMA - English Windows (from Quietust, in bug report #2850645)
{"rama", "", {
@@ -3303,18 +3349,18 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.003", 0, "48841e4b84ef1b98b48d43566fda9e13", 1636},
{"ressci.003", 0, "2a68edd064e5e4937b5e9c74b38f2082", 6870356},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// RAMA - German Windows CD (from farmboy0, in pull request 397)
{"rama", "", {
{"resmap.001", 0, "f68cd73308c46977a9632dfc618e1e38", 8338},
- {"ressci.001", 0, "2a68edd064e5e4937b5e9c74b38f2082", 70595521},
- {"resmap.002", 0, "891fc2f5d9e23e7d9a9454acc7aaae52", 12082},
- {"ressci.002", 0, "2a68edd064e5e4937b5e9c74b38f2082", 128508558},
- {"resmap.003", 0, "222096000bd83a1d56577114a452cccf", 1636},
- {"ressci.003", 0, "2a68edd064e5e4937b5e9c74b38f2082", 6954219},
+ {"ressci.001", 0, "2a68edd064e5e4937b5e9c74b38f2082", 70595521},
+ {"resmap.002", 0, "891fc2f5d9e23e7d9a9454acc7aaae52", 12082},
+ {"ressci.002", 0, "2a68edd064e5e4937b5e9c74b38f2082", 128508558},
+ {"resmap.003", 0, "222096000bd83a1d56577114a452cccf", 1636},
+ {"ressci.003", 0, "2a68edd064e5e4937b5e9c74b38f2082", 6954219},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// RAMA - Italian Windows CD (from glorifindel)
// SCI interpreter version 3.000.000 (a guess?)
@@ -3322,7 +3368,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"ressci.001", 0, "2a68edd064e5e4937b5e9c74b38f2082", 70611091},
{"resmap.001", 0, "70ba2ff04a2b7fb2c52420ba7fbd47c2", 8338},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI3_GAMES
// Shivers - English Windows (from jvprat)
@@ -3331,14 +3377,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "f2ead37749ed8f6535a2445a7d05a0cc", 46525},
{"ressci.000", 0, "4294c6d7510935f2e0a52e302073c951", 262654836},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Shivers - German Windows (from Tobis87)
{"shivers", "", {
{"resmap.000", 0, "f483d0a1f78334c18052e92785c3086e", 46537},
{"ressci.000", 0, "6751b144671e2deed919eb9d284b07eb", 262390692},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Shivers - English Windows Demo
// Executable scanning reports "2.100.002"
@@ -3346,7 +3392,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "d9e0bc5eddefcbe47f528760085d8927", 1186},
{"ressci.000", 0, "3a93c6340b54e07e65d0e5583354d186", 10505469},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Shivers 2 doesn't contain SCI scripts. The whole game logic has
// been reimplemented from SCI in native code placed in DLL files.
@@ -3364,7 +3410,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "d8659188b84beaef076bd869837cd530", 634},
{"ressci.000", 0, "7fbac0807a044c9543e8ac376d200e59", 4925003},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Shivers 2 - English Windows (from abevi)
// VERSION.TXT Version 1.0 (3/25/97)
@@ -3372,7 +3418,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"ressci.001", 0, "a79d03d6eb75be0a79324f14e3d2ace4", 95346793},
{"resmap.001", 0, "a4804d436d90c4ec2e46b537f5e954db", 6268},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif
@@ -3385,7 +3431,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.msg", 0, "1aeafe2b495de288d002109650b66614", 1364},
{"resource.000", 0, "8e10d4f05c1fd9f883384fa38a898489", 377394},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Slater & Charlie Go Camping - English DOS/Windows
{"slater", "", {
@@ -3393,7 +3439,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "21f85414124dc23e54544a5536dc35cd", 4044},
{"resource.msg", 0, "c44f51fb955eae266fecf360ebcd5ad2", 1132},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Slater & Charlie Go Camping - English DOS/Windows (Sierra Originals)
@@ -3402,14 +3448,14 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "21f85414124dc23e54544a5536dc35cd", 4044},
{"resource.msg", 0, "c44f51fb955eae266fecf360ebcd5ad2", 1132},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Slater & Charlie Go Camping - English Macintosh
{"slater", "", {
{"Data1", 0, "7243b4390e5f0182d8133fbcae4b50c5", 2298853},
{"Data2", 0, "6b6f18f9b502dc0923eeae0ef47f02d5", 2276956},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO1(GUIO_NONE) },
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK, GUIO1(GUIO_NONE) },
// Space Quest 1 VGA Remake - English Amiga (from www.back2roots.org)
// SCI interpreter version 1.000.510 (just a guess)
@@ -3422,7 +3468,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "b25a1539c71701f7715f738c5037e9a6", 775515},
{"resource.005", 0, "640ffe1a9acde392cc33cc1b1a528328", 806324},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 1 VGA Remake - English DOS (from the Space Quest Collection)
// Executable scanning reports "T.A00.081", VERSION file reports "2.000"
@@ -3435,7 +3481,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "c47600e50c6fc591957ae0c5020ee7b8", 1213262},
{"resource.004", 0, "e19ea4ad131472f9238590f2e1d40289", 1203051},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 1 VGA Remake - English Mac (from Fingolfin)
{"sq1sci", "SCI", {
@@ -3446,7 +3492,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "ae46e195e66df5a131917f0aa80b5669", 1242794},
{"resource.004", 0, "91d58a9eb2187c38424990afe4c12bc6", 1250949},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 1 VGA Remake - English Non-Interactive Demo (from FRG)
// SCI interpreter version 1.000.181
@@ -3454,7 +3500,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "5af709ac5e0e923e0b8174f49978c30e", 636},
{"resource.001", 0, "fd99ea43f57576ded7c86036996346cf", 507642},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 1 VGA Remake - Spanish DOS Floppy (from jvprat)
// Executable scanning reports "T.A00.081", VERSION file reports "2.000"
@@ -3468,7 +3514,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "9b78228ad4f9f335fedf74f1812dcfca", 513325},
{"resource.005", 0, "7d4ebcb745c0bf8fc42e4013f52ecd49", 1101812},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest I 2.0 EGA DOS (6 x 3.5" disks)
// Provided by ssburnout in bug report #3046805
@@ -3481,7 +3527,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "975c6e81194ae6b65e960a248129ecaa", 684119},
{"resource.005", 0, "13d96f7905637552c0647175ff816145", 695589},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - English Amiga (from www.back2roots.org)
// SCI interpreter version 0.000.453 (just a guess)
@@ -3492,7 +3538,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.003", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 746496},
{"resource.004", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 761984},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - German Amiga (also includes english language)
// Executable scanning reports "1.004.006"
@@ -3513,7 +3559,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "ec66ac2b1ce58b2575ba00b65058de1a", 612},
{"resource.001", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 180245},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - English DOS (provided by richiefs in bug report #2670691)
// SCI interpreter version 0.000.453
@@ -3523,7 +3569,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 720244},
{"resource.003", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 688367},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - English DOS (from the Space Quest Collection)
// Executable scanning reports "0.000.685", VERSION file reports "1.018"
@@ -3533,7 +3579,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "8b55c4875298f45ea5696a5ee8f6a7fe", 715777},
{"resource.003", 0, "8b55c4875298f45ea5696a5ee8f6a7fe", 703370},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - English DOS (from abevi, bug report #2612718)
{"sq3", "", {
@@ -3545,7 +3591,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 328278},
{"resource.006", 0, "ceeda7202b96e5c85ecaa88a40a540fc", 356702},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - English Mac (from Fingolfin)
{"sq3", "", {
@@ -3554,7 +3600,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "0d8dfe42683b46f3131823233a91ce6a", 794072},
{"resource.003", 0, "0d8dfe42683b46f3131823233a91ce6a", 776536},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 - German DOS (from Tobis87, also includes english language)
// SCI interpreter version 0.000.453 (?)
@@ -3568,7 +3614,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.006", 0, "9107c2aa5398e28b5c5406df13491f85", 320643},
{"resource.007", 0, "9107c2aa5398e28b5c5406df13491f85", 344287},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 3 v1.052 - German DOS (supplied by markcoolio in bug report #2723860, also includes english language)
// Executable scanning reports "S.old.114"
@@ -3578,7 +3624,18 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "9107c2aa5398e28b5c5406df13491f85", 596768},
{"resource.003", 0, "9107c2aa5398e28b5c5406df13491f85", 693573},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Space Quest 3 v1.1 (game says 0.016) - English Mac (supplied by misterhands in bug report #6484)
+ // Executable scanning reports "0.024"
+ {"sq3", "", {
+ {"resource.map", 0, "d1574928fc6187f5958d431ac9d8022e", 5844},
+ {"resource.001", 0, "0d8dfe42683b46f3131823233a91ce6a", 771942},
+ {"resource.002", 0, "0d8dfe42683b46f3131823233a91ce6a", 794127},
+ {"resource.003", 0, "0d8dfe42683b46f3131823233a91ce6a", 776554},
+ {"resource.004", 0, "0d8dfe42683b46f3131823233a91ce6a", 787066},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English Amiga
// Executable scanning reports "1.004.024"
@@ -3593,7 +3650,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "3540d1cc84d674cf4b2c898b88a3b563", 790296},
{"resource.006", 0, "ade814bc4d56244c156d9e9bcfebbc11", 664085},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformAmiga, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - German Amiga (from www.back2roots.org, also includes english language)
// SCI interpreter version 1.000.200 (just a guess)
@@ -3607,7 +3664,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "10ee1709e6559c724676d058199b75b5", 818745},
{"resource.006", 0, "67fb188b191d88efe8414af6ea297b93", 672675},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformAmiga, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English DOS - THIS VERSION IS PIRATED/CRACKED AND REPACKAGED =DO NOT RE-ADD=
// Executable scanning reports "1.000.753"
@@ -3616,7 +3673,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a18088c8aceb06025dbc945f29e02935", 5124},
{"resource.000", 0, "e1f46832cd2458796028e054a0466031", 5502009},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_PIRATED, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_PIRATED, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English DOS
// Executable scanning reports "1.000.753"
@@ -3625,7 +3682,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "71ccf4f82ac4efb588731acfb7bf2603", 5646},
{"resource.000", 0, "e1f46832cd2458796028e054a0466031", 933928},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 1.052 - English DOS Floppy (supplied by markcoolio in bug report #2723865)
// Executable scanning reports "1.000.753"
@@ -3639,7 +3696,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "ff9c87da3bc53473fdee8b9d3edbc93c", 1200631},
{"resource.005", 0, "e33019ac19f755ae33fbf49b4fc9066c", 1053294},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 1.000 - French DOS Floppy (supplied by misterhands in bug report #3515247)
{"sq4", "", {
@@ -3652,7 +3709,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "b2cca3afcf2e013b8ce86b64155af766", 1254353},
{"resource.005", 0, "9e520577e035547c4b5149a6d12ef85b", 1098814},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 1.000 - English DOS Floppy (from abevi, bug report #2612718)
{"sq4", "", {
@@ -3664,7 +3721,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "c06350184a490c10eb4585fff0aa3192", 1254368},
{"resource.005", 0, "b8d6efbd3235329bfe844c794097b2c9", 1098717},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest IV DOS 1.060 EGA (6 x 3.5" disks)
// Supplied by ssburnout in bug report #3046781
@@ -3677,7 +3734,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "9a673e33c3f6dd560b993ffed77eeb49", 534994},
{"resource.005", 0, "3c4841d0a3ebba4404af588c93620c22", 595465},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO5(GUIO_NOSPEECH, GAMEOPTION_EGA_UNDITHER, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - German DOS (from Tobis87, also includes english language)
// SCI interpreter version 1.000.200 (just a guess)
@@ -3691,7 +3748,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "47ee647b5b12232d27e63cc627c25899", 1156765},
{"resource.006", 0, "dfb023e4e2a1e7a00fa18f9ede72a91b", 924059},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - Italian DOS Floppy (from glorifindel, also includes english language)
// SCI interpreter version 1.000.200 (just a guess)
@@ -3704,7 +3761,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "4277c61bed40a50dadc4b5a344520af2", 1251000},
{"resource.005", 0, "5f885abd335978e2fd4e5f886d7676c8", 1102880},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - Japanese PC-98 5.25" Floppy (also includes english language)
// SCI interpreter version 1.000.1068
@@ -3714,7 +3771,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "454684e3a7a68cbca073945e50778447", 1187088},
{"resource.002", 0, "6dc668326cc22cb9e8bd8ca9e68d2a66", 1181249},
AD_LISTEND},
- Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::JA_JPN, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - Japanese PC-98 5.25" Floppy (also includes english language)
// SCI interpreter version 1.000.1068
@@ -3724,7 +3781,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.001", 0, "454684e3a7a68cbca073945e50778447", 1187088},
{"resource.002", 0, "6dc668326cc22cb9e8bd8ca9e68d2a66", 1181249},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformPC98, ADGF_ADDENGLISH, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English DOS CD (from the Space Quest Collection)
// Executable scanning reports "1.001.064", VERSION file reports "1.0"
@@ -3732,7 +3789,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "ed90a8e3ccc53af6633ff6ab58392bae", 7054},
{"resource.000", 0, "63247e3901ab8963d4eece73747832e0", 5157378},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO4(GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD, GUIO4(GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English Windows CD (from the Space Quest Collection)
// Executable scanning reports "1.001.064", VERSION file reports "1.0"
@@ -3742,7 +3799,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "ed90a8e3ccc53af6633ff6ab58392bae", 7054},
{"resource.000", 0, "63247e3901ab8963d4eece73747832e0", 5157378},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO5(GUIO_MIDIGM, GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_CD, GUIO5(GUIO_MIDIGM, GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English DOS CD patch 1.2 (unofficial - NRS) - THIS VERSION IS PIRATED/CRACKED AND REPACKAGED =DO NOT RE-ADD=
// In essence, this "patch" includes a mixture the CD and floppy versions (the whole game), without the speech file
@@ -3750,7 +3807,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "38287a646458a1dabded55d094407793", 7139},
{"resource.000", 0, "231fd8421e1f211e1bcf9d7b8b6408e7", 9525849},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_PIRATED, GUIO4(GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_PIRATED, GUIO4(GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - Spanish DOS CD (from jvprat, is still text only, not talkie, also includes english language)
// Executable scanning reports "1.SQ4.057", VERSION file reports "1.000"
@@ -3764,7 +3821,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "776fba81c110d1908776232cbe190e20", 1253752},
{"resource.005", 0, "55fae26c2a92f16ef72c1e216e827c0f", 1098328},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GAMEOPTION_SQ4_SILVER_CURSORS, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - Spanish DOS Floppy (from jvprat, also includes english language)
// Executable scanning reports "1.SQ4.056", VERSION file reports "1.000"
@@ -3776,7 +3833,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.002", 0, "74c62fa2146ff3b3b2ea2b3fb95b9af9", 1140801},
{"resource.003", 0, "42a307941edeb1a3be31daeb2e4be90b", 1088408},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 1.000 - German DOS Floppy (supplied by markcoolio in bug report #2723862, also includes english language)
// Executable scanning reports "1.SQ4.030"
@@ -3790,7 +3847,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "c06350184a490c10eb4585fff0aa3192", 1254368},
{"resource.005", 0, "b8d6efbd3235329bfe844c794097b2c9", 1098717},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_ADDENGLISH, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - English Macintosh
// Executable scanning reports "x.yyy.zzz"
@@ -3805,7 +3862,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.005", 0, "869d16cab6641c80b06f4dcee18f86bc", 1426228},
{"resource.006", 0, "91d23407bc0447a3722fbeb952d7edee", 1402451},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformMacintosh, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 4 - Russian DOS
// Executable scanning reports "1.000.753", VERSION file reports "1.994"
@@ -3818,7 +3875,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.004", 0, "2763fe4f0cb74df716ec8b0c464b0988", 1217428},
{"resource.005", 0, "d608713197c5ba1cd8c6ed46299c3069", 1057924},
AD_LISTEND},
- Common::RU_RUS, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::RU_RUS, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 - English DOS (from the Space Quest Collection)
// Executable scanning reports "1.001.068", VERSION file reports "1.04"
@@ -3827,7 +3884,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "4147edc5045e6d62998018b5614c58ec", 5496486},
{"resource.msg", 0, "bb8ad78793c26bdb3f77498b1d6515a9", 125988},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 - English DOS - THIS IS THE UNOFFICIAL BETA VERSION, WHICH IS OBVIOUSLY PIRATED AND CONTAINS MANY BUGS
// refer to http://www.akril15.com/sr/sq5alt/sq5alt.html =DO NOT RE-ADD=
@@ -3836,7 +3893,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "8bde0a9adb9a3e9aaa861826874c9834", 6473},
{"resource.000", 0, "f4a48705764544d7cc64a7bb22a610df", 6025184},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_PIRATED, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_PIRATED, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 v1.04 - German DOS (from Tobis87, updated information by markcool from bug reports #2723935 and #2724762)
// SCI interpreter version 1.001.068
@@ -3845,7 +3902,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "4147edc5045e6d62998018b5614c58ec", 5496486},
{"resource.msg", 0, "7c71cfc36153cfe07b450423a51f7e68", 146282},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 v1.04 - French DOS (from Hkz, Included in Space Quest Collector's Edition, with chapters I-V)
{"sq5", "", {
@@ -3853,7 +3910,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "4147edc5045e6d62998018b5614c58ec", 5496486},
{"resource.msg", 0, "877c42380320eb1db7dad83ccd261214", 140374},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 - Italian DOS Floppy (from glorifindel)
// SCI interpreter version 1.001.068 (just a guess)
@@ -3861,7 +3918,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "5040026519f37199f3616fb1d4704dff", 6047170},
{"resource.map", 0, "5b09168baa2f6e2e22787429b2d72f54", 6492},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 - Spanish DOS Floppy (from mirir, bug report #3090664)
{"sq5", "", {
@@ -3869,7 +3926,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "5714a899033bdebf2d61ad333c8c6637", 6492},
{"resource.msg", 0, "46deca7ef9cf057f7d442df98c1a2ae2", 134612},
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 5 - Russian DOS
// Executable scanning reports "1.001.068", VERSION file reports "1.994"
@@ -3878,7 +3935,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.000", 0, "6f9ed21e1001526b4137f6703ed476af", 6103778},
{"resource.msg", 0, "0a8931990cd2eac1691602391c68ab85", 147580},
AD_LISTEND},
- Common::RU_RUS, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::RU_RUS, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Space Quest 6 - English DOS/Win3.11 CD (from the Space Quest Collection)
@@ -3887,7 +3944,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "6dddfa3a8f3a3a513ec9dfdfae955005", 10528},
{"resource.000", 0, "c4259ab7355aead07773397b1052827d", 41150806},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 6 - English DOS/Win3.11 CD ver 1.11 (from FRG)
// SCI interpreter version 2.100.002 (just a guess)
@@ -3895,7 +3952,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "e0615d6e4e10e37ae42e6a2a95aaf145", 10528},
{"resource.000", 0, "c4259ab7355aead07773397b1052827d", 41150806},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 6 - French DOS/Win3.11 CD (from French magazine Joystick - September 1997)
// Executable scanning reports "2.100.002", VERSION file reports "1.0"
@@ -3903,7 +3960,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "3c831625931d5079b73ae8c275f52c95", 10534},
{"resource.000", 0, "4195ca940f759424f62b90e262cc1737", 40932397},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 6 - German DOS (from Tobis87, updated info from markcoolio in bug report #2723884)
// SCI interpreter version 2.100.002 (just a guess)
@@ -3911,7 +3968,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "664d797415484f85c90b1b45aedc7686", 10534},
{"resource.000", 0, "ba87ba91e5bdabb4169dd0df75777722", 40933685},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformDOS, ADGF_CD | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Space Quest 6 - English DOS/Win3.11 Interactive Demo (from FRG)
// SCI interpreter version 2.100.002 (just a guess)
@@ -3919,7 +3976,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "368f07b07433db3f819fa3fa0e5efee5", 2572},
{"resource.000", 0, "ab12724e078dea34b624e0d2a38dcd7c", 2272050},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO | ADGF_UNSTABLE, GUIO5(GUIO_NOSPEECH, GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI32
// The Island of Dr. Brain - English DOS CD (from jvprat)
@@ -3928,7 +3985,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "2388efef8430b041b0f3b00b9050e4a2", 3281},
{"resource.000", 0, "b3acd9b9dd7fe53c4ee133ac9a1acfab", 2103560},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO3(GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// The Island of Dr. Brain - English DOS (from Quietust)
// Executable scanning reports "1.001.053", VERSION file reports "1.1 2.3.93"
@@ -3936,7 +3993,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "3c07da06bdd1689f9d07af78fb94d0ec", 3101},
{"resource.000", 0, "ecc686e0034fb4d41de077ac7167b3cf", 1947866},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, 0, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// The Island of Dr. Brain - English DOS Non-Interactive Demo
// SCI interpreter version 1.001.053 (just a guess)
@@ -3944,7 +4001,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resource.map", 0, "a8e5ca8ed1996974afa59f4c45e06195", 986},
{"resource.000", 0, "b3acd9b9dd7fe53c4ee133ac9a1acfab", 586560},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformDOS, ADGF_DEMO, GUIO4(GUIO_NOSPEECH, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#ifdef ENABLE_SCI32
// Torin's Passage - English Windows Interactive Demo
@@ -3953,7 +4010,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "9a3e172cde9963d0a969f26469318cec", 3403},
{"ressci.000", 0, "db3e290481c35c3224e9602e71e4a1f1", 5073868},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Torin's Passage (Multilingual) - English Windows CD
// SCI interpreter version 2.100.002
@@ -3961,7 +4018,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "bb3b0b22ff08df54fbe2d06263409be6", 9799},
{"ressci.000", 0, "693a259d346c9360f4a0c11fdaae430a", 55973887},
AD_LISTEND},
- Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::EN_ANY, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Torin's Passage (Multilingual) - Spanish Windows CD (from jvprat)
// Executable scanning reports "2.100.002", VERSION file reports "1.0"
@@ -3970,7 +4027,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"ressci.000", 0, "693a259d346c9360f4a0c11fdaae430a", 55973887},
// TODO: depend on one of the patches?
AD_LISTEND},
- Common::ES_ESP, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::ES_ESP, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Torin's Passage (Multilingual) - French Windows CD
// SCI interpreter version 2.100.002
@@ -3978,7 +4035,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "bb3b0b22ff08df54fbe2d06263409be6", 9799},
{"ressci.000", 0, "693a259d346c9360f4a0c11fdaae430a", 55973887},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Torin's Passage (Multilingual) - German Windows CD
// SCI interpreter version 2.100.002
@@ -3986,7 +4043,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "bb3b0b22ff08df54fbe2d06263409be6", 9799},
{"ressci.000", 0, "693a259d346c9360f4a0c11fdaae430a", 55973887},
AD_LISTEND},
- Common::DE_DEU, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::DE_DEU, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Torin's Passage (Multilingual) - Italian Windows CD (from glorifindel)
// SCI interpreter version 2.100.002
@@ -3994,7 +4051,7 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "bb3b0b22ff08df54fbe2d06263409be6", 9799},
{"ressci.000", 0, "693a259d346c9360f4a0c11fdaae430a", 55973887},
AD_LISTEND},
- Common::IT_ITA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::IT_ITA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
// Torin's Passage - French Windows (from LePhilousophe)
// SCI interpreter version 2.100.002
@@ -4002,16 +4059,30 @@ static const struct ADGameDescription SciGameDescriptions[] = {
{"resmap.000", 0, "66ed46e3e56f487e688d52f05b33d0ba", 9787},
{"ressci.000", 0, "118f9bec04bfe17c4f87bbb5ddb43c18", 56126981},
AD_LISTEND},
- Common::FR_FRA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+ Common::FR_FRA, Common::kPlatformWindows, ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
+
+ // Torin's Passage - English Macintosh
+ {"torin", "", {
+ {"Data1", 0, "63887e33cc282c92dc1f916f54aea8eb", 700786},
+ {"Data2", 0, "da2f13be2819a7333fee372d38b8d1a2", 122485},
+ {"Data3", 0, "e9fda4f1714ddb443545ba8a2d58ef18", 7299126},
+ {"Data4", 0, "59b432ec35b24a216432a556e25087ef", 7209309},
+ {"Data5", 0, "189e809f24aee83c707dea03a543c7c4", 6615563},
+ {"Data6", 0, "b639487c83d1dae0e001e700f3631566", 7594881},
+ {"Data7", 0, "2afd9b5434102b89610916b904c3f73a", 7627374},
+ AD_LISTEND},
+ Common::EN_ANY, Common::kPlatformMacintosh, ADGF_MACRESFORK | ADGF_UNSTABLE, GUIO4(GUIO_NOASPECT, GAMEOPTION_PREFER_DIGITAL_SFX, GAMEOPTION_ORIGINAL_SAVELOAD, GAMEOPTION_FB01_MIDI) },
#endif // ENABLE_SCI32
// SCI Fanmade Games
+ FANMADE("120 Degrees Below Zero", "57f6135bd073802215c9b97f32d6aea3", 504, "03adf530a34557dfc20f848c9572f4d0", 320749),
FANMADE("Al Pond: Island Quest 2", "4cba6a5a4c8f66f21935ed78b0511a92", 870, "876587dc9a5ec569287a3dc4b29139d8", 613769),
FANMADE("Al Pond 2: Island Quest", "9625372e710d1a95d2027b48f9e325af", 1506, "a0f9aa65b9bf3d8703adff5a621f243c", 889843),
FANMADE("Al Pond 2: Island Quest (Updated)", "64be277cdcc6aafce7d9f26e88ad31a8", 1500, "571547228a212d63315f0c114cf48d54", 885241),
FANMADE("Another DG Game: I Want My C64 Back", "4a8ca7ca2abd18899ef856f47665e2e9", 588, "12ff558d20c72e42cc6adb408f34d6d8", 150513),
FANMADE_L("Another DG Game: I Want My C64 Back", "13dc1d9ebc57daf8895412eee5e39fea", 576, "e2ad60b3a280171429db5c85f158f84a", 141697, Common::FR_FRA),
FANMADE("Aquarius: An Aquatic Experience", "2e23bc3b82f22a454be202ea593fb478", 480, "01555c8de683d25405bda270aa1ff014", 272372),
+ FANMADE("Betrayed Alliance", "b1f43f496a83cb8503f290a838b26242", 4062, "e637255aae6191ee92b9e843ad276288", 2367197),
FANMADE("Bluntman and Chronic (Politically Correct Version)", "c3ef9fa6c7c5fb840078bf28d87c7f8b", 1362, "441636a9f6f86710844868fded868ee7", 596688),
FANMADE("Cascade Quest", "c94efc10d18c040b6e22a1dc6d3adfe1", 3468, "8ada33dfa945f81531e5508240b573de", 1432195),
FANMADE("Circus Quest", "35871f6b4e1df56af4113c0203a0b223", 630, "7d6f97d7935d8733f488d4cb74315e5b", 279627),
@@ -4019,26 +4090,40 @@ static const struct ADGameDescription SciGameDescriptions[] = {
FANMADE("Curt's Quest 1.1", "54084c29346683296e45ef32d7ae74f3", 1128, "c851182cdf6fc6a81b840f4d4875f1a0", 302000),
FANMADE("Demo Quest", "c89a0c9e0a4e4af0ecedb300a3b31dbf", 384, "a32f3495ba24764cba091119cc3f1e13", 160098),
FANMADE("Dr. Jummybummy's Space Adventure 2", "6ae6cb7de423f51736d9487b4ca0c6da", 810, "26e5b563f578e104d79689f36568b7cf", 394670),
+ FANMADE("Edy Oliver into the Cave of Whistling Skulls Demo", "eba0a0e86768ee3f14e78fecbc5af011", 2388, "4f6eab79a0f7980960eed101ab8122ad", 2601551),
+ FANMADE("Footsteps Sound Demo", "d9dabee6e1550b1fdb793f442f227738", 372, "06561df40dea49c6e84184e0ba6f19cb", 114212),
FANMADE_L("Grostesteing: Plus Mechant que Jamais", "ec9a97ccb134f69249f6ea8b16c13d8e", 1500, "b869f5f11bfe2ab5f67f4f0c618f2ce1", 464657, Common::FR_FRA), // FIXME: Accent
FANMADE("Humanoid Demo", "97d8331293a6d57e8bad58c1efc89a63", 624, "fb354b9abe64011b12159e45d724633f", 452320),
+ FANMADE("Island of Secrets Demo 0.3", "61279176c3e4530fec9b578877aecda7", 504, "7f4ed7a81b86bea22c62bc98e6d9ec39", 197790),
FANMADE("Jim’s Quest 1: The Phantom Thesis", "0af50be1d3f0cb77a09137709a76ef4f", 960, "9c042c136548b20d9183495668e03526", 496446),
+ FANMADE("King's Quest II SCI Pre-Alpha Version", "cdea1c081022e7697a1afffb1d2f9f6a", 2646, "fb2ce39002c3e05f3d83533638dea105", 2310356),
FANMADE("Knight's Quest Demo 1.0", "5e816edf993956752ed06fccfeeae6d9", 1260, "959321f88a22905fa1f8c6d897874744", 703836),
FANMADE("LockerGnome Quest", "3eeff9130206cad0c4e1551e2b9dd2c5", 420, "ae05ca90806fd90cc43f147c82d3547c", 158906),
+ FANMADE("LockerGnome Quest Redux", "55b0081dbdd77a07807c76cec3606970", 492, "75c9c5e8a475a7b5f1a6cb18edad67f2", 168069),
FANMADE("New Year's Mystery", "e4dcab1b1d3cb4a2c070a07a9c9589e0", 708, "e00ca5e44fd4e98d8174b467b31b0f21", 295425),
FANMADE("New Year's Mystery (Updated)", "efd1beb5120293725065c95959144f81", 714, "b3bd3c2372ed6efa28adb12403c4c31a", 305027),
FANMADE("Ocean Battle", "c2304a0568e0eb84f8e9a0915f01170a", 408, "46c520c1ac9b63528854d0f58c7e1b74", 142234),
FANMADE("Osama", "db8f1710453cfbecf4214b2946970043", 390, "7afd75d4620dedf97a84ae8f0a7523cf", 123827),
FANMADE("Quest for the Cheat", "a359d4cf27f98264b42b55c017671214", 882, "8a943029f73c4bc85d454b7f473455ba", 455209),
+ FANMADE("Robust Parse Demo 1.2", "c956d40b6eb42292ec328c510acb11d8", 540, "26f092bab5ec4490737d8463fd3ebbd5", 229044),
FANMADE("SCI Capture the Flag", "4cd679a51d93b8b27c6b38d81be24b8b", 432, "98ae1f6ed7b4c21f88addbf643dd1d2f", 147878),
FANMADE("SCI Companion Template", "ad54d4f504086cd597aa2348d0aa3b09", 354, "6798b7b601ce8154c1d1bc0f0edcdd18", 113061),
+ FANMADE("SCI Logging Demo", "615c30c1445ea9349847e8868312a674", 558, "2df6858526177612ef9473e7af5b31c6", 171012),
+#if 0
+ // Disabled as this requires network access to the Google Translate API, which is not available as OSystem has no network API.
+ FANMADE("SCI Narration Demo", "731f4f2b726a13c153380af08da16591", 360, "38c80558fb942e8568f011d4a1a4af59", 109789),
+#endif
FANMADE("SCI Programming April 2010 Competition Template", "36e5c4011dd7c92e1ae4c6fede7d698d", 456, "20c87fbb7f73e2a3eb2c5dfab4d76b5a", 142221),
FANMADE("SCI Studio Template 3.0", "ca0dc8d586e0a8670b7621cde090b532", 354, "58a48ee692a86c0575e6bd0b00a92b9a", 113097),
FANMADE("SCI Quest", "9067e1f1e54436d2dbfce855524bc84a", 552, "ffa7d355cd9223f245289108a696bcd2", 149634),
FANMADE("SCI-Man", "3ab85bd39a86c11f85781764f9db09bb", 468, "bb8f9992f504a242bf0860e3588e150b", 131810),
- FANMADE("The Black Cauldron", "5e1ff2833c7f33ebcfa456ba836e2067", 2592, "2f8e6264d2db91bb54982ab8aa18b3b4", 1881839),
+ FANMADE("Text Views Demo", "ad0485a96470566517f184ff5dd049f8", 372, "727b946b37588ed334737732c55007c4", 115788),
+ FANMADE("The Black Cauldron Demo", "5e1ff2833c7f33ebcfa456ba836e2067", 2592, "2f8e6264d2db91bb54982ab8aa18b3b4", 1881839),
+ FANMADE("The Black Cauldron Final", "cbb4705f0cd73760996e5b27aae54f6a", 2484, "fc3bcaa7783b91bb78faefa345c6b3d9", 1677293),
FANMADE("The Farm Nightmare", "fb6cbfddaa7c055e2c3d8cf4c683a7db", 906, "50655e8b8925f717e698e08f006f40be", 338303),
FANMADE("The Gem Scenario", "ef5f61f4d2c6d31122d3e2baf89ad976", 642, "2f16be390dd90c3d7ca1c8a594ac0bfa", 244794),
FANMADE("The Legend of the Lost Jewel", "ba1bca315e3818c5626eda51bcfbcccf", 636, "9b0736d69924af0cff32a0f78db96855", 300398),
+ FANMADE("Winter Wonderland", "c1ffaf8327462effd4ad21eeed9eea59", 504, "5d48666dc62f90d852a1d0de6e69195f", 305076),
// FIXME: The vga demo does not have a resource.000/001 file.
//FANMADE_V("SCI VGA Demo", "00b1abd87bad356b90fcdfcb6132c26f", 8, "", 0, 0),
diff --git a/engines/sci/engine/features.cpp b/engines/sci/engine/features.cpp
index c26c787fbd..31e7ca4931 100644
--- a/engines/sci/engine/features.cpp
+++ b/engines/sci/engine/features.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/features.h b/engines/sci/engine/features.h
index f6bb0b5759..a4d715fee0 100644
--- a/engines/sci/engine/features.h
+++ b/engines/sci/engine/features.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/file.cpp b/engines/sci/engine/file.cpp
index 3dc042389e..2ba7d15ac0 100644
--- a/engines/sci/engine/file.cpp
+++ b/engines/sci/engine/file.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/file.h b/engines/sci/engine/file.h
index 1c8e302d15..052eb735e9 100644
--- a/engines/sci/engine/file.h
+++ b/engines/sci/engine/file.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/gc.cpp b/engines/sci/engine/gc.cpp
index 9a30ff3e17..70c8c52bf0 100644
--- a/engines/sci/engine/gc.cpp
+++ b/engines/sci/engine/gc.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/gc.h b/engines/sci/engine/gc.h
index 9e02bbd0bd..fbaad14b00 100644
--- a/engines/sci/engine/gc.h
+++ b/engines/sci/engine/gc.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kernel.cpp b/engines/sci/engine/kernel.cpp
index 8d55790ad2..2b16bb3d99 100644
--- a/engines/sci/engine/kernel.cpp
+++ b/engines/sci/engine/kernel.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -35,8 +35,6 @@ namespace Sci {
Kernel::Kernel(ResourceManager *resMan, SegManager *segMan)
: _resMan(resMan), _segMan(segMan), _invalid("<invalid>") {
- loadSelectorNames();
- mapSelectors(); // Map a few special selectors for later use
}
Kernel::~Kernel() {
@@ -53,6 +51,11 @@ Kernel::~Kernel() {
}
}
+void Kernel::init() {
+ loadSelectorNames();
+ mapSelectors(); // Map a few special selectors for later use
+}
+
uint Kernel::getSelectorNamesSize() const {
return _selectorNames.size();
}
@@ -104,6 +107,11 @@ int Kernel::findSelector(const char *selectorName) const {
return -1;
}
+// used by Script patcher to figure out, if it's okay to initialize signature/patch-table
+bool Kernel::selectorNamesAvailable() {
+ return !_selectorNames.empty();
+}
+
void Kernel::loadSelectorNames() {
Resource *r = _resMan->findResource(ResourceId(kResourceTypeVocab, VOCAB_RESOURCE_SELECTORS), 0);
bool oldScriptHeader = (getSciVersion() == SCI_VERSION_0_EARLY);
diff --git a/engines/sci/engine/kernel.h b/engines/sci/engine/kernel.h
index 8a021073fc..dddf845222 100644
--- a/engines/sci/engine/kernel.h
+++ b/engines/sci/engine/kernel.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -145,6 +145,8 @@ public:
*/
Kernel(ResourceManager *resMan, SegManager *segMan);
~Kernel();
+
+ void init();
uint getSelectorNamesSize() const;
const Common::String &getSelectorName(uint selector);
@@ -159,6 +161,8 @@ public:
* @return The appropriate selector ID, or -1 on error
*/
int findSelector(const char *selectorName) const;
+
+ bool selectorNamesAvailable();
// Script dissection/dumping functions
void dissectScript(int scriptNumber, Vocabulary *vocab);
diff --git a/engines/sci/engine/kernel_tables.h b/engines/sci/engine/kernel_tables.h
index d7858180f1..fc46d16b8d 100644
--- a/engines/sci/engine/kernel_tables.h
+++ b/engines/sci/engine/kernel_tables.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -331,7 +331,7 @@ static SciKernelMapEntry s_kernelMap[] = {
{ MAP_CALL(Clone), SIG_EVERYWHERE, "o", NULL, NULL },
{ MAP_CALL(CoordPri), SIG_EVERYWHERE, "i(i)", NULL, NULL },
{ MAP_CALL(CosDiv), SIG_EVERYWHERE, "ii", NULL, NULL },
- { MAP_CALL(DeleteKey), SIG_EVERYWHERE, "l.", NULL, NULL },
+ { MAP_CALL(DeleteKey), SIG_EVERYWHERE, "l.", NULL, kDeleteKey_workarounds },
{ MAP_CALL(DeviceInfo), SIG_EVERYWHERE, "i(r)(r)(i)", NULL, kDeviceInfo_workarounds }, // subop
{ MAP_CALL(Display), SIG_EVERYWHERE, "[ir]([ir!]*)", NULL, kDisplay_workarounds },
// ^ we allow invalid references here, because kDisplay gets called with those in e.g. pq3 during intro
@@ -421,7 +421,7 @@ static SciKernelMapEntry s_kernelMap[] = {
{ MAP_CALL(PrevNode), SIG_EVERYWHERE, "n", NULL, NULL },
{ MAP_CALL(PriCoord), SIG_EVERYWHERE, "i", NULL, NULL },
{ MAP_CALL(Random), SIG_EVERYWHERE, "i(i)(i)", NULL, NULL },
- { MAP_CALL(ReadNumber), SIG_EVERYWHERE, "r", NULL, NULL },
+ { MAP_CALL(ReadNumber), SIG_EVERYWHERE, "r", NULL, kReadNumber_workarounds },
{ MAP_CALL(RemapColors), SIG_SCI11, SIGFOR_ALL, "i(i)(i)(i)(i)", NULL, NULL },
#ifdef ENABLE_SCI32
{ "RemapColors", kRemapColors32, SIG_SCI32, SIGFOR_ALL, "i(i)(i)(i)(i)(i)", NULL, NULL },
@@ -431,7 +431,7 @@ static SciKernelMapEntry s_kernelMap[] = {
{ MAP_CALL(RestartGame), SIG_EVERYWHERE, "", NULL, NULL },
{ MAP_CALL(RestoreGame), SIG_EVERYWHERE, "[r0]i[r0]", NULL, NULL },
{ MAP_CALL(Said), SIG_EVERYWHERE, "[r0]", NULL, NULL },
- { MAP_CALL(SaveGame), SIG_EVERYWHERE, "[r0]i[r0](r)", NULL, NULL },
+ { MAP_CALL(SaveGame), SIG_EVERYWHERE, "[r0]i[r0](r0)", NULL, NULL },
{ MAP_CALL(ScriptID), SIG_EVERYWHERE, "[io](i)", NULL, NULL },
{ MAP_CALL(SetCursor), SIG_SCI21, SIGFOR_ALL, "i(i)([io])(i*)", NULL, NULL },
// TODO: SCI2.1 may supply an object optionally (mother goose sci21 right on startup) - find out why
@@ -454,7 +454,7 @@ static SciKernelMapEntry s_kernelMap[] = {
{ MAP_CALL(StrAt), SIG_EVERYWHERE, "ri(i)", NULL, kStrAt_workarounds },
{ MAP_CALL(StrCat), SIG_EVERYWHERE, "rr", NULL, NULL },
{ MAP_CALL(StrCmp), SIG_EVERYWHERE, "rr(i)", NULL, NULL },
- { MAP_CALL(StrCpy), SIG_EVERYWHERE, "r[r0](i)", NULL, NULL },
+ { MAP_CALL(StrCpy), SIG_EVERYWHERE, "r[r0](i)", NULL, kStrCpy_workarounds },
{ MAP_CALL(StrEnd), SIG_EVERYWHERE, "r", NULL, NULL },
{ MAP_CALL(StrLen), SIG_EVERYWHERE, "[r0]", NULL, kStrLen_workarounds },
{ MAP_CALL(StrSplit), SIG_EVERYWHERE, "rr[r0]", NULL, NULL },
diff --git a/engines/sci/engine/kevent.cpp b/engines/sci/engine/kevent.cpp
index 11ef18c0c2..cb81da2279 100644
--- a/engines/sci/engine/kevent.cpp
+++ b/engines/sci/engine/kevent.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -126,7 +126,7 @@ reg_t kGetEvent(EngineState *s, int argc, reg_t *argv) {
// track left buttton clicks, if requested
if (curEvent.type == SCI_EVENT_MOUSE_PRESS && curEvent.data == 1 && g_debug_track_mouse_clicks) {
- g_sci->getSciDebugger()->DebugPrintf("Mouse clicked at %d, %d\n",
+ g_sci->getSciDebugger()->debugPrintf("Mouse clicked at %d, %d\n",
mousePos.x, mousePos.y);
}
@@ -163,20 +163,20 @@ reg_t kGetEvent(EngineState *s, int argc, reg_t *argv) {
// A SCI event occurred, and we have been asked to stop, so open the debug console
Console *con = g_sci->getSciDebugger();
- con->DebugPrintf("SCI event occurred: ");
+ con->debugPrintf("SCI event occurred: ");
switch (curEvent.type) {
case SCI_EVENT_QUIT:
- con->DebugPrintf("quit event\n");
+ con->debugPrintf("quit event\n");
break;
case SCI_EVENT_KEYBOARD:
- con->DebugPrintf("keyboard event\n");
+ con->debugPrintf("keyboard event\n");
break;
case SCI_EVENT_MOUSE_RELEASE:
case SCI_EVENT_MOUSE_PRESS:
- con->DebugPrintf("mouse click event\n");
+ con->debugPrintf("mouse click event\n");
break;
default:
- con->DebugPrintf("unknown or no event (event type %d)\n", curEvent.type);
+ con->debugPrintf("unknown or no event (event type %d)\n", curEvent.type);
}
con->attach();
diff --git a/engines/sci/engine/kfile.cpp b/engines/sci/engine/kfile.cpp
index c6635f2f27..61fb717567 100644
--- a/engines/sci/engine/kfile.cpp
+++ b/engines/sci/engine/kfile.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -37,6 +37,7 @@
#include "sci/engine/state.h"
#include "sci/engine/kernel.h"
#include "sci/engine/savegame.h"
+#include "sci/sound/audio.h"
#include "sci/console.h"
namespace Sci {
@@ -494,6 +495,21 @@ reg_t kFileIOWriteString(EngineState *s, int argc, reg_t *argv) {
Common::String str = s->_segMan->getString(argv[1]);
debugC(kDebugLevelFile, "kFileIO(writeString): %d", handle);
+ // Handle sciAudio calls in fanmade games here. sciAudio is an
+ // external .NET library for playing MP3 files in fanmade games.
+ // It runs in the background, and obtains sound commands from the
+ // currently running game via text files (called "conductor files").
+ // We skip creating these files, and instead handle the calls
+ // directly. Since the sciAudio calls are only creating text files,
+ // this is probably the most straightforward place to handle them.
+ if (handle == 0xFFFF && str.hasPrefix("(sciAudio")) {
+ Common::List<ExecStack>::const_iterator iter = s->_executionStack.reverse_begin();
+ iter--; // sciAudio
+ iter--; // sciAudio child
+ g_sci->_audio->handleFanmadeSciAudio(iter->sendp, s->_segMan);
+ return NULL_REG;
+ }
+
#ifdef ENABLE_SCI32
if (handle == VIRTUALFILE_HANDLE) {
s->_virtualIndexFile->write(str.c_str(), str.size());
@@ -718,7 +734,7 @@ reg_t kSave(EngineState *s, int argc, reg_t *argv) {
reg_t kSaveGame(EngineState *s, int argc, reg_t *argv) {
Common::String game_id;
- int16 virtualId = argv[1].toSint16();
+ int16 virtualId = argv[1].toSint16();
int16 savegameId = -1;
Common::String game_description;
Common::String version;
@@ -743,11 +759,11 @@ reg_t kSaveGame(EngineState *s, int argc, reg_t *argv) {
savegameId = dialog->runModalWithCurrentTarget();
game_description = dialog->getResultString();
if (game_description.empty()) {
- // create our own description for the saved game, the user didnt enter it
+ // create our own description for the saved game, the user didn't enter it
game_description = dialog->createDefaultSaveDescription(savegameId);
}
delete dialog;
- g_sci->_soundCmd->pauseAll(false); // unpause music ( we can't have it paused during save)
+ g_sci->_soundCmd->pauseAll(false); // unpause music (we can't have it paused during save)
if (savegameId < 0)
return NULL_REG;
@@ -849,8 +865,6 @@ reg_t kRestoreGame(EngineState *s, int argc, reg_t *argv) {
}
// don't adjust ID of the saved game, it's already correct
} else {
- if (argv[2].isNull())
- error("kRestoreGame: called with parameter 2 being NULL");
if (g_sci->getGameId() == GID_JONES) {
// Jones has one save slot only
savegameId = 0;
@@ -879,16 +893,28 @@ reg_t kRestoreGame(EngineState *s, int argc, reg_t *argv) {
in = saveFileMan->openForLoading(filename);
if (in) {
// found a savegame file
-
gamestate_restore(s, in);
delete in;
- if (g_sci->getGameId() == GID_MOTHERGOOSE256) {
+ switch (g_sci->getGameId()) {
+ case GID_MOTHERGOOSE:
+ // WORKAROUND: Mother Goose SCI0
+ // Script 200 / rm200::newRoom will set global C5h directly right after creating a child to the
+ // current number of children plus 1.
+ // We can't trust that global, that's why we set the actual savedgame id right here directly after
+ // restoring a saved game.
+ // If we didn't, the game would always save to a new slot
+ s->variables[VAR_GLOBAL][0xC5].setOffset(SAVEGAMEID_OFFICIALRANGE_START + savegameId);
+ break;
+ case GID_MOTHERGOOSE256:
// WORKAROUND: Mother Goose SCI1/SCI1.1 does some weird things for
// saving a previously restored game.
// We set the current savedgame-id directly and remove the script
// code concerning this via script patch.
s->variables[VAR_GLOBAL][0xB3].setOffset(SAVEGAMEID_OFFICIALRANGE_START + savegameId);
+ break;
+ default:
+ break;
}
} else {
s->r_acc = TRUE_REG;
diff --git a/engines/sci/engine/kgraphics.cpp b/engines/sci/engine/kgraphics.cpp
index e4b3028bcd..c2089bcd4d 100644
--- a/engines/sci/engine/kgraphics.cpp
+++ b/engines/sci/engine/kgraphics.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -185,7 +185,8 @@ static reg_t kSetCursorSci11(EngineState *s, int argc, reg_t *argv) {
hotspot = new Common::Point(argv[3].toSint16(), argv[4].toSint16());
// Fallthrough
case 3:
- if (g_sci->getPlatform() == Common::kPlatformMacintosh) {
+ if (g_sci->getPlatform() == Common::kPlatformMacintosh && g_sci->getGameId() != GID_TORIN) {
+ // Torin Mac seems to be the only game that uses view cursors
delete hotspot; // Mac cursors have their own hotspot, so ignore any we get here
g_sci->_gfxCursor->kernelSetMacCursor(argv[0].toUint16(), argv[1].toUint16(), argv[2].toUint16());
} else {
diff --git a/engines/sci/engine/kgraphics32.cpp b/engines/sci/engine/kgraphics32.cpp
index cd735d1233..8953f45266 100644
--- a/engines/sci/engine/kgraphics32.cpp
+++ b/engines/sci/engine/kgraphics32.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -142,7 +142,15 @@ reg_t kIsOnMe(EngineState *s, int argc, reg_t *argv) {
uint16 y = argv[1].toUint16();
reg_t targetObject = argv[2];
uint16 illegalBits = argv[3].getOffset();
- Common::Rect nsRect = g_sci->_gfxCompare->getNSRect(targetObject, true);
+ Common::Rect nsRect = g_sci->_gfxCompare->getNSRect(targetObject);
+
+ uint16 itemX = readSelectorValue(s->_segMan, targetObject, SELECTOR(x));
+ uint16 itemY = readSelectorValue(s->_segMan, targetObject, SELECTOR(y));
+ // If top and left are negative, we need to adjust coordinates by the item's x and y
+ if (nsRect.left < 0)
+ nsRect.translate(itemX, 0);
+ if (nsRect.top < 0)
+ nsRect.translate(0, itemY);
// we assume that x, y are local coordinates
diff --git a/engines/sci/engine/klists.cpp b/engines/sci/engine/klists.cpp
index 7e6c112b9f..66590da23f 100644
--- a/engines/sci/engine/klists.cpp
+++ b/engines/sci/engine/klists.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kmath.cpp b/engines/sci/engine/kmath.cpp
index b2aaa01b45..15bc24e0e3 100644
--- a/engines/sci/engine/kmath.cpp
+++ b/engines/sci/engine/kmath.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kmenu.cpp b/engines/sci/engine/kmenu.cpp
index 05ba7005d7..8dca7f74df 100644
--- a/engines/sci/engine/kmenu.cpp
+++ b/engines/sci/engine/kmenu.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kmisc.cpp b/engines/sci/engine/kmisc.cpp
index 8b7fc4ffec..448e641b63 100644
--- a/engines/sci/engine/kmisc.cpp
+++ b/engines/sci/engine/kmisc.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -244,7 +244,8 @@ reg_t kGetTime(EngineState *s, int argc, reg_t *argv) {
debugC(kDebugLevelTime, "GetTime(24h) returns %d", retval);
break;
case KGETTIME_DATE :
- retval = loc_time.tm_mday | ((loc_time.tm_mon + 1) << 5) | (((loc_time.tm_year + 1900) & 0x7f) << 9);
+ // Year since 1980 (0 = 1980, 1 = 1981, etc.)
+ retval = loc_time.tm_mday | ((loc_time.tm_mon + 1) << 5) | (((loc_time.tm_year - 80) & 0x7f) << 9);
debugC(kDebugLevelTime, "GetTime(date) returns %d", retval);
break;
default:
diff --git a/engines/sci/engine/kmovement.cpp b/engines/sci/engine/kmovement.cpp
index 649a1428a0..51d49eea9f 100644
--- a/engines/sci/engine/kmovement.cpp
+++ b/engines/sci/engine/kmovement.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kparse.cpp b/engines/sci/engine/kparse.cpp
index 5e861daaa4..aa89b963cc 100644
--- a/engines/sci/engine/kparse.cpp
+++ b/engines/sci/engine/kparse.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kpathing.cpp b/engines/sci/engine/kpathing.cpp
index 3c223bebbe..67d814b86f 100644
--- a/engines/sci/engine/kpathing.cpp
+++ b/engines/sci/engine/kpathing.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -1921,7 +1921,7 @@ static int intersectDir(const Vertex *v1, const Vertex *v2) {
// Direction of edge in degrees from pos. x-axis, between -180 and 180
static int edgeDir(const Vertex *v) {
Common::Point p = v->_next->v - v->v;
- int deg = (int)Common::rad2deg(atan2((double)p.y, (double)p.x));
+ int deg = (int)Common::rad2deg((float)atan2((double)p.y, (double)p.x));
if (deg < -180) deg += 360;
if (deg > 180) deg -= 360;
return deg;
diff --git a/engines/sci/engine/kscripts.cpp b/engines/sci/engine/kscripts.cpp
index 2c115be500..5c271780dd 100644
--- a/engines/sci/engine/kscripts.cpp
+++ b/engines/sci/engine/kscripts.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/ksound.cpp b/engines/sci/engine/ksound.cpp
index 2879b7f45d..6a1708d21a 100644
--- a/engines/sci/engine/ksound.cpp
+++ b/engines/sci/engine/ksound.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kstring.cpp b/engines/sci/engine/kstring.cpp
index d72b1d1772..56dad583e4 100644
--- a/engines/sci/engine/kstring.cpp
+++ b/engines/sci/engine/kstring.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/kvideo.cpp b/engines/sci/engine/kvideo.cpp
index 3964ccc1f8..319469cb08 100644
--- a/engines/sci/engine/kvideo.cpp
+++ b/engines/sci/engine/kvideo.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/message.cpp b/engines/sci/engine/message.cpp
index 8c5741f8b0..640175b20a 100644
--- a/engines/sci/engine/message.cpp
+++ b/engines/sci/engine/message.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/message.h b/engines/sci/engine/message.h
index 5bead82efe..ff76534d2d 100644
--- a/engines/sci/engine/message.h
+++ b/engines/sci/engine/message.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/object.cpp b/engines/sci/engine/object.cpp
index b28026b71f..eeff45163d 100644
--- a/engines/sci/engine/object.cpp
+++ b/engines/sci/engine/object.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -175,6 +175,7 @@ bool Object::initBaseObject(SegManager *segMan, reg_t addr, bool doInitSuperClas
_variables.resize(baseObj->getVarCount());
// Copy base from species class, as we need its selector IDs
_baseObj = baseObj->_baseObj;
+ assert(_baseObj);
if (doInitSuperClass)
initSuperClass(segMan, addr);
diff --git a/engines/sci/engine/object.h b/engines/sci/engine/object.h
index 1ea9ae449a..00fe7c6875 100644
--- a/engines/sci/engine/object.h
+++ b/engines/sci/engine/object.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/savegame.cpp b/engines/sci/engine/savegame.cpp
index c60b50a964..cdcdcc41e5 100644
--- a/engines/sci/engine/savegame.cpp
+++ b/engines/sci/engine/savegame.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -219,25 +219,30 @@ void SegManager::saveLoadWithSerializer(Common::Serializer &s) {
syncArray<Class>(s, _classTable);
- // Now that all scripts are loaded, init their objects
- for (uint i = 0; i < _heap.size(); i++) {
- if (!_heap[i] || _heap[i]->getType() != SEG_TYPE_SCRIPT)
- continue;
+ // Now that all scripts are loaded, init their objects.
+ // Just like in Script::initializeObjectsSci0, we do two passes
+ // in case an object is loaded before its base.
+ int passes = getSciVersion() < SCI_VERSION_1_1 ? 2 : 1;
+ for (int pass = 1; pass <= passes; ++pass) {
+ for (uint i = 0; i < _heap.size(); i++) {
+ if (!_heap[i] || _heap[i]->getType() != SEG_TYPE_SCRIPT)
+ continue;
- Script *scr = (Script *)_heap[i];
- scr->syncLocalsBlock(this);
+ Script *scr = (Script *)_heap[i];
+ scr->syncLocalsBlock(this);
- ObjMap objects = scr->getObjectMap();
- for (ObjMap::iterator it = objects.begin(); it != objects.end(); ++it) {
- reg_t addr = it->_value.getPos();
- Object *obj = scr->scriptObjInit(addr, false);
+ ObjMap objects = scr->getObjectMap();
+ for (ObjMap::iterator it = objects.begin(); it != objects.end(); ++it) {
+ reg_t addr = it->_value.getPos();
+ Object *obj = scr->scriptObjInit(addr, false);
- if (getSciVersion() < SCI_VERSION_1_1) {
- if (!obj->initBaseObject(this, addr, false)) {
- // TODO/FIXME: This should not be happening at all. It might indicate a possible issue
- // with the garbage collector. It happens for example in LSL5 (German, perhaps English too).
- warning("Failed to locate base object for object at %04X:%04X; skipping", PRINT_REG(addr));
- objects.erase(addr.toUint16());
+ if (pass == 2) {
+ if (!obj->initBaseObject(this, addr, false)) {
+ // TODO/FIXME: This should not be happening at all. It might indicate a possible issue
+ // with the garbage collector. It happens for example in LSL5 (German, perhaps English too).
+ warning("Failed to locate base object for object at %04X:%04X; skipping", PRINT_REG(addr));
+ objects.erase(addr.toUint16());
+ }
}
}
}
@@ -465,7 +470,7 @@ void Script::syncStringHeap(Common::Serializer &s) {
break;
} while (1);
- } else if (getSciVersion() >= SCI_VERSION_1_1 && getSciVersion() <= SCI_VERSION_2_1){
+ } else if (getSciVersion() >= SCI_VERSION_1_1 && getSciVersion() <= SCI_VERSION_2_1){
// Strings in SCI1.1 come after the object instances
byte *buf = _heapStart + 4 + READ_SCI11ENDIAN_UINT16(_heapStart + 2) * 2;
@@ -484,7 +489,7 @@ void Script::saveLoadWithSerializer(Common::Serializer &s) {
s.syncAsSint32LE(_nr);
if (s.isLoading())
- load(_nr, g_sci->getResMan());
+ load(_nr, g_sci->getResMan(), g_sci->getScriptPatcher());
s.skip(4, VER(14), VER(22)); // OBSOLETE: Used to be _bufSize
s.skip(4, VER(14), VER(22)); // OBSOLETE: Used to be _scriptSize
s.skip(4, VER(14), VER(22)); // OBSOLETE: Used to be _heapSize
@@ -855,16 +860,13 @@ void gamestate_restore(EngineState *s, Common::SeekableReadStream *fh) {
return;
}
- if ((meta.version < MINIMUM_SAVEGAME_VERSION) ||
- (meta.version > CURRENT_SAVEGAME_VERSION)) {
- /*
- if (meta.version < MINIMUM_SAVEGAME_VERSION)
- warning("Old savegame version detected, unable to load it");
- else
- warning("Savegame version is %d, maximum supported is %0d", meta.version, CURRENT_SAVEGAME_VERSION);
- */
-
- showScummVMDialog("The format of this saved game is obsolete, unable to load it");
+ if ((meta.version < MINIMUM_SAVEGAME_VERSION) || (meta.version > CURRENT_SAVEGAME_VERSION)) {
+ if (meta.version < MINIMUM_SAVEGAME_VERSION) {
+ showScummVMDialog("The format of this saved game is obsolete, unable to load it");
+ } else {
+ Common::String msg = Common::String::format("Savegame version is %d, maximum supported is %0d", meta.version, CURRENT_SAVEGAME_VERSION);
+ showScummVMDialog(msg);
+ }
s->r_acc = TRUE_REG; // signal failure
return;
@@ -873,8 +875,6 @@ void gamestate_restore(EngineState *s, Common::SeekableReadStream *fh) {
if (meta.gameObjectOffset > 0 && meta.script0Size > 0) {
Resource *script0 = g_sci->getResMan()->findResource(ResourceId(kResourceTypeScript, 0), false);
if (script0->size != meta.script0Size || g_sci->getGameObject().getOffset() != meta.gameObjectOffset) {
- //warning("This saved game was created with a different version of the game, unable to load it");
-
showScummVMDialog("This saved game was created with a different version of the game, unable to load it");
s->r_acc = TRUE_REG; // signal failure
diff --git a/engines/sci/engine/savegame.h b/engines/sci/engine/savegame.h
index f1f02f89f2..8f2835654b 100644
--- a/engines/sci/engine/savegame.h
+++ b/engines/sci/engine/savegame.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/script.cpp b/engines/sci/engine/script.cpp
index 36d2841b07..2fe1aba975 100644
--- a/engines/sci/engine/script.cpp
+++ b/engines/sci/engine/script.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -32,7 +32,8 @@
namespace Sci {
-Script::Script() : SegmentObj(SEG_TYPE_SCRIPT), _buf(NULL) {
+Script::Script()
+ : SegmentObj(SEG_TYPE_SCRIPT), _buf(NULL) {
freeScript();
}
@@ -65,7 +66,7 @@ void Script::freeScript() {
_objects.clear();
}
-void Script::load(int script_nr, ResourceManager *resMan) {
+void Script::load(int script_nr, ResourceManager *resMan, ScriptPatcher *scriptPatcher) {
freeScript();
Resource *script = resMan->findResource(ResourceId(kResourceTypeScript, script_nr), 0);
@@ -136,7 +137,7 @@ void Script::load(int script_nr, ResourceManager *resMan) {
memcpy(_buf, script->data, script->size);
// Check scripts for matching signatures and patch those, if found
- matchSignatureAndPatch(_nr, _buf, script->size);
+ scriptPatcher->processScript(_nr, _buf, script->size);
if (getSciVersion() >= SCI_VERSION_1_1 && getSciVersion() <= SCI_VERSION_2_1) {
Resource *heap = resMan->findResource(ResourceId(kResourceTypeHeap, _nr), 0);
diff --git a/engines/sci/engine/script.h b/engines/sci/engine/script.h
index 0b499203c2..46d6ace917 100644
--- a/engines/sci/engine/script.h
+++ b/engines/sci/engine/script.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -25,12 +25,13 @@
#include "common/str.h"
#include "sci/engine/segment.h"
+#include "sci/engine/script_patches.h"
namespace Sci {
struct EngineState;
class ResourceManager;
-struct SciScriptSignature;
+struct SciScriptPatcherEntry;
enum ScriptObjectTypes {
SCI_OBJ_TERMINATOR,
@@ -96,11 +97,7 @@ public:
~Script();
void freeScript();
- void load(int script_nr, ResourceManager *resMan);
-
- void matchSignatureAndPatch(uint16 scriptNr, byte *scriptData, const uint32 scriptSize);
- int32 findSignature(const SciScriptSignature *signature, const byte *scriptData, const uint32 scriptSize);
- void applyPatch(const uint16 *patch, byte *scriptData, const uint32 scriptSize, int32 signatureOffset);
+ void load(int script_nr, ResourceManager *resMan, ScriptPatcher *scriptPatcher);
virtual bool isValidOffset(uint16 offset) const;
virtual SegmentRef dereference(reg_t pointer);
diff --git a/engines/sci/engine/script_patches.cpp b/engines/sci/engine/script_patches.cpp
index d2c3356d54..8bbbd713a6 100644
--- a/engines/sci/engine/script_patches.cpp
+++ b/engines/sci/engine/script_patches.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -21,43 +21,111 @@
*/
#include "sci/sci.h"
+#include "sci/engine/kernel.h"
#include "sci/engine/script.h"
#include "sci/engine/state.h"
#include "sci/engine/features.h"
+#include "sci/engine/script_patches.h"
#include "common/util.h"
namespace Sci {
-#define PATCH_END 0xFFFF
-#define PATCH_COMMANDMASK 0xF000
-#define PATCH_VALUEMASK 0x0FFF
-#define PATCH_ADDTOOFFSET 0xE000
-#define PATCH_GETORIGINALBYTE 0xD000
-#define PATCH_ADJUSTWORD 0xC000
-#define PATCH_ADJUSTWORD_NEG 0xB000
-#define PATCH_MAGICDWORD(a, b, c, d) CONSTANT_LE_32(a | (b << 8) | (c << 16) | (d << 24))
-#define PATCH_VALUELIMIT 4096
-
-struct SciScriptSignature {
- uint16 scriptNr;
- const char *description;
- int16 applyCount;
- uint32 magicDWord;
- int magicOffset;
- const byte *data;
- const uint16 *patch;
+// IMPORTANT:
+// every patch entry needs the following:
+// - script number (pretty obvious)
+//
+// - apply count
+// specifies the number of times a patch is supposed to get applied.
+// Most of the time, it should be 1.
+//
+// - magicDWORD + magicOffset
+// please ALWAYS put 0 for those two. Both will get filled out at runtime by the patcher.
+//
+// - signature data (is used to identify certain script code, that needs patching)
+// every signature needs to contain SIG_MAGICDWORD once.
+// The following 4 bytes after SIG_MAGICDWORD - which don't have to be fixed, you may for example
+// use SIG_SELECTOR16, will get used to quickly search for a partly match before verifying that
+// the whole signature actually matches. If it's not included, the script patcher will error() out
+// right when loading up the game.
+// If selector-IDs are included, please use SIG_SELECTOR16 + SIG_SELECTOR8 [1]. Simply
+// specify the selector that way, so that the patcher will search for the specific
+// selector instead of looking for a hardcoded value. Selectors may not be the same
+// between game versions.
+// For UINT16s either use SIG_UINT16 or SIG_SELECTOR16.
+// Macintosh versions of SCI games are using BE ordering instead of LE since SCI1.1 for UINT16s in scripts
+// By using those 2 commands, it's possible to make patches work for PC and Mac versions of the same game.
+// You may also skip bytes by using the SIG_ADDTOOFFSET command
+// Every signature data needs to get terminated using SIGNATURE_END
+//
+// - patch data (is used for actually patching scripts)
+// When a match is found, the patch data will get applied.
+// Patch data is similar to signature data. Just use PATCH_SELECTOR16 + PATCH_SELECTOR8 [1]
+// for patching in selectors.
+// There are also patch specific commands.
+// Those are PATCH_GETORIGINALBYTE, which fetches a byte from the original script
+// and PATCH_GETORIGINALBYTEADJUST, which does the same but gets a second value
+// from the uint16 array and uses that value to adjust the original byte.
+// Every patch data needs to get terminated using PATCH_END
+//
+// - and please always add a comment about why the patch was done and what's causing issues.
+// If possible make sure, that the patch works on localized (or just different) game versions
+// as well in case those need patching too.
+//
+// [1] - selectors need to get specified in selectorTable[] and ScriptPatcherSelectors-enum
+// before they can get used using the SIG_SELECTORx and PATCH_SELECTORx commands.
+// You have to use the exact same order in both the table and the enum, otherwise
+// it won't work.
+
+static const char *const selectorNameTable[] = {
+ "cycles", // system selector
+ "seconds", // system selector
+ "init", // system selector
+ "dispose", // system selector
+ "new", // system selector
+ "curEvent", // system selector
+ "disable", // system selector
+ "doit", // system selector
+ "show", // system selector
+ "x", // system selector
+ "cel", // system selector
+ "setMotion", // system selector
+ "overlay", // system selector
+ "deskSarg", // Gabriel Knight
+ "localize", // Freddy Pharkas
+ "put", // Police Quest 1 VGA
+ "solvePuzzle", // Quest For Glory 3
+ "timesShownID", // Space Quest 1 VGA
+ "startText", // King's Quest 6 CD / Laura Bow 2 CD for audio+text support
+ "startAudio", // King's Quest 6 CD / Laura Bow 2 CD for audio+text support
+ "modNum", // King's Quest 6 CD / Laura Bow 2 CD for audio+text support
+ NULL
+};
+
+enum ScriptPatcherSelectors {
+ SELECTOR_cycles = 0,
+ SELECTOR_seconds,
+ SELECTOR_init,
+ SELECTOR_dispose,
+ SELECTOR_new,
+ SELECTOR_curEvent,
+ SELECTOR_disable,
+ SELECTOR_doit,
+ SELECTOR_show,
+ SELECTOR_x,
+ SELECTOR_cel,
+ SELECTOR_setMotion,
+ SELECTOR_overlay,
+ SELECTOR_deskSarg,
+ SELECTOR_localize,
+ SELECTOR_put,
+ SELECTOR_solvePuzzle,
+ SELECTOR_timesShownID,
+ SELECTOR_startText,
+ SELECTOR_startAudio,
+ SELECTOR_modNum
};
-#define SCI_SIGNATUREENTRY_TERMINATOR { 0, NULL, 0, 0, 0, NULL, NULL }
-
-// signatures are built like this:
-// - first a counter of the bytes that follow
-// - then the actual bytes that need to get matched
-// - then another counter of bytes (0 for EOS)
-// - if not EOS, an adjust offset and the actual bytes
-// - rinse and repeat
-
// ===========================================================================
// Conquests of Camelot
// At the bazaar in Jerusalem, it's possible to see a girl taking a shower.
@@ -77,36 +145,33 @@ struct SciScriptSignature {
//
// We fix the script by patching in a jump to the proper code inside fawaz::doit.
// Responsible method: fawaz::handleEvent
-// Fixes bug #3614969
-const byte camelotSignaturePeepingTom[] = {
- 5,
- 0x72, 0x7e, 0x07, // lofsa fawaz <-- start of proper initializion code
- 0xa1, 0xb9, // sag b9h
- +255, 0,
- +255, 0,
- +61, 19, // skip 571 bytes
- 0x39, 0x7a, // pushi 7a <-- initialization code when walking automatically
- 0x78, // push1
- 0x7a, // push2
- 0x38, 0xa9, 0x00, // pushi 00a9 - script 169
- 0x78, // push1
- 0x43, 0x02, 0x04, // call kScriptID
- 0x36, // push
- 0x81, 0x00, // lag 00
- 0x4a, 0x06, // send 06
- 0x32, 0x20, 0x05, // jmp [end of fawaz::handleEvent]
- 0
-};
-
-const uint16 camelotPatchPeepingTom[] = {
- PATCH_ADDTOOFFSET | +576,
- 0x32, 0xbd, 0xfd, // jmp to fawaz::doit / properly init peepingTom code
+// Fixes bug: #6402
+static const uint16 camelotSignaturePeepingTom[] = {
+ 0x72, SIG_MAGICDWORD, SIG_UINT16(0x077e), // lofsa fawaz <-- start of proper initializion code
+ 0xa1, 0xb9, // sag b9h
+ SIG_ADDTOOFFSET(+571), // skip 571 bytes
+ 0x39, 0x7a, // pushi 7a <-- initialization code when walking automatically
+ 0x78, // push1
+ 0x7a, // push2
+ 0x38, SIG_UINT16(0x00a9), // + 0xa9, 0x00, // pushi 00a9 - script 169
+ 0x78, // push1
+ 0x43, 0x02, 0x04, // call kScriptID
+ 0x36, // push
+ 0x81, 0x00, // lag 00
+ 0x4a, 0x06, // send 06
+ 0x32, SIG_UINT16(0x0520), // jmp [end of fawaz::handleEvent]
+ SIG_END
+};
+
+static const uint16 camelotPatchPeepingTom[] = {
+ PATCH_ADDTOOFFSET(+576),
+ 0x32, PATCH_UINT16(0xfdbd), // jmp to fawaz::doit / properly init peepingTom code
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature camelotSignatures[] = {
- { 62, "fix peepingTom Sierra bug", 1, PATCH_MAGICDWORD(0x7e, 0x07, 0xa1, 0xb9), -1, camelotSignaturePeepingTom, camelotPatchPeepingTom },
+// script, description, signature patch
+static const SciScriptPatcherEntry camelotSignatures[] = {
+ { true, 62, "fix peepingTom Sierra bug", 1, camelotSignaturePeepingTom, camelotPatchPeepingTom },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -115,64 +180,67 @@ const SciScriptSignature camelotSignatures[] = {
// boundaries of room 660. Normally a textbox is supposed to get on screen
// but the call is wrong, so not only do we get an error message the script
// is also hanging because the cue won't get sent out
-// This also happens in sierra sci - refer to bug #3038387
-const byte ecoquest1SignatureStayAndHelp[] = {
- 40,
- 0x3f, 0x01, // link 01
- 0x87, 0x01, // lap param[1]
- 0x65, 0x14, // aTop state
- 0x36, // push
- 0x3c, // dup
- 0x35, 0x00, // ldi 00
- 0x1a, // eq?
- 0x31, 0x1c, // bnt [next state]
- 0x76, // push0
- 0x45, 0x01, 0x00, // callb export1 from script 0 (switching control off)
- 0x38, 0x22, 0x01, // pushi 0122
- 0x78, // push1
- 0x76, // push0
- 0x81, 0x00, // lag global[0]
- 0x4a, 0x06, // send 06 - call ego::setMotion(0)
- 0x39, 0x6e, // pushi 6e (selector init)
- 0x39, 0x04, // pushi 04
- 0x76, // push0
- 0x76, // push0
- 0x39, 0x17, // pushi 17
- 0x7c, // pushSelf
- 0x51, 0x82, // class EcoNarrator
- 0x4a, 0x0c, // send 0c - call EcoNarrator::init(0, 0, 23, self) (BADLY BROKEN!)
- 0x33, // jmp [end]
- 0
+// This also happens in sierra sci
+// Applies to at least: PC-CD
+// Responsible method: stayAndHelp::changeState
+// Fixes bug: #5107
+static const uint16 ecoquest1SignatureStayAndHelp[] = {
+ 0x3f, 0x01, // link 01
+ 0x87, 0x01, // lap param[1]
+ 0x65, 0x14, // aTop state
+ 0x36, // push
+ 0x3c, // dup
+ 0x35, 0x00, // ldi 00
+ 0x1a, // eq?
+ 0x31, 0x1c, // bnt [next state]
+ 0x76, // push0
+ 0x45, 0x01, 0x00, // callb export1 from script 0 (switching control off)
+ SIG_MAGICDWORD,
+ 0x38, SIG_UINT16(0x0122), // pushi 0122
+ 0x78, // push1
+ 0x76, // push0
+ 0x81, 0x00, // lag global[0]
+ 0x4a, 0x06, // send 06 - call ego::setMotion(0)
+ 0x39, SIG_SELECTOR8(init), // pushi "init"
+ 0x39, 0x04, // pushi 04
+ 0x76, // push0
+ 0x76, // push0
+ 0x39, 0x17, // pushi 17
+ 0x7c, // pushSelf
+ 0x51, 0x82, // class EcoNarrator
+ 0x4a, 0x0c, // send 0c - call EcoNarrator::init(0, 0, 23, self) (BADLY BROKEN!)
+ 0x33, // jmp [end]
+ SIG_END
+};
+
+static const uint16 ecoquest1PatchStayAndHelp[] = {
+ 0x87, 0x01, // lap param[1]
+ 0x65, 0x14, // aTop state
+ 0x36, // push
+ 0x2f, 0x22, // bt [next state] (this optimization saves 6 bytes)
+ 0x39, 0x00, // pushi 0 (wasting 1 byte here)
+ 0x45, 0x01, 0x00, // callb export1 from script 0 (switching control off)
+ 0x38, PATCH_UINT16(0x0122), // pushi 0122
+ 0x78, // push1
+ 0x76, // push0
+ 0x81, 0x00, // lag global[0]
+ 0x4a, 0x06, // send 06 - call ego::setMotion(0)
+ 0x39, PATCH_SELECTOR8(init), // pushi "init"
+ 0x39, 0x06, // pushi 06
+ 0x39, 0x02, // pushi 02 (additional 2 bytes)
+ 0x76, // push0
+ 0x76, // push0
+ 0x39, 0x17, // pushi 17
+ 0x7c, // pushSelf
+ 0x38, PATCH_UINT16(0x0280), // pushi 280 (additional 3 bytes)
+ 0x51, 0x82, // class EcoNarrator
+ 0x4a, 0x10, // send 10 - call EcoNarrator::init(2, 0, 0, 23, self, 640)
+ PATCH_END
};
-const uint16 ecoquest1PatchStayAndHelp[] = {
- 0x87, 0x01, // lap param[1]
- 0x65, 0x14, // aTop state
- 0x36, // push
- 0x2f, 0x22, // bt [next state] (this optimization saves 6 bytes)
- 0x39, 0x00, // pushi 0 (wasting 1 byte here)
- 0x45, 0x01, 0x00, // callb export1 from script 0 (switching control off)
- 0x38, 0x22, 0x01, // pushi 0122
- 0x78, // push1
- 0x76, // push0
- 0x81, 0x00, // lag global[0]
- 0x4a, 0x06, // send 06 - call ego::setMotion(0)
- 0x39, 0x6e, // pushi 6e (selector init)
- 0x39, 0x06, // pushi 06
- 0x39, 0x02, // pushi 02 (additional 2 bytes)
- 0x76, // push0
- 0x76, // push0
- 0x39, 0x17, // pushi 17
- 0x7c, // pushSelf
- 0x38, 0x80, 0x02, // pushi 280 (additional 3 bytes)
- 0x51, 0x82, // class EcoNarrator
- 0x4a, 0x10, // send 10 - call EcoNarrator::init(2, 0, 0, 23, self, 640)
- PATCH_END
-};
-
-// script, description, magic DWORD, adjust
-const SciScriptSignature ecoquest1Signatures[] = {
- { 660, "CD: bad messagebox and freeze", 1, PATCH_MAGICDWORD(0x38, 0x22, 0x01, 0x78), -17, ecoquest1SignatureStayAndHelp, ecoquest1PatchStayAndHelp },
+// script, description, signature patch
+static const SciScriptPatcherEntry ecoquest1Signatures[] = {
+ { true, 660, "CD: bad messagebox and freeze", 1, ecoquest1SignatureStayAndHelp, ecoquest1PatchStayAndHelp },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -181,122 +249,124 @@ const SciScriptSignature ecoquest1Signatures[] = {
// ecorder. This is done by reusing temp-space, that was filled on state 1.
// this worked in sierra sci just by accident. In our sci, the temp space
// is resetted every time, which means the previous text isn't available
-// anymore. We have to patch the code because of that - bug #3035386
-const byte ecoquest2SignatureEcorder[] = {
- 35,
- 0x31, 0x22, // bnt [next state]
- 0x39, 0x0a, // pushi 0a
- 0x5b, 0x04, 0x1e, // lea temp[1e]
- 0x36, // push
- 0x39, 0x64, // pushi 64
- 0x39, 0x7d, // pushi 7d
- 0x39, 0x32, // pushi 32
- 0x39, 0x66, // pushi 66
- 0x39, 0x17, // pushi 17
- 0x39, 0x69, // pushi 69
- 0x38, 0x31, 0x26, // pushi 2631
- 0x39, 0x6a, // pushi 6a
- 0x39, 0x64, // pushi 64
- 0x43, 0x1b, 0x14, // call kDisplay
- 0x35, 0x0a, // ldi 0a
- 0x65, 0x20, // aTop ticks
- 0x33, // jmp [end]
- +1, 5, // [skip 1 byte]
- 0x3c, // dup
- 0x35, 0x03, // ldi 03
- 0x1a, // eq?
- 0x31, // bnt [end]
- 0
-};
-
-const uint16 ecoquest2PatchEcorder[] = {
- 0x2f, 0x02, // bt [to pushi 07]
- 0x3a, // toss
- 0x48, // ret
- 0x38, 0x07, 0x00, // pushi 07 (parameter count) (waste 1 byte)
- 0x39, 0x0b, // push (FillBoxAny)
- 0x39, 0x1d, // pushi 29d
- 0x39, 0x73, // pushi 115d
- 0x39, 0x5e, // pushi 94d
- 0x38, 0xd7, 0x00, // pushi 215d
- 0x78, // push1 (visual screen)
- 0x38, 0x17, 0x00, // pushi 17 (color) (waste 1 byte)
- 0x43, 0x6c, 0x0e, // call kGraph
- 0x38, 0x05, 0x00, // pushi 05 (parameter count) (waste 1 byte)
- 0x39, 0x0c, // pushi 12d (UpdateBox)
- 0x39, 0x1d, // pushi 29d
- 0x39, 0x73, // pushi 115d
- 0x39, 0x5e, // pushi 94d
- 0x38, 0xd7, 0x00, // pushi 215d
- 0x43, 0x6c, 0x0a, // call kGraph
+// anymore. We have to patch the code because of that.
+// Fixes bug: #4993
+static const uint16 ecoquest2SignatureEcorder[] = {
+ 0x31, 0x22, // bnt [next state]
+ 0x39, 0x0a, // pushi 0a
+ 0x5b, 0x04, 0x1e, // lea temp[1e]
+ 0x36, // push
+ SIG_MAGICDWORD,
+ 0x39, 0x64, // pushi 64
+ 0x39, 0x7d, // pushi 7d
+ 0x39, 0x32, // pushi 32
+ 0x39, 0x66, // pushi 66
+ 0x39, 0x17, // pushi 17
+ 0x39, 0x69, // pushi 69
+ 0x38, PATCH_UINT16(0x2631), // pushi 2631
+ 0x39, 0x6a, // pushi 6a
+ 0x39, 0x64, // pushi 64
+ 0x43, 0x1b, 0x14, // call kDisplay
+ 0x35, 0x0a, // ldi 0a
+ 0x65, 0x20, // aTop ticks
+ 0x33, // jmp [end]
+ SIG_ADDTOOFFSET(+1), // [skip 1 byte]
+ 0x3c, // dup
+ 0x35, 0x03, // ldi 03
+ 0x1a, // eq?
+ 0x31, // bnt [end]
+ SIG_END
+};
+
+static const uint16 ecoquest2PatchEcorder[] = {
+ 0x2f, 0x02, // bt [to pushi 07]
+ 0x3a, // toss
+ 0x48, // ret
+ 0x38, PATCH_UINT16(0x0007), // pushi 07 (parameter count) (waste 1 byte)
+ 0x39, 0x0b, // push (FillBoxAny)
+ 0x39, 0x1d, // pushi 29d
+ 0x39, 0x73, // pushi 115d
+ 0x39, 0x5e, // pushi 94d
+ 0x38, PATCH_UINT16(0x00d7), // pushi 215d
+ 0x78, // push1 (visual screen)
+ 0x38, PATCH_UINT16(0x0017), // pushi 17 (color) (waste 1 byte)
+ 0x43, 0x6c, 0x0e, // call kGraph
+ 0x38, PATCH_UINT16(0x0005), // pushi 05 (parameter count) (waste 1 byte)
+ 0x39, 0x0c, // pushi 12d (UpdateBox)
+ 0x39, 0x1d, // pushi 29d
+ 0x39, 0x73, // pushi 115d
+ 0x39, 0x5e, // pushi 94d
+ 0x38, PATCH_UINT16(0x00d7), // pushi 215d
+ 0x43, 0x6c, 0x0a, // call kGraph
PATCH_END
};
// ===========================================================================
-// Same patch as above for the ecorder introduction. Fixes bug #3092115.
+// Same patch as above for the ecorder introduction.
// Two workarounds are needed for this patch in workarounds.cpp (when calling
// kGraphFillBoxAny and kGraphUpdateBox), as there isn't enough space to patch
// the function otherwise.
-const byte ecoquest2SignatureEcorderTutorial[] = {
- 36,
- 0x30, 0x23, 0x00, // bnt [next state]
- 0x39, 0x0a, // pushi 0a
- 0x5b, 0x04, 0x1f, // lea temp[1f]
- 0x36, // push
- 0x39, 0x64, // pushi 64
- 0x39, 0x7d, // pushi 7d
- 0x39, 0x32, // pushi 32
- 0x39, 0x66, // pushi 66
- 0x39, 0x17, // pushi 17
- 0x39, 0x69, // pushi 69
- 0x38, 0x31, 0x26, // pushi 2631
- 0x39, 0x6a, // pushi 6a
- 0x39, 0x64, // pushi 64
- 0x43, 0x1b, 0x14, // call kDisplay
- 0x35, 0x1e, // ldi 1e
- 0x65, 0x20, // aTop ticks
- 0x32, // jmp [end]
+// Fixes bug: #6467
+static const uint16 ecoquest2SignatureEcorderTutorial[] = {
+ 0x30, SIG_UINT16(0x0023), // bnt [next state]
+ 0x39, 0x0a, // pushi 0a
+ 0x5b, 0x04, 0x1f, // lea temp[1f]
+ 0x36, // push
+ SIG_MAGICDWORD,
+ 0x39, 0x64, // pushi 64
+ 0x39, 0x7d, // pushi 7d
+ 0x39, 0x32, // pushi 32
+ 0x39, 0x66, // pushi 66
+ 0x39, 0x17, // pushi 17
+ 0x39, 0x69, // pushi 69
+ 0x38, SIG_UINT16(0x2631), // pushi 2631
+ 0x39, 0x6a, // pushi 6a
+ 0x39, 0x64, // pushi 64
+ 0x43, 0x1b, 0x14, // call kDisplay
+ 0x35, 0x1e, // ldi 1e
+ 0x65, 0x20, // aTop ticks
+ 0x32, // jmp [end]
// 2 extra bytes, jmp offset
- 0
+ SIG_END
};
-const uint16 ecoquest2PatchEcorderTutorial[] = {
- 0x31, 0x23, // bnt [next state] (save 1 byte)
+static const uint16 ecoquest2PatchEcorderTutorial[] = {
+ 0x31, 0x23, // bnt [next state] (save 1 byte)
// The parameter count below should be 7, but we're out of bytes
// to patch! A workaround has been added because of this
- 0x78, // push1 (parameter count)
- //0x39, 0x07, // pushi 07 (parameter count)
- 0x39, 0x0b, // push (FillBoxAny)
- 0x39, 0x1d, // pushi 29d
- 0x39, 0x73, // pushi 115d
- 0x39, 0x5e, // pushi 94d
- 0x38, 0xd7, 0x00, // pushi 215d
- 0x78, // push1 (visual screen)
- 0x39, 0x17, // pushi 17 (color)
- 0x43, 0x6c, 0x0e, // call kGraph
+ 0x78, // push1 (parameter count)
+ //0x39, 0x07, // pushi 07 (parameter count)
+ 0x39, 0x0b, // push (FillBoxAny)
+ 0x39, 0x1d, // pushi 29d
+ 0x39, 0x73, // pushi 115d
+ 0x39, 0x5e, // pushi 94d
+ 0x38, PATCH_UINT16(0x00d7), // pushi 215d
+ 0x78, // push1 (visual screen)
+ 0x39, 0x17, // pushi 17 (color)
+ 0x43, 0x6c, 0x0e, // call kGraph
// The parameter count below should be 5, but we're out of bytes
// to patch! A workaround has been added because of this
- 0x78, // push1 (parameter count)
- //0x39, 0x05, // pushi 05 (parameter count)
- 0x39, 0x0c, // pushi 12d (UpdateBox)
- 0x39, 0x1d, // pushi 29d
- 0x39, 0x73, // pushi 115d
- 0x39, 0x5e, // pushi 94d
- 0x38, 0xd7, 0x00, // pushi 215d
- 0x43, 0x6c, 0x0a, // call kGraph
+ 0x78, // push1 (parameter count)
+ //0x39, 0x05, // pushi 05 (parameter count)
+ 0x39, 0x0c, // pushi 12d (UpdateBox)
+ 0x39, 0x1d, // pushi 29d
+ 0x39, 0x73, // pushi 115d
+ 0x39, 0x5e, // pushi 94d
+ 0x38, PATCH_UINT16(0x00d7), // pushi 215d
+ 0x43, 0x6c, 0x0a, // call kGraph
// We are out of bytes to patch at this point,
// so we skip 494 (0x1EE) bytes to reuse this code:
// ldi 1e
// aTop 20
// jmp 030e (jump to end)
- 0x32, 0xee, 0x01, // skip 494 (0x1EE) bytes
+ 0x32, PATCH_UINT16(0x01ee), // skip 494 (0x1EE) bytes
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature ecoquest2Signatures[] = {
- { 50, "initial text not removed on ecorder", 1, PATCH_MAGICDWORD(0x39, 0x64, 0x39, 0x7d), -8, ecoquest2SignatureEcorder, ecoquest2PatchEcorder },
- { 333, "initial text not removed on ecorder tutorial",1, PATCH_MAGICDWORD(0x39, 0x64, 0x39, 0x7d), -9, ecoquest2SignatureEcorderTutorial, ecoquest2PatchEcorderTutorial },
+// script, description, signature patch
+static const SciScriptPatcherEntry ecoquest2Signatures[] = {
+ { true, 50, "initial text not removed on ecorder", 1, ecoquest2SignatureEcorder, ecoquest2PatchEcorder },
+ { true, 333, "initial text not removed on ecorder tutorial", 1, ecoquest2SignatureEcorderTutorial, ecoquest2PatchEcorderTutorial },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -305,27 +375,27 @@ const SciScriptSignature ecoquest2Signatures[] = {
// wrong address when an incorrect word is typed, therefore leading to an
// infinite loop. This script bug was not apparent in SSCI, probably because
// event handling was slightly different there, so it was never discovered.
-// Fixes bug #3038870.
-const byte fanmadeSignatureInfiniteLoop[] = {
- 13,
- 0x38, 0x4c, 0x00, // pushi 004c
- 0x39, 0x00, // pushi 00
- 0x87, 0x01, // lap 01
- 0x4b, 0x04, // send 04
- 0x18, // not
- 0x30, 0x2f, 0x00, // bnt 002f [06a5] --> jmp ffbc [0664] --> BUG! infinite loop
- 0
-};
-
-const uint16 fanmadePatchInfiniteLoop[] = {
- PATCH_ADDTOOFFSET | +10,
- 0x30, 0x32, 0x00, // bnt 0032 [06a8] --> pushi 004c
+// Fixes bug: #5120
+static const uint16 fanmadeSignatureInfiniteLoop[] = {
+ 0x38, SIG_UINT16(0x004c), // pushi 004c
+ 0x39, 0x00, // pushi 00
+ 0x87, 0x01, // lap 01
+ 0x4b, 0x04, // send 04
+ SIG_MAGICDWORD,
+ 0x18, // not
+ 0x30, SIG_UINT16(0x002f), // bnt 002f [06a5] --> jmp ffbc [0664] --> BUG! infinite loop
+ SIG_END
+};
+
+static const uint16 fanmadePatchInfiniteLoop[] = {
+ PATCH_ADDTOOFFSET(+10),
+ 0x30, SIG_UINT16(0x0032), // bnt 0032 [06a8] --> pushi 004c
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature fanmadeSignatures[] = {
- { 999, "infinite loop on typo", 1, PATCH_MAGICDWORD(0x18, 0x30, 0x2f, 0x00), -9, fanmadeSignatureInfiniteLoop, fanmadePatchInfiniteLoop },
+// script, description, signature patch
+static const SciScriptPatcherEntry fanmadeSignatures[] = {
+ { true, 999, "infinite loop on typo", 1, fanmadeSignatureInfiniteLoop, fanmadePatchInfiniteLoop },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -337,21 +407,23 @@ const SciScriptSignature fanmadeSignatures[] = {
// was already playing in the sound driver. In our case we would also stop
// the sample from playing, so we patch it out
// The "score" code is already buggy and sets volume to 0 when playing
-const byte freddypharkasSignatureScoreDisposal[] = {
- 10,
- 0x67, 0x32, // pTos 32 (selector theAudCount)
- 0x78, // push1
- 0x39, 0x0d, // pushi 0d
- 0x43, 0x75, 0x02, // call kDoAudio
- 0x1c, // ne?
- 0x31, // bnt (-> to skip disposal)
- 0
-};
-
-const uint16 freddypharkasPatchScoreDisposal[] = {
- 0x34, 0x00, 0x00, // ldi 0000
- 0x34, 0x00, 0x00, // ldi 0000
- 0x34, 0x00, 0x00, // ldi 0000
+// Applies to at least: English PC-CD
+// Responsible method: unknown
+static const uint16 freddypharkasSignatureScoreDisposal[] = {
+ 0x67, 0x32, // pTos 32 (selector theAudCount)
+ 0x78, // push1
+ SIG_MAGICDWORD,
+ 0x39, 0x0d, // pushi 0d
+ 0x43, 0x75, 0x02, // call kDoAudio
+ 0x1c, // ne?
+ 0x31, // bnt (-> to skip disposal)
+ SIG_END
+};
+
+static const uint16 freddypharkasPatchScoreDisposal[] = {
+ 0x34, PATCH_UINT16(0x0000), // ldi 0000
+ 0x34, PATCH_UINT16(0x0000), // ldi 0000
+ 0x34, PATCH_UINT16(0x0000), // ldi 0000
PATCH_END
};
@@ -361,24 +433,26 @@ const uint16 freddypharkasPatchScoreDisposal[] = {
// in IconBar::disable doing endless loops even in sierra sci, because there
// is no enabled icon left. We remove disabling of icon 8 (which is help),
// this fixes the issue.
-const byte freddypharkasSignatureCanisterHang[] = {
- 12,
- 0x38, 0xf1, 0x00, // pushi f1 (selector disable)
- 0x7a, // push2
- 0x39, 0x07, // pushi 07
- 0x39, 0x08, // pushi 08
- 0x81, 0x45, // lag 45
- 0x4a, 0x08, // send 08 - call IconBar::disable(7, 8)
- 0
-};
-
-const uint16 freddypharkasPatchCanisterHang[] = {
- PATCH_ADDTOOFFSET | +3,
- 0x78, // push1
- PATCH_ADDTOOFFSET | +2,
- 0x33, 0x00, // ldi 00 (waste 2 bytes)
- PATCH_ADDTOOFFSET | +3,
- 0x06, // send 06 - call IconBar::disable(7)
+// Applies to at least: English PC-CD
+// Responsible method: rm235::init and sEnterFrom500::changeState
+static const uint16 freddypharkasSignatureCanisterHang[] = {
+ 0x38, SIG_SELECTOR16(disable), // pushi disable
+ 0x7a, // push2
+ SIG_MAGICDWORD,
+ 0x39, 0x07, // pushi 07
+ 0x39, 0x08, // pushi 08
+ 0x81, 0x45, // lag 45
+ 0x4a, 0x08, // send 08 - call IconBar::disable(7, 8)
+ SIG_END
+};
+
+static const uint16 freddypharkasPatchCanisterHang[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x78, // push1
+ PATCH_ADDTOOFFSET(+2),
+ 0x33, 0x00, // ldi 00 (waste 2 bytes)
+ PATCH_ADDTOOFFSET(+3),
+ 0x06, // send 06 - call IconBar::disable(7)
PATCH_END
};
@@ -390,135 +464,132 @@ const uint16 freddypharkasPatchCanisterHang[] = {
// ego, sometimes clicks also won't get registered. Strangely it's not nearly
// as bad as in our sci, but these differences may be caused by timing.
// We just reuse the active event, thus removing the duplicate kGetEvent call.
-const byte freddypharkasSignatureLadderEvent[] = {
- 21,
- 0x39, 0x6d, // pushi 6d (selector new)
- 0x76, // push0
- 0x38, 0xf5, 0x00, // pushi f5 (selector curEvent)
- 0x76, // push0
- 0x81, 0x50, // lag global[50]
- 0x4a, 0x04, // send 04 - read User::curEvent
- 0x4a, 0x04, // send 04 - call curEvent::new
- 0xa5, 0x00, // sat temp[0]
- 0x38, 0x94, 0x00, // pushi 94 (selector localize)
- 0x76, // push0
- 0x4a, 0x04, // send 04 - call curEvent::localize
- 0
-};
-
-const uint16 freddypharkasPatchLadderEvent[] = {
- 0x34, 0x00, 0x00, // ldi 0000 (waste 3 bytes, overwrites first 2 pushes)
- PATCH_ADDTOOFFSET | +8,
- 0xa5, 0x00, // sat temp[0] (waste 2 bytes, overwrites 2nd send)
- PATCH_ADDTOOFFSET | +2,
- 0x34, 0x00, 0x00, // ldi 0000
- 0x34, 0x00, 0x00, // ldi 0000 (waste 6 bytes, overwrites last 3 opcodes)
+// Applies to at least: English PC-CD, German Floppy, English Mac
+// Responsible method: lowerLadder::doit and highLadder::doit
+static const uint16 freddypharkasSignatureLadderEvent[] = {
+ 0x39, SIG_MAGICDWORD,
+ SIG_SELECTOR8(new), // pushi new
+ 0x76, // push0
+ 0x38, SIG_SELECTOR16(curEvent), // pushi curEvent
+ 0x76, // push0
+ 0x81, 0x50, // lag global[50]
+ 0x4a, 0x04, // send 04 - read User::curEvent
+ 0x4a, 0x04, // send 04 - call curEvent::new
+ 0xa5, 0x00, // sat temp[0]
+ 0x38, SIG_SELECTOR16(localize),
+ 0x76, // push0
+ 0x4a, 0x04, // send 04 - call curEvent::localize
+ SIG_END
+};
+
+static const uint16 freddypharkasPatchLadderEvent[] = {
+ 0x34, 0x00, 0x00, // ldi 0000 (waste 3 bytes, overwrites first 2 pushes)
+ PATCH_ADDTOOFFSET(+8),
+ 0xa5, 0x00, // sat temp[0] (waste 2 bytes, overwrites 2nd send)
+ PATCH_ADDTOOFFSET(+2),
+ 0x34, 0x00, 0x00, // ldi 0000
+ 0x34, 0x00, 0x00, // ldi 0000 (waste 6 bytes, overwrites last 3 opcodes)
PATCH_END
};
// In the Macintosh version of Freddy Pharkas, kRespondsTo is broken for
// property selectors. They hacked the script to work around the issue,
// so we revert the script back to using the values of the DOS script.
-const byte freddypharkasSignatureMacInventory[] = {
- 10,
- 0x39, 0x23, // pushi 23
- 0x39, 0x74, // pushi 74
- 0x78, // push1
- 0x38, 0x01, 0x74, // pushi 0174
- 0x85, 0x15, // lat 15
- 0
+// Applies to at least: English Mac
+// Responsible method: unknown
+static const uint16 freddypharkasSignatureMacInventory[] = {
+ SIG_MAGICDWORD,
+ 0x39, 0x23, // pushi 23
+ 0x39, 0x74, // pushi 74
+ 0x78, // push1
+ 0x38, SIG_UINT16(0x0174), // pushi 0174 (on mac it's actually 0x01, 0x74)
+ 0x85, 0x15, // lat 15
+ SIG_END
+};
+
+static const uint16 freddypharkasPatchMacInventory[] = {
+ 0x39, 0x02, // pushi 02 (now matches the DOS version)
+ PATCH_ADDTOOFFSET(+23),
+ 0x39, 0x04, // pushi 04 (now matches the DOS version)
+ PATCH_END
};
-const uint16 freddypharkasPatchMacInventory[] = {
- 0x39, 0x02, // pushi 02 (now matches the DOS version)
- 0x39, 0x74, // pushi 74
- 0x78, // push1
- 0x38, 0x01, 0x74, // pushi 0174
- 0x85, 0x15, // lat 15
- 0x4a, 0x06, // send 06
- 0x31, 0x08, // bnt 08
- 0x38, 0x01, 0x74, // pushi 0174
- 0x76, // push0
- 0x85, 0x15, // lat 15
- 0x4a, 0x04, // send 04
- 0x02, // add
- 0xa5, 0x12, // sat 12
- 0x39, 0x04, // pushi 04 (now matches the DOS version)
- PATCH_END
-};
-
-// script, description, magic DWORD, adjust
-const SciScriptSignature freddypharkasSignatures[] = {
- { 0, "CD: score early disposal", 1, PATCH_MAGICDWORD(0x39, 0x0d, 0x43, 0x75), -3, freddypharkasSignatureScoreDisposal, freddypharkasPatchScoreDisposal },
- { 15, "Mac: broken inventory", 1, PATCH_MAGICDWORD(0x39, 0x23, 0x39, 0x74), 0, freddypharkasSignatureMacInventory, freddypharkasPatchMacInventory },
- { 235, "CD: canister pickup hang", 3, PATCH_MAGICDWORD(0x39, 0x07, 0x39, 0x08), -4, freddypharkasSignatureCanisterHang, freddypharkasPatchCanisterHang },
- { 320, "ladder event issue", 2, PATCH_MAGICDWORD(0x6d, 0x76, 0x38, 0xf5), -1, freddypharkasSignatureLadderEvent, freddypharkasPatchLadderEvent },
+// script, description, signature patch
+static const SciScriptPatcherEntry freddypharkasSignatures[] = {
+ { true, 0, "CD: score early disposal", 1, freddypharkasSignatureScoreDisposal, freddypharkasPatchScoreDisposal },
+ { true, 15, "Mac: broken inventory", 1, freddypharkasSignatureMacInventory, freddypharkasPatchMacInventory },
+ { true, 235, "CD: canister pickup hang", 3, freddypharkasSignatureCanisterHang, freddypharkasPatchCanisterHang },
+ { true, 320, "ladder event issue", 2, freddypharkasSignatureLadderEvent, freddypharkasPatchLadderEvent },
SCI_SIGNATUREENTRY_TERMINATOR
};
// ===========================================================================
// daySixBeignet::changeState (4) is called when the cop goes out and sets cycles to 220.
// this is not enough time to get to the door, so we patch that to 23 seconds
-const byte gk1SignatureDay6PoliceBeignet[] = {
- 4,
- 0x35, 0x04, // ldi 04
- 0x1a, // eq?
- 0x30, // bnt [next state check]
- +2, 5, // [skip 2 bytes, offset of bnt]
- 0x38, 0x93, 0x00, // pushi 93 (selector dispose)
- 0x76, // push0
- 0x72, // lofsa deskSarg
- +2, 9, // [skip 2 bytes, offset of lofsa]
- 0x4a, 0x04, 0x00, // send 04
- 0x34, 0xdc, 0x00, // ldi 220
- 0x65, 0x1a, // aTop cycles
- 0x32, // jmp [end]
- 0
-};
-
-const uint16 gk1PatchDay6PoliceBeignet[] = {
- PATCH_ADDTOOFFSET | +16,
- 0x34, 0x17, 0x00, // ldi 23
- 0x65, 0x1c, // aTop seconds
+// Applies to at least: English PC-CD, German PC-CD, English Mac
+// Responsible method: daySixBeignet::changeState
+static const uint16 gk1SignatureDay6PoliceBeignet[] = {
+ 0x35, 0x04, // ldi 04
+ 0x1a, // eq?
+ 0x30, SIG_ADDTOOFFSET(+2), // bnt [next state check]
+ 0x38, SIG_SELECTOR16(dispose), // pushi dispose
+ 0x76, // push0
+ 0x72, SIG_ADDTOOFFSET(+2), // lofsa deskSarg
+ 0x4a, SIG_UINT16(0x0004), // send 04
+ SIG_MAGICDWORD,
+ 0x34, SIG_UINT16(0x00dc), // ldi 220
+ 0x65, SIG_ADDTOOFFSET(+1), // aTop cycles (1a for PC, 1c for Mac)
+ 0x32, // jmp [end]
+ SIG_END
+};
+
+static const uint16 gk1PatchDay6PoliceBeignet[] = {
+ PATCH_ADDTOOFFSET(+16),
+ 0x34, PATCH_UINT16(0x0017), // ldi 23
+ 0x65, PATCH_GETORIGINALBYTEADJUST(+20, +2), // aTop seconds (1c for PC, 1e for Mac)
PATCH_END
};
// sargSleeping::changeState (8) is called when the cop falls asleep and sets cycles to 220.
// this is not enough time to get to the door, so we patch it to 42 seconds
-const byte gk1SignatureDay6PoliceSleep[] = {
- 4,
- 0x35, 0x08, // ldi 08
- 0x1a, // eq?
- 0x31, // bnt [next state check]
- +1, 6, // [skip 1 byte, offset of bnt]
- 0x34, 0xdc, 0x00, // ldi 220
- 0x65, 0x1a, // aTop cycles
- 0x32, // jmp [end]
+// Applies to at least: English PC-CD, German PC-CD, English Mac
+// Responsible method: sargSleeping::changeState
+static const uint16 gk1SignatureDay6PoliceSleep[] = {
+ 0x35, 0x08, // ldi 08
+ 0x1a, // eq?
+ 0x31, SIG_ADDTOOFFSET(+1), // bnt [next state check]
+ SIG_MAGICDWORD,
+ 0x34, SIG_UINT16(0x00dc), // ldi 220
+ 0x65, SIG_ADDTOOFFSET(+1), // aTop cycles (1a for PC, 1c for Mac)
+ 0x32, // jmp [end]
0
};
-const uint16 gk1PatchDay6PoliceSleep[] = {
- PATCH_ADDTOOFFSET | +5,
- 0x34, 0x2a, 0x00, // ldi 42
- 0x65, 0x1c, // aTop seconds
+static const uint16 gk1PatchDay6PoliceSleep[] = {
+ PATCH_ADDTOOFFSET(+5),
+ 0x34, SIG_UINT16(0x002a), // ldi 42
+ 0x65, PATCH_GETORIGINALBYTEADJUST(+9, +2), // aTop seconds (1c for PC, 1e for Mac)
PATCH_END
};
// startOfDay5::changeState (20h) - when gabriel goes to the phone the script will hang
-const byte gk1SignatureDay5PhoneFreeze[] = {
- 5,
- 0x35, 0x03, // ldi 03
- 0x65, 0x1a, // aTop cycles
- 0x32, // jmp [end]
- +2, 3, // [skip 2 bytes, offset of jmp]
- 0x3c, // dup
- 0x35, 0x21, // ldi 21
- 0
-};
-
-const uint16 gk1PatchDay5PhoneFreeze[] = {
- 0x35, 0x06, // ldi 06
- 0x65, 0x20, // aTop ticks
+// Applies to at least: English PC-CD, German PC-CD, English Mac
+// Responsible method: startOfDay5::changeState
+static const uint16 gk1SignatureDay5PhoneFreeze[] = {
+ 0x4a,
+ SIG_MAGICDWORD, SIG_UINT16(0x000c), // send 0c
+ 0x35, 0x03, // ldi 03
+ 0x65, SIG_ADDTOOFFSET(+1), // aTop cycles
+ 0x32, SIG_ADDTOOFFSET(+2), // jmp [end]
+ 0x3c, // dup
+ 0x35, 0x21, // ldi 21
+ SIG_END
+};
+
+static const uint16 gk1PatchDay5PhoneFreeze[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x35, 0x06, // ldi 01
+ 0x65, PATCH_GETORIGINALBYTEADJUST(+6, +6), // aTop ticks
PATCH_END
};
@@ -530,63 +601,66 @@ const uint16 gk1PatchDay5PhoneFreeze[] = {
// comparison between a number an an object. In the CD version, the checks are
// in the correct order, thus the comparison is correct, thus we use the code
// from the CD version in the floppy one.
-const byte gk1SignatureInterrogationBug[] = {
- 43,
- 0x65, 0x4c, // aTop 4c
- 0x67, 0x50, // pTos 50
- 0x34, 0x10, 0x27, // ldi 2710
- 0x1e, // gt?
- 0x31, 0x08, // bnt 08 [05a0]
- 0x67, 0x50, // pTos 50
- 0x34, 0x10, 0x27, // ldi 2710
- 0x04, // sub
- 0x65, 0x50, // aTop 50
- 0x63, 0x50, // pToa 50
- 0x31, 0x15, // bnt 15 [05b9]
- 0x39, 0x0e, // pushi 0e
- 0x76, // push0
- 0x4a, 0x04, 0x00, // send 0004
- 0xa5, 0x00, // sat 00
- 0x38, 0x93, 0x00, // pushi 0093
- 0x76, // push0
- 0x63, 0x50, // pToa 50
- 0x4a, 0x04, 0x00, // send 0004
- 0x85, 0x00, // lat 00
- 0x65, 0x50, // aTop 50
- 0
+// Applies to at least: English Floppy
+// Responsible method: Interrogation::dispose
+// TODO: Check, if English Mac is affected too and if this patch applies
+static const uint16 gk1SignatureInterrogationBug[] = {
+ SIG_MAGICDWORD,
+ 0x65, 0x4c, // aTop 4c
+ 0x67, 0x50, // pTos 50
+ 0x34, SIG_UINT16(0x2710), // ldi 2710
+ 0x1e, // gt?
+ 0x31, 0x08, // bnt 08 [05a0]
+ 0x67, 0x50, // pTos 50
+ 0x34, SIG_UINT16(0x2710), // ldi 2710
+ 0x04, // sub
+ 0x65, 0x50, // aTop 50
+ 0x63, 0x50, // pToa 50
+ 0x31, 0x15, // bnt 15 [05b9]
+ 0x39, 0x0e, // pushi 0e
+ 0x76, // push0
+ 0x4a, SIG_UINT16(0x0004), // send 0004
+ 0xa5, 0x00, // sat 00
+ 0x38, SIG_SELECTOR16(dispose), // pushi dispose
+ 0x76, // push0
+ 0x63, 0x50, // pToa 50
+ 0x4a, SIG_UINT16(0x0004), // send 0004
+ 0x85, 0x00, // lat 00
+ 0x65, 0x50, // aTop 50
+ SIG_END
+};
+
+static const uint16 gk1PatchInterrogationBug[] = {
+ 0x65, 0x4c, // aTop 4c
+ 0x63, 0x50, // pToa 50
+ 0x31, 0x15, // bnt 15 [05b9]
+ 0x39, 0x0e, // pushi 0e
+ 0x76, // push0
+ 0x4a, 0x04, 0x00, // send 0004
+ 0xa5, 0x00, // sat 00
+ 0x38, SIG_SELECTOR16(dispose), // pushi dispose
+ 0x76, // push0
+ 0x63, 0x50, // pToa 50
+ 0x4a, 0x04, 0x00, // send 0004
+ 0x85, 0x00, // lat 00
+ 0x65, 0x50, // aTop 50
+ 0x67, 0x50, // pTos 50
+ 0x34, PATCH_UINT16(0x2710), // ldi 2710
+ 0x1e, // gt?
+ 0x31, 0x08, // bnt 08 [05b9]
+ 0x67, 0x50, // pTos 50
+ 0x34, PATCH_UINT16(0x2710), // ldi 2710
+ 0x04, // sub
+ 0x65, 0x50, // aTop 50
+ PATCH_END
};
-const uint16 gk1PatchInterrogationBug[] = {
- 0x65, 0x4c, // aTop 4c
- 0x63, 0x50, // pToa 50
- 0x31, 0x15, // bnt 15 [05b9]
- 0x39, 0x0e, // pushi 0e
- 0x76, // push0
- 0x4a, 0x04, 0x00, // send 0004
- 0xa5, 0x00, // sat 00
- 0x38, 0x93, 0x00, // pushi 0093
- 0x76, // push0
- 0x63, 0x50, // pToa 50
- 0x4a, 0x04, 0x00, // send 0004
- 0x85, 0x00, // lat 00
- 0x65, 0x50, // aTop 50
- 0x67, 0x50, // pTos 50
- 0x34, 0x10, 0x27, // ldi 2710
- 0x1e, // gt?
- 0x31, 0x08, // bnt 08 [05b9]
- 0x67, 0x50, // pTos 50
- 0x34, 0x10, 0x27, // ldi 2710
- 0x04, // sub
- 0x65, 0x50, // aTop 50
- PATCH_END
-};
-
-// script, description, magic DWORD, adjust
-const SciScriptSignature gk1Signatures[] = {
- { 51, "interrogation bug", 1, PATCH_MAGICDWORD(0x65, 0x4c, 0x67, 0x50), 0, gk1SignatureInterrogationBug, gk1PatchInterrogationBug },
- { 212, "day 5 phone freeze", 1, PATCH_MAGICDWORD(0x35, 0x03, 0x65, 0x1a), 0, gk1SignatureDay5PhoneFreeze, gk1PatchDay5PhoneFreeze },
- { 230, "day 6 police beignet timer issue", 1, PATCH_MAGICDWORD(0x34, 0xdc, 0x00, 0x65), -16, gk1SignatureDay6PoliceBeignet, gk1PatchDay6PoliceBeignet },
- { 230, "day 6 police sleep timer issue", 1, PATCH_MAGICDWORD(0x34, 0xdc, 0x00, 0x65), -5, gk1SignatureDay6PoliceSleep, gk1PatchDay6PoliceSleep },
+// script, description, signature patch
+static const SciScriptPatcherEntry gk1Signatures[] = {
+ { true, 51, "interrogation bug", 1, gk1SignatureInterrogationBug, gk1PatchInterrogationBug },
+ { true, 212, "day 5 phone freeze", 1, gk1SignatureDay5PhoneFreeze, gk1PatchDay5PhoneFreeze },
+ { true, 230, "day 6 police beignet timer issue", 1, gk1SignatureDay6PoliceBeignet, gk1PatchDay6PoliceBeignet },
+ { true, 230, "day 6 police sleep timer issue", 1, gk1SignatureDay6PoliceSleep, gk1PatchDay6PoliceSleep },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -596,47 +670,47 @@ const SciScriptSignature gk1Signatures[] = {
// is later used to set master volume. This issue makes sierra sci set
// the volume to max. We fix the export, so volume won't get modified in
// those cases.
-const byte kq5SignatureCdHarpyVolume[] = {
- 34,
- 0x80, 0x91, 0x01, // lag global[191h]
- 0x18, // not
- 0x30, 0x2c, 0x00, // bnt [jump further] (jumping, if global 191h is 1)
- 0x35, 0x01, // ldi 01
- 0xa0, 0x91, 0x01, // sag global[191h] (setting global 191h to 1)
- 0x38, 0x7b, 0x01, // pushi 017b
- 0x76, // push0
- 0x81, 0x01, // lag global[1]
- 0x4a, 0x04, // send 04 - read KQ5::masterVolume
- 0xa5, 0x03, // sat temp[3] (store volume in temp 3)
- 0x38, 0x7b, 0x01, // pushi 017b
- 0x76, // push0
- 0x81, 0x01, // lag global[1]
- 0x4a, 0x04, // send 04 - read KQ5::masterVolume
- 0x36, // push
- 0x35, 0x04, // ldi 04
- 0x20, // ge? (followed by bnt)
- 0
-};
-
-const uint16 kq5PatchCdHarpyVolume[] = {
- 0x38, 0x2f, 0x02, // pushi 022f (selector theVol) (3 new bytes)
- 0x76, // push0 (1 new byte)
- 0x51, 0x88, // class SpeakTimer (2 new bytes)
- 0x4a, 0x04, // send 04 (2 new bytes) -> read SpeakTimer::theVol
- 0xa5, 0x03, // sat temp[3] (2 new bytes) -> write to temp 3
- 0x80, 0x91, 0x01, // lag global[191h]
+static const uint16 kq5SignatureCdHarpyVolume[] = {
+ SIG_MAGICDWORD,
+ 0x80, SIG_UINT16(0x0191), // lag global[191h]
+ 0x18, // not
+ 0x30, SIG_UINT16(0x002c), // bnt [jump further] (jumping, if global 191h is 1)
+ 0x35, 0x01, // ldi 01
+ 0xa0, SIG_UINT16(0x0191), // sag global[191h] (setting global 191h to 1)
+ 0x38, SIG_UINT16(0x017b), // pushi 017b
+ 0x76, // push0
+ 0x81, 0x01, // lag global[1]
+ 0x4a, 0x04, // send 04 - read KQ5::masterVolume
+ 0xa5, 0x03, // sat temp[3] (store volume in temp 3)
+ 0x38, SIG_UINT16(0x017b), // pushi 017b
+ 0x76, // push0
+ 0x81, 0x01, // lag global[1]
+ 0x4a, 0x04, // send 04 - read KQ5::masterVolume
+ 0x36, // push
+ 0x35, 0x04, // ldi 04
+ 0x20, // ge? (followed by bnt)
+ SIG_END
+};
+
+static const uint16 kq5PatchCdHarpyVolume[] = {
+ 0x38, PATCH_UINT16(0x022f), // pushi 022f (selector theVol) (3 new bytes)
+ 0x76, // push0 (1 new byte)
+ 0x51, 0x88, // class SpeakTimer (2 new bytes)
+ 0x4a, 0x04, // send 04 (2 new bytes) -> read SpeakTimer::theVol
+ 0xa5, 0x03, // sat temp[3] (2 new bytes) -> write to temp 3
+ 0x80, PATCH_UINT16(0x0191), // lag global[191h]
// saving 1 byte due optimization
- 0x2e, 0x23, 0x00, // bt [jump further] (jumping, if global 191h is 1)
- 0x35, 0x01, // ldi 01
- 0xa0, 0x91, 0x01, // sag global[191h] (setting global 191h to 1)
- 0x38, 0x7b, 0x01, // pushi 017b
- 0x76, // push0
- 0x81, 0x01, // lag global[1]
- 0x4a, 0x04, // send 04 - read KQ5::masterVolume
- 0xa5, 0x03, // sat temp[3] (store volume in temp 3)
+ 0x2e, PATCH_UINT16(0x0023), // bt [jump further] (jumping, if global 191h is 1)
+ 0x35, 0x01, // ldi 01
+ 0xa0, PATCH_UINT16(0x0191), // sag global[191h] (setting global 191h to 1)
+ 0x38, PATCH_UINT16(0x017b), // pushi 017b
+ 0x76, // push0
+ 0x81, 0x01, // lag global[1]
+ 0x4a, 0x04, // send 04 - read KQ5::masterVolume
+ 0xa5, 0x03, // sat temp[3] (store volume in temp 3)
// saving 8 bytes due removing of duplicate code
- 0x39, 0x04, // pushi 04 (saving 1 byte due swapping)
- 0x22, // lt? (because we switched values)
+ 0x39, 0x04, // pushi 04 (saving 1 byte due swapping)
+ 0x22, // lt? (because we switched values)
PATCH_END
};
@@ -648,30 +722,32 @@ const uint16 kq5PatchCdHarpyVolume[] = {
// Additionally its top,left,bottom,right properties are set to 0 rather
// than the right values. We fix the object by setting the right values.
// If they are all zero, this causes an impossible position check in
-// witch::cantBeHere and an infinite loop when entering room 22 (bug #3034714).
+// witch::cantBeHere and an infinite loop when entering room 22.
//
// This bug is accidentally not triggered in SSCI because the invalid number
// of variables effectively hides witchCage::doit, causing this position check
// to be bypassed entirely.
// See also the warning+comment in Object::initBaseObject
-const byte kq5SignatureWitchCageInit[] = {
- 16,
- 0x00, 0x00, // top
- 0x00, 0x00, // left
- 0x00, 0x00, // bottom
- 0x00, 0x00, // right
- 0x00, 0x00, // extra property #1
- 0x7a, 0x00, // extra property #2
- 0xc8, 0x00, // extra property #3
- 0xa3, 0x00, // extra property #4
- 0
-};
-
-const uint16 kq5PatchWitchCageInit[] = {
- 0x00, 0x00, // top
- 0x7a, 0x00, // left
- 0xc8, 0x00, // bottom
- 0xa3, 0x00, // right
+//
+// Fixes bug: #4964
+static const uint16 kq5SignatureWitchCageInit[] = {
+ SIG_UINT16(0x0000), // top
+ SIG_UINT16(0x0000), // left
+ SIG_UINT16(0x0000), // bottom
+ SIG_UINT16(0x0000), // right
+ SIG_UINT16(0x0000), // extra property #1
+ SIG_MAGICDWORD,
+ SIG_UINT16(0x007a), // extra property #2
+ SIG_UINT16(0x00c8), // extra property #3
+ SIG_UINT16(0x00a3), // extra property #4
+ SIG_END
+};
+
+static const uint16 kq5PatchWitchCageInit[] = {
+ PATCH_UINT16(0x0000), // top
+ PATCH_UINT16(0x007a), // left
+ PATCH_UINT16(0x00c8), // bottom
+ PATCH_UINT16(0x00a3), // right
PATCH_END
};
@@ -689,31 +765,25 @@ const uint16 kq5PatchWitchCageInit[] = {
// changes to GameFeatures::detectsetCursorType() ) and breaking savegame
// compatibilty between the DOS and Windows CD versions of KQ5.
// TODO: Investigate these side effects more closely.
-const byte kq5SignatureWinGMSignals[] = {
- 9,
- 0x80, 0x90, 0x01, // lag 0x190
- 0x18, // not
- 0x30, 0x1b, 0x00, // bnt +0x001B
- 0x89, 0x57, // lsg 0x57
- 0
+static const uint16 kq5SignatureWinGMSignals[] = {
+ SIG_MAGICDWORD,
+ 0x80, SIG_UINT16(0x0190), // lag 0x190
+ 0x18, // not
+ 0x30, SIG_UINT16(0x001b), // bnt +0x001B
+ 0x89, 0x57, // lsg 0x57
+ SIG_END
};
-const uint16 kq5PatchWinGMSignals[] = {
- 0x34, 0x01, 0x00, // ldi 0x0001
+static const uint16 kq5PatchWinGMSignals[] = {
+ 0x34, PATCH_UINT16(0x0001), // ldi 0x0001
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature kq5Signatures[] = {
- { 0, "CD: harpy volume change", 1, PATCH_MAGICDWORD(0x80, 0x91, 0x01, 0x18), 0, kq5SignatureCdHarpyVolume, kq5PatchCdHarpyVolume },
- { 200, "CD: witch cage init", 1, PATCH_MAGICDWORD(0x7a, 0x00, 0xc8, 0x00), -10, kq5SignatureWitchCageInit, kq5PatchWitchCageInit },
- SCI_SIGNATUREENTRY_TERMINATOR
-};
-
-const SciScriptSignature kq5WinGMSignatures[] = {
- { 0, "CD: harpy volume change", 1, PATCH_MAGICDWORD(0x80, 0x91, 0x01, 0x18), 0, kq5SignatureCdHarpyVolume, kq5PatchCdHarpyVolume },
- { 200, "CD: witch cage init", 1, PATCH_MAGICDWORD(0x7a, 0x00, 0xc8, 0x00), -10, kq5SignatureWitchCageInit, kq5PatchWitchCageInit },
- { 124, "Win: GM Music signal checks", 4, PATCH_MAGICDWORD(0x80, 0x90, 0x01, 0x18), 0, kq5SignatureWinGMSignals, kq5PatchWinGMSignals },
+// script, description, signature patch
+static const SciScriptPatcherEntry kq5Signatures[] = {
+ { true, 0, "CD: harpy volume change", 1, kq5SignatureCdHarpyVolume, kq5PatchCdHarpyVolume },
+ { true, 200, "CD: witch cage init", 1, kq5SignatureWitchCageInit, kq5PatchWitchCageInit },
+ { false, 124, "Win: GM Music signal checks", 4, kq5SignatureWinGMSignals, kq5PatchWinGMSignals },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -725,25 +795,518 @@ const SciScriptSignature kq5WinGMSignatures[] = {
// sound is played twice, squelching all other sounds. We just rip the
// unnecessary cryMusic::check method out, thereby stopping the sound from
// constantly restarting (since it's being looped anyway), thus the normal
-// game speech can work while the baby cry sound is heard. Fixes bug #3034579.
-const byte kq6SignatureDuplicateBabyCry[] = {
- 10,
- 0x83, 0x00, // lal 00
- 0x31, 0x1e, // bnt 1e [07f4]
- 0x78, // push1
- 0x39, 0x04, // pushi 04
- 0x43, 0x75, 0x02, // callk DoAudio[75] 02
- 0
+// game speech can work while the baby cry sound is heard.
+// Fixes bug: #4955
+static const uint16 kq6SignatureDuplicateBabyCry[] = {
+ SIG_MAGICDWORD,
+ 0x83, 0x00, // lal 00
+ 0x31, 0x1e, // bnt 1e [07f4]
+ 0x78, // push1
+ 0x39, 0x04, // pushi 04
+ 0x43, 0x75, 0x02, // callk DoAudio[75] 02
+ SIG_END
+};
+
+static const uint16 kq6PatchDuplicateBabyCry[] = {
+ 0x48, // ret
+ PATCH_END
};
-const uint16 kq6PatchDuplicateBabyCry[] = {
- 0x48, // ret
+// The inventory of King's Quest 6 is buggy. When it grows too large,
+// it will get split into 2 pages. Switching between those pages will
+// grow the stack, because it's calling itself per switch.
+// Which means after a while ScummVM will bomb out because the stack frame
+// will be too large. This patch fixes the buggy script.
+// Applies to at least: PC-CD, English PC floppy, German PC floppy, English Mac
+// Responsible method: KqInv::showSelf
+// Fixes bug: #5681
+static const uint16 kq6SignatureInventoryStackFix[] = {
+ 0x67, 0x30, // pTos state
+ 0x34, SIG_UINT16(0x2000), // ldi 2000
+ 0x12, // and
+ 0x18, // not
+ 0x31, 0x04, // bnt [not first refresh]
+ 0x35, 0x00, // ldi 00
+ SIG_MAGICDWORD,
+ 0x65, 0x1e, // aTop curIcon
+ 0x67, 0x30, // pTos state
+ 0x34, SIG_UINT16(0xdfff), // ldi dfff
+ 0x12, // and
+ 0x65, 0x30, // aTop state
+ 0x38, SIG_SELECTOR16(show), // pushi "show" ("show" is e1h for KQ6CD)
+ 0x78, // push1
+ 0x87, 0x00, // lap param[0]
+ 0x31, 0x04, // bnt [use global for show]
+ 0x87, 0x01, // lap param[1]
+ 0x33, 0x02, // jmp [use param for show]
+ 0x81, 0x00, // lag global[0]
+ 0x36, // push
+ 0x54, 0x06, // self 06 (KqInv::show)
+ 0x31, SIG_ADDTOOFFSET(+1), // bnt [exit menu code] (0x08 for PC, 0x07 for mac)
+ 0x39, 0x39, // pushi 39
+ 0x76, // push0
+ 0x54, 0x04, // self 04 (KqInv::doit)
+ SIG_END // followed by jmp (0x32 for PC, 0x33 for mac)
+};
+
+static const uint16 kq6PatchInventoryStackFix[] = {
+ 0x67, 0x30, // pTos state
+ 0x3c, // dup (1 more byte, needed for patch)
+ 0x3c, // dup (1 more byte, saves 1 byte later)
+ 0x34, PATCH_UINT16(0x2000), // ldi 2000
+ 0x12, // and
+ 0x2f, 0x02, // bt [not first refresh] - saves 3 bytes in total
+ 0x65, 0x1e, // aTop curIcon
+ 0x00, // neg (either 2000 or 0000 in acc, this will create dfff or ffff) - saves 2 bytes
+ 0x12, // and
+ 0x65, 0x30, // aTop state
+ 0x38, // pushi "show"
+ PATCH_GETORIGINALBYTE(+22),
+ PATCH_GETORIGINALBYTE(+23),
+ 0x78, // push1
+ 0x87, 0x00, // lap param[0]
+ 0x31, 0x04, // bnt [call show using global 0]
+ 0x8f, 0x01, // lsp param[1], save 1 byte total with lsg global[0] combined
+ 0x33, 0x02, // jmp [call show using param 1]
+ 0x89, 0x00, // lsg global[0], save 1 byte total, see above
+ 0x54, 0x06, // self 06 (call x::show)
+ 0x31, // bnt [menu exit code]
+ PATCH_GETORIGINALBYTEADJUST(+39, +6),// dynamic offset must be 0x0E for PC and 0x0D for mac
+ 0x34, PATCH_UINT16(0x2000), // ldi 2000
+ 0x12, // and
+ 0x2f, 0x05, // bt [to return]
+ 0x39, 0x39, // pushi 39
+ 0x76, // push0
+ 0x54, 0x04, // self 04 (self::doit)
+ 0x48, // ret (saves 2 bytes for PC, 1 byte for mac)
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature kq6Signatures[] = {
- { 481, "duplicate baby cry", 1, PATCH_MAGICDWORD(0x83, 0x00, 0x31, 0x1e), 0, kq6SignatureDuplicateBabyCry, kq6PatchDuplicateBabyCry },
+// The "Drink Me" bottle code doesn't repaint the AddToPics elements to the screen,
+// when Alexander returns back from the effect of the bottle.
+// It's pretty strange that Sierra didn't find this bug, because it occurs when
+// drinking the bottle right on the screen, where the bottle is found.
+// This bug also occurs in Sierra SCI.
+// Applies to at least: PC-CD, English PC floppy, German PC floppy, English Mac
+// Responsible method: drinkMeScript::changeState
+// Fixes bug: #5252
+static const uint16 kq6SignatureDrinkMeFix[] = {
+ SIG_MAGICDWORD,
+ 0x3c, // dup
+ 0x35, 0x0f, // ldi 0f
+ 0x1a, // eq?
+ 0x30, SIG_UINT16(0x00a4), // bnt [skip to next check]
+ SIG_ADDTOOFFSET(+161),
+ 0x32, SIG_UINT16(0x007f), // jmp [return]
+ 0x3c, // dup
+ 0x35, 0x10, // ldi 10
+ 0x1a, // eq?
+ 0x31, 0x07, // bnt [skip to next check]
+ 0x35, 0x03, // ldi 03
+ 0x65, 0x1a, // aTop (cycles)
+ 0x32, SIG_UINT16(0x0072), // jmp [return]
+ 0x3c, // dup
+ 0x35, 0x11, // ldi 11
+ 0x1a, // eq?
+ 0x31, 0x13, // bnt [skip to next check]
+ SIG_ADDTOOFFSET(+20),
+ 0x35, 0x12, // ldi 12
+ SIG_ADDTOOFFSET(+23),
+ 0x35, 0x13, // ldi 13
+ SIG_END
+};
+
+static const uint16 kq6PatchDrinkMeFix[] = {
+ PATCH_ADDTOOFFSET(+5), // skip to bnt offset
+ PATCH_GETORIGINALBYTEADJUST(+5, +13), // adjust jump to [check for 11h code]
+ PATCH_ADDTOOFFSET(+162),
+ 0x39, PATCH_SELECTOR8(doit), // pushi (doit)
+ 0x76, // push0
+ 0x81, 0x0a, // lag 0a
+ 0x4a, 0x04, // send 04 (call addToPics::doit)
+ 0x3a, // toss
+ 0x48, // ret
+ PATCH_ADDTOOFFSET(+8), // skip to check 11h code
+ 0x35, 0x10, // ldi 10 instead of 11
+ PATCH_ADDTOOFFSET(+23), // skip to check 12h code
+ 0x35, 0x11, // ldi 11 instead of 12
+ PATCH_ADDTOOFFSET(+23), // skip to check 13h code
+ 0x35, 0x12, // ldi 12 instead of 13
+ PATCH_END
+};
+
+// Audio + subtitles support - SHARED! - used for King's Quest 6 and Laura Bow 2
+// this patch gets enabled, when the user selects "both" in the ScummVM "Speech + Subtitles" menu
+// We currently use global 98d to hold a kMemory pointer.
+// Applies to at least: KQ6 PC-CD, LB2 PC-CD
+// Patched method: Messager::sayNext / lb2Messager::sayNext (always use text branch)
+static const uint16 kq6laurabow2CDSignatureAudioTextSupport1[] = {
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x12, // and
+ SIG_MAGICDWORD,
+ 0x31, 0x13, // bnt [audio call]
+ 0x38, SIG_SELECTOR16(modNum), // pushi modNum
+ SIG_END
+};
+
+static const uint16 kq6laurabow2CDPatchAudioTextSupport1[] = {
+ PATCH_ADDTOOFFSET(+5),
+ 0x33, 0x13, // jmp [audio call]
+ PATCH_END
+};
+
+// Applies to at least: KQ6 PC-CD, LB2 PC-CD
+// Patched method: Messager::sayNext / lb2Messager::sayNext (allocate audio memory)
+static const uint16 kq6laurabow2CDSignatureAudioTextSupport2[] = {
+ 0x7a, // push2
+ 0x78, // push1
+ 0x39, 0x0c, // pushi 0c
+ 0x43, SIG_MAGICDWORD, 0x72, 0x04, // kMemory
+ 0xa5, 0xc9, // sat global[c9]
+ SIG_END
+};
+
+static const uint16 kq6laurabow2CDPatchAudioTextSupport2[] = {
+ PATCH_ADDTOOFFSET(+7),
+ 0xa1, 98, // sag global[98d]
+ PATCH_END
+};
+
+// Applies to at least: KQ6 PC-CD, LB2 PC-CD
+// Patched method: Messager::sayNext / lb2Messager::sayNext (release audio memory)
+static const uint16 kq6laurabow2CDSignatureAudioTextSupport3[] = {
+ 0x7a, // push2
+ 0x39, 0x03, // pushi 03
+ SIG_MAGICDWORD,
+ 0x8d, 0xc9, // lst temp[c9]
+ 0x43, 0x72, 0x04, // kMemory
+ SIG_END
+};
+
+static const uint16 kq6laurabow2CDPatchAudioTextSupport3[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x89, 98, // lsg global[98d]
+ PATCH_END
+};
+
+// startText call gets acc = 0 for text-only and acc = 2 for audio+text
+// Applies to at least: KQ6 PC-CD, LB2 PC-CD
+// Patched method: Narrator::say (use audio memory)
+static const uint16 kq6laurabow2CDSignatureAudioTextSupport4[] = {
+ // set caller property code
+ 0x31, 0x08, // bnt [set acc to 0 for caller]
+ 0x87, 0x02, // lap param[2]
+ 0x31, 0x04, // bnt [set acc to 0 for caller]
+ 0x87, 0x02, // lap param[2]
+ 0x33, 0x02, // jmp [set caller]
+ 0x35, 0x00, // ldi 00
+ 0x65, 0x68, // aTop caller
+ // call startText + startAudio code
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x01, // ldi 01
+ 0x12, // and
+ 0x31, 0x08, // bnt [skip code]
+ 0x38, SIG_SELECTOR16(startText), // pushi startText
+ 0x78, // push1
+ 0x8f, 0x01, // lsp param[1]
+ 0x54, 0x06, // self 06
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x12, // and
+ 0x31, 0x08, // bnt [skip code]
+ SIG_MAGICDWORD,
+ 0x38, SIG_SELECTOR16(startAudio), // pushi startAudio
+ 0x78, // push1
+ 0x8f, 0x01, // lsp param[1]
+ 0x54, 0x06, // self 06
+ SIG_END
+};
+
+static const uint16 kq6laurabow2CDPatchAudioTextSupport4[] = {
+ 0x31, 0x02, // bnt [set caller]
+ 0x87, 0x02, // lap param[2]
+ 0x65, 0x68, // aTop caller
+ 0x81, 0x5a, // lag global[5a]
+ 0x78, // push1
+ 0x12, // and
+ 0x31, 0x11, // bnt [skip startText code]
+ 0x81, 0x5a, // lag global[5a]
+ 0x7a, // push2
+ 0x12, // and
+ 0x33, 0x03, // skip over 3 unused bytes
+ PATCH_ADDTOOFFSET(+22),
+ 0x89, 98, // lsp global[98d]
+ PATCH_END
+};
+
+// Applies to at least: KQ6 PC-CD, LB2 PC-CD
+// Patched method: Talker::display/Narrator::say (remove reset saved mouse cursor code)
+// code would screw over mouse cursor
+static const uint16 kq6laurabow2CDSignatureAudioTextSupport5[] = {
+ SIG_MAGICDWORD,
+ 0x35, 0x00, // ldi 00
+ 0x65, 0x82, // aTop saveCursor
+ SIG_END
+};
+
+static const uint16 kq6laurabow2CDPatchAudioTextSupport5[] = {
+ 0x18, 0x18, 0x18, 0x18, // waste bytes, do nothing
+ PATCH_END
+};
+
+// Additional patch specifically for King's Quest 6
+// Fixes text window placement, when in "dual" mode
+// Applies to at least: PC-CD
+// Patched method: Kq6Talker::init
+static const uint16 kq6CDSignatureAudioTextSupport1[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x31, SIG_ADDTOOFFSET(+1), // bnt [jump-to-text-code]
+ 0x78, // push1
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextSupport1[] = {
+ PATCH_ADDTOOFFSET(+4),
+ 0x12, // and
+ PATCH_END
+};
+
+// Additional patch specifically for King's Quest 6
+// Fixes low-res portrait staying on screen for hi-res mode
+// Applies to at least: PC-CD
+// Patched method: Talker::startText
+// this method is called by Narrator::say and acc is 0 for text-only and 2 for dual mode (audio+text)
+static const uint16 kq6CDSignatureAudioTextSupport2[] = {
+ SIG_MAGICDWORD,
+ 0x3f, 0x01, // link 01
+ 0x63, 0x8a, // pToa viewInPrint
+ 0x18, // not
+ 0x31, 0x06, // bnt [skip following code]
+ 0x38, SIG_UINT16(0x00e1), // pushi 00e1
+ 0x76, // push0
+ 0x54, 0x04, // self 04
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextSupport2[] = {
+ PATCH_ADDTOOFFSET(+2),
+ 0x67, 0x8a, // pTos viewInPrint
+ 0x14, // or
+ 0x2f, // bt [skip following code]
+ PATCH_END
+};
+
+// Additional patch specifically for King's Quest 6
+// Fixes special windows, used for example in the Pawn shop (room 280),
+// when the man in a robe complains about no more mints.
+// We have to change even more code, because the game uses PODialog class for
+// text windows and myDialog class for audio. Both are saved to KQ6Print::dialog
+// Sadly PODialog is created during KQ6Print::addText, myDialog is set during
+// KQ6Print::showSelf, which is called much later and KQ6Print::addText requires
+// KQ6Print::dialog to be set, which means we have to set it before calling addText
+// for audio mode, otherwise the user would have to click to get those windows disposed.
+// Applies to at least: PC-CD
+// Patched method: KQ6Print::say
+static const uint16 kq6CDSignatureAudioTextSupport3[] = {
+ 0x31, 0x6e, // bnt [to text code]
+ SIG_ADDTOOFFSET(+85),
+ SIG_MAGICDWORD,
+ 0x8f, 0x01, // lsp param[1]
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x0c, // bnt [code to set property repressText to 1]
+ 0x38, // pushi (selector addText)
+ SIG_ADDTOOFFSET(+9), // skip addText-calling code
+ 0x33, 0x10, // jmp [to ret]
+ 0x35, 0x01, // ldi 01
+ 0x65, 0x2e, // aTop repressText
+ 0x33, 0x0a, // jmp [to ret]
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextSupport3[] = {
+ 0x31, 0x5c, // adjust jump to reuse audio mode addText-calling code
+ PATCH_ADDTOOFFSET(102),
+ 0x48, // ret
+ 0x48, // ret (waste byte)
+ 0x72, 0x0e, 0x00, // lofsa myDialog
+ 0x65, 0x12, // aTop dialog
+ 0x33, 0xed, // jump back to audio mode addText-calling code
+ PATCH_END
+};
+
+// Additional patch specifically for King's Quest 6
+// Fixes text-window size for hires portraits mode
+// Otherwise at least at the end some text-windows will be way too small
+// Applies to at least: PC-CD
+// Patched method: Talker::init
+static const uint16 kq6CDSignatureAudioTextSupport4[] = {
+ SIG_MAGICDWORD,
+ 0x63, 0x94, // pToa raving
+ 0x31, 0x0a, // bnt [no rave code]
+ 0x35, 0x00, // ldi 00
+ SIG_ADDTOOFFSET(6), // skip reset of bust, eyes and mouth
+ 0x33, 0x24, // jmp [to super class code]
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextSupport4[] = {
+ PATCH_ADDTOOFFSET(+12),
+ 0x33, PATCH_GETORIGINALBYTEADJUST(+13, -6), // adjust jump to also include setSize call
+ PATCH_END
+};
+
+// Fixes text window placement, when dual mode is active (Guards in room 220)
+// Applies to at least: PC-CD
+// Patched method: tlkGateGuard1::init & tlkGateGuard2::init
+static const uint16 kq6CDSignatureAudioTextSupportGuards[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ SIG_END // followed by bnt for Guard1 and bt for Guard2
+};
+
+static const uint16 kq6CDPatchAudioTextSupportGuards[] = {
+ PATCH_ADDTOOFFSET(+2),
+ 0x35, 0x02, // ldi 02
+ 0x1c, // ne?
+ PATCH_END
+};
+
+// Fixes text window placement, when portrait+text is shown (Stepmother in room 250)
+// Applies to at least: PC-CD
+// Patched method: tlkStepmother::init
+static const uint16 kq6CDSignatureAudioTextSupportStepmother[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x12, // and
+ 0x31, // bnt [jump-for-text-code]
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextSupportJumpAlways[] = {
+ PATCH_ADDTOOFFSET(+4),
+ 0x1a, // eq?
+ PATCH_END
+};
+
+// Fixes "Girl In The Tower" to get played in dual mode as well
+// Applies to at least: PC-CD
+// Patched method: rm740::cue
+static const uint16 kq6CDSignatureAudioTextSupportGirlInTheTower[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x31, // bnt [jump-for-text-code]
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextSupportGirlInTheTower[] = {
+ PATCH_ADDTOOFFSET(+4),
+ 0x12, // and
+ PATCH_END
+};
+
+// Additional patch specifically for King's Quest 6
+// Adds another button state for the text/audio button. We currently use the "speech" view for "dual" mode.
+// View 947, loop 9, cel 0+1 -> "text"
+// View 947, loop 8, cel 0+1 -> "speech"
+// View 947, loop 12, cel 0+1 -> "dual" (this view is injected by us into the game)
+// Applies to at least: PC-CD
+// Patched method: iconTextSwitch::show, iconTextSwitch::doit
+static const uint16 kq6CDSignatureAudioTextMenuSupport[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x31, 0x06, // bnt [set text view]
+ 0x35, 0x08, // ldi 08
+ 0x65, 0x14, // aTop loop
+ 0x33, 0x04, // jmp [skip over text view]
+ 0x35, 0x09, // ldi 09
+ 0x65, 0x14, // aTop loop
+ SIG_ADDTOOFFSET(+102), // skip to iconTextSwitch::doit code
+ 0x89, 0x5a, // lsg global[5a]
+ 0x3c, // dup
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x06, // bnt [set text mode]
+ 0x35, 0x02, // ldi 02
+ 0xa1, 0x5a, // sag global[5a]
+ 0x33, 0x0a, // jmp [skip over text mode code]
+ 0x3c, // dup
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x31, 0x04, // bnt [skip over text ode code]
+ 0x35, 0x01, // ldi 01
+ 0xa1, 0x5a, // sag global[5a]
+ 0x3a, // toss
+ 0x67, 0x14, // pTos loop
+ 0x35, 0x09, // ldi 09
+ 0x1a, // eq?
+ 0x31, 0x04, // bnt [set text view]
+ 0x35, 0x08, // ldi 08
+ 0x33, 0x02, // jmp [skip text view]
+ 0x35, 0x09, // ldi 09
+ 0x65, 0x14, // aTop loop
+ SIG_END
+};
+
+static const uint16 kq6CDPatchAudioTextMenuSupport[] = {
+ PATCH_ADDTOOFFSET(+13),
+ 0x33, 0x79, // jmp to new text+dual code
+ PATCH_ADDTOOFFSET(+104), // seek to iconTextSwitch::doit
+ 0x81, 0x5a, // lag global[5a]
+ 0x78, // push1
+ 0x02, // add
+ 0xa1, 0x5a, // sag global[5a]
+ 0x36, // push
+ 0x35, 0x03, // ldi 03
+ 0x1e, // gt?
+ 0x31, 0x03, // bnt [skip over]
+ 0x78, // push1
+ 0xa9, 0x5a, // ssg global[5a]
+ 0x33, 0x17, // jmp [iconTextSwitch::show call]
+ // additional code for iconTextSwitch::show
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x04, // bnt [dual mode]
+ 0x35, 0x09, // ldi 09
+ 0x33, 0x02, // jmp [skip over dual mode]
+ 0x35, 0x0c, // ldi 0c (view 947, loop 12, cel 0+1 is our "dual" view, injected by view.cpp)
+ 0x65, 0x14, // aTop loop
+ 0x32, PATCH_UINT16(0xff75), // jmp [back to iconTextSwitch::show]
+ PATCH_END
+};
+
+// script, description, signature patch
+static const SciScriptPatcherEntry kq6Signatures[] = {
+ { true, 481, "duplicate baby cry", 1, kq6SignatureDuplicateBabyCry, kq6PatchDuplicateBabyCry },
+ { true, 907, "inventory stack fix", 1, kq6SignatureInventoryStackFix, kq6PatchInventoryStackFix },
+ { true, 87, "Drink Me bottle fix", 1, kq6SignatureDrinkMeFix, kq6PatchDrinkMeFix },
+ // King's Quest 6 and Laura Bow 2 share basic patches for audio + text support
+ // *** King's Quest 6 audio + text support ***
+ { false, 924, "CD: audio + text support KQ6&LB2 1", 1, kq6laurabow2CDSignatureAudioTextSupport1, kq6laurabow2CDPatchAudioTextSupport1 },
+ { false, 924, "CD: audio + text support KQ6&LB2 2", 1, kq6laurabow2CDSignatureAudioTextSupport2, kq6laurabow2CDPatchAudioTextSupport2 },
+ { false, 924, "CD: audio + text support KQ6&LB2 3", 1, kq6laurabow2CDSignatureAudioTextSupport3, kq6laurabow2CDPatchAudioTextSupport3 },
+ { false, 928, "CD: audio + text support KQ6&LB2 4", 1, kq6laurabow2CDSignatureAudioTextSupport4, kq6laurabow2CDPatchAudioTextSupport4 },
+ { false, 928, "CD: audio + text support KQ6&LB2 5", 2, kq6laurabow2CDSignatureAudioTextSupport5, kq6laurabow2CDPatchAudioTextSupport5 },
+ { false, 909, "CD: audio + text support KQ6 1", 2, kq6CDSignatureAudioTextSupport1, kq6CDPatchAudioTextSupport1 },
+ { false, 928, "CD: audio + text support KQ6 2", 1, kq6CDSignatureAudioTextSupport2, kq6CDPatchAudioTextSupport2 },
+ { false, 104, "CD: audio + text support KQ6 3", 1, kq6CDSignatureAudioTextSupport3, kq6CDPatchAudioTextSupport3 },
+ { false, 928, "CD: audio + text support KQ6 4", 1, kq6CDSignatureAudioTextSupport4, kq6CDPatchAudioTextSupport4 },
+ { false, 1009, "CD: audio + text support KQ6 Guards", 2, kq6CDSignatureAudioTextSupportGuards, kq6CDPatchAudioTextSupportGuards },
+ { false, 1027, "CD: audio + text support KQ6 Stepmother", 1, kq6CDSignatureAudioTextSupportStepmother, kq6CDPatchAudioTextSupportJumpAlways },
+ { false, 740, "CD: audio + text support KQ6 Girl In The Tower", 1, kq6CDSignatureAudioTextSupportGirlInTheTower, kq6CDPatchAudioTextSupportGirlInTheTower },
+ { false, 903, "CD: audio + text support KQ6 menu", 1, kq6CDSignatureAudioTextMenuSupport, kq6CDPatchAudioTextMenuSupport },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -756,40 +1319,40 @@ const SciScriptSignature kq6Signatures[] = {
// the function is undefined, thus kStrCat() that is called inside the function
// reads a random pointer and crashes. We patch all of the 5 function calls
// (one for each letter typed from "R", "O", "B", "I", "N") so that they are
-// the same as the English version. Fixes bug #3048054.
-const byte longbowSignatureShowHandCode[] = {
- 3,
- 0x78, // push1
- 0x78, // push1
- 0x72, // lofsa
- +2, 2, // skip 2 bytes, offset of lofsa (the letter typed)
- 0x36, // push
- 0x40, // call
- +2, 3, // skip 2 bytes, offset of call
- 0x02, // perform the call above with 2 parameters
- 0x36, // push
- 0x40, // call
- +2, 8, // skip 2 bytes, offset of call
- 0x02, // perform the call above with 2 parameters
- 0x38, 0x1c, 0x01, // pushi 011c (setMotion)
- 0x39, 0x04, // pushi 04 (x)
- 0x51, 0x1e, // class MoveTo
- 0
-};
-
-const uint16 longbowPatchShowHandCode[] = {
- 0x39, 0x01, // pushi 1 (combine the two push1's in one, like in the English version)
- PATCH_ADDTOOFFSET | +3, // leave the lofsa call untouched
+// the same as the English version.
+// Applies to at least: German floppy
+// Responsible method: unknown
+// Fixes bug: #5264
+static const uint16 longbowSignatureShowHandCode[] = {
+ 0x78, // push1
+ 0x78, // push1
+ 0x72, SIG_ADDTOOFFSET(+2), // lofsa (letter, that was typed)
+ 0x36, // push
+ 0x40, SIG_ADDTOOFFSET(+2), // call
+ 0x02, // perform the call above with 2 parameters
+ 0x36, // push
+ 0x40, SIG_ADDTOOFFSET(+2), // call
+ SIG_MAGICDWORD,
+ 0x02, // perform the call above with 2 parameters
+ 0x38, SIG_SELECTOR16(setMotion), // pushi "setMotion" (0x11c in Longbow German)
+ 0x39, SIG_SELECTOR8(x), // pushi "x" (0x04 in Longbow German)
+ 0x51, 0x1e, // class MoveTo
+ SIG_END
+};
+
+static const uint16 longbowPatchShowHandCode[] = {
+ 0x39, 0x01, // pushi 1 (combine the two push1's in one, like in the English version)
+ PATCH_ADDTOOFFSET(+3), // leave the lofsa call untouched
// The following will remove the duplicate call
- 0x32, 0x02, 0x00, // jmp 02 - skip 2 bytes (the remainder of the first call)
- 0x48, // ret (dummy, should never be reached)
- 0x48, // ret (dummy, should never be reached)
+ 0x32, PATCH_UINT16(0x0002), // jmp 02 - skip 2 bytes (the remainder of the first call)
+ 0x48, // ret (dummy, should never be reached)
+ 0x48, // ret (dummy, should never be reached)
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature longbowSignatures[] = {
- { 210, "hand code crash", 5, PATCH_MAGICDWORD(0x02, 0x38, 0x1c, 0x01), -14, longbowSignatureShowHandCode, longbowPatchShowHandCode },
+// script, description, signature patch
+static const SciScriptPatcherEntry longbowSignatures[] = {
+ { true, 210, "hand code crash", 5, longbowSignatureShowHandCode, longbowPatchShowHandCode },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -807,31 +1370,60 @@ const SciScriptSignature longbowSignatures[] = {
// "worked" in SSCI, but ScummVM/SCI doesn't allow that.
// That's why those points weren't granted here at all.
// We patch the script to use global 90, which seems to be unused in the whole game.
+// Applies to at least: English floppy
// Responsible method: rm63Script::handleEvent
-// Fixes bug #3614419
-const byte larry2SignatureWearParachutePoints[] = {
- 16,
- 0x35, 0x01, // ldi 01
- 0xa1, 0x8e, // sag 8e
- 0x80, 0xe0, 0x01, // lag 1e0
- 0x18, // not
- 0x30, 0x0f, 0x00, // bnt [don't give points]
- 0x35, 0x01, // ldi 01
- 0xa0, 0xe0, 0x01, // sag 1e0
- 0
+// Fixes bug: #6346
+static const uint16 larry2SignatureWearParachutePoints[] = {
+ 0x35, 0x01, // ldi 01
+ 0xa1, SIG_MAGICDWORD, 0x8e, // sag 8e
+ 0x80, SIG_UINT16(0x01e0), // lag 1e0
+ 0x18, // not
+ 0x30, SIG_UINT16(0x000f), // bnt [don't give points]
+ 0x35, 0x01, // ldi 01
+ 0xa0, 0xe0, 0x01, // sag 1e0
+ SIG_END
+};
+
+static const uint16 larry2PatchWearParachutePoints[] = {
+ PATCH_ADDTOOFFSET(+4),
+ 0x80, PATCH_UINT16(0x005a), // lag 5a (global 90)
+ PATCH_ADDTOOFFSET(+6),
+ 0xa0, PATCH_UINT16(0x005a), // sag 5a (global 90)
+ PATCH_END
};
-const uint16 larry2PatchWearParachutePoints[] = {
- PATCH_ADDTOOFFSET | +4,
- 0x80, 0x5a, 0x00, // lag 5a (global 90)
- PATCH_ADDTOOFFSET | +6,
- 0xa0, 0x5a, 0x00, // sag 5a (global 90)
+// script, description, signature patch
+static const SciScriptPatcherEntry larry2Signatures[] = {
+ { true, 63, "plane: no points for wearing plane", 1, larry2SignatureWearParachutePoints, larry2PatchWearParachutePoints },
+ SCI_SIGNATUREENTRY_TERMINATOR
+};
+
+// ===========================================================================
+// Leisure Suit Larry 5
+// In one of the conversations near the end (to be exact - room 380 and the text
+// about using champagne on Reverse Biaz - only used when you actually did that
+// in the game), the German text is too large, causing the textbox to get too large.
+// Because of that the talking head of Patti is drawn over the textbox. A translation oversight.
+// Applies to at least: German floppy
+// Responsible method: none, position of talker object on screen needs to get modified
+static const uint16 larry5SignatureGermanEndingPattiTalker[] = {
+ SIG_MAGICDWORD,
+ SIG_UINT16(0x006e), // object pattiTalker::x (110)
+ SIG_UINT16(0x00b4), // object pattiTalker::y (180)
+ SIG_ADDTOOFFSET(+469), // verify that it's really the German version
+ 0x59, 0x6f, 0x75, // (object name) "You"
+ 0x23, 0x47, 0x44, 0x75, // "#GDu"
+ SIG_END
+};
+
+static const uint16 larry5PatchGermanEndingPattiTalker[] = {
+ PATCH_UINT16(0x005a), // change pattiTalker::x to 90
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature larry2Signatures[] = {
- { 63, "plane: no points for wearing plane", 1, PATCH_MAGICDWORD(0x8e, 0x80, 0xe0, 0x01), -3, larry2SignatureWearParachutePoints, larry2PatchWearParachutePoints },
+// script, description, signature patch
+static const SciScriptPatcherEntry larry5Signatures[] = {
+ { true, 380, "German-only: Enlarge Patti Textbox", 1, larry5SignatureGermanEndingPattiTalker, larry5PatchGermanEndingPattiTalker },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -843,77 +1435,346 @@ const SciScriptSignature larry2Signatures[] = {
// doesn't happen anymore. We would otherwise get a crash
// calling for invalid views (this happens of course also
// in sierra sci)
-const byte larry6SignatureDeathDialog[] = {
- 7,
- 0x3e, 0x33, 0x01, // link 0133 (offset 0x20)
- 0x35, 0xff, // ldi ff
- 0xa3, 0x00, // sal 00
- +255, 0,
- +255, 0,
- +170, 12, // [skip 680 bytes]
- 0x8f, 0x01, // lsp 01 (offset 0x2cf)
- 0x7a, // push2
- 0x5a, 0x04, 0x00, 0x0e, 0x01, // lea 0004 010e
- 0x36, // push
- 0x43, 0x7c, 0x0e, // kMessage[7c] 0e
- +90, 10, // [skip 90 bytes]
- 0x38, 0xd6, 0x00, // pushi 00d6 (offset 0x335)
- 0x78, // push1
- 0x5a, 0x04, 0x00, 0x0e, 0x01, // lea 0004 010e
- 0x36, // push
- +76, 11, // [skip 76 bytes]
- 0x38, 0xcd, 0x00, // pushi 00cd (offset 0x38b)
- 0x39, 0x03, // pushi 03
- 0x5a, 0x04, 0x00, 0x0e, 0x01, // lea 0004 010e
+// Applies to at least: German PC-CD
+// Responsible method: unknown
+static const uint16 larry6SignatureDeathDialog[] = {
+ SIG_MAGICDWORD,
+ 0x3e, SIG_UINT16(0x0133), // link 0133 (offset 0x20)
+ 0x35, 0xff, // ldi ff
+ 0xa3, 0x00, // sal 00
+ SIG_ADDTOOFFSET(+680), // [skip 680 bytes]
+ 0x8f, 0x01, // lsp 01 (offset 0x2cf)
+ 0x7a, // push2
+ 0x5a, SIG_UINT16(0x0004), SIG_UINT16(0x010e), // lea 0004 010e
+ 0x36, // push
+ 0x43, 0x7c, 0x0e, // kMessage[7c] 0e
+ SIG_ADDTOOFFSET(+90), // [skip 90 bytes]
+ 0x38, SIG_UINT16(0x00d6), // pushi 00d6 (offset 0x335)
+ 0x78, // push1
+ 0x5a, SIG_UINT16(0x0004), SIG_UINT16(0x010e), // lea 0004 010e
+ 0x36, // push
+ SIG_ADDTOOFFSET(+76), // [skip 76 bytes]
+ 0x38, SIG_UINT16(0x00cd), // pushi 00cd (offset 0x38b)
+ 0x39, 0x03, // pushi 03
+ 0x5a, SIG_UINT16(0x0004), SIG_UINT16(0x010e), // lea 0004 010e
0x36,
- 0
+ SIG_END
};
-const uint16 larry6PatchDeathDialog[] = {
- 0x3e, 0x00, 0x02, // link 0200
- PATCH_ADDTOOFFSET | +687,
- 0x5a, 0x04, 0x00, 0x40, 0x01, // lea 0004 0140
- PATCH_ADDTOOFFSET | +98,
- 0x5a, 0x04, 0x00, 0x40, 0x01, // lea 0004 0140
- PATCH_ADDTOOFFSET | +82,
- 0x5a, 0x04, 0x00, 0x40, 0x01, // lea 0004 0140
+static const uint16 larry6PatchDeathDialog[] = {
+ 0x3e, 0x00, 0x02, // link 0200
+ PATCH_ADDTOOFFSET(+687),
+ 0x5a, PATCH_UINT16(0x0004), PATCH_UINT16(0x0140), // lea 0004 0140
+ PATCH_ADDTOOFFSET(+98),
+ 0x5a, PATCH_UINT16(0x0004), PATCH_UINT16(0x0140), // lea 0004 0140
+ PATCH_ADDTOOFFSET(+82),
+ 0x5a, PATCH_UINT16(0x0004), PATCH_UINT16(0x0140), // lea 0004 0140
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature larry6Signatures[] = {
- { 82, "death dialog memory corruption", 1, PATCH_MAGICDWORD(0x3e, 0x33, 0x01, 0x35), 0, larry6SignatureDeathDialog, larry6PatchDeathDialog },
+// script, description, signature patch
+static const SciScriptPatcherEntry larry6Signatures[] = {
+ { true, 82, "death dialog memory corruption", 1, larry6SignatureDeathDialog, larry6PatchDeathDialog },
SCI_SIGNATUREENTRY_TERMINATOR
};
// ===========================================================================
-// rm560::doit was supposed to close the painting, when Heimlich enters the
-// room. The code is buggy, so it actually closes the painting, when heimlich
-// is not in the room. We fix that.
-const byte laurabow2SignaturePaintingClosing[] = {
- 17,
- 0x4a, 0x04, // send 04 - read aHeimlich::room
- 0x36, // push
- 0x81, 0x0b, // lag global[11d] -> current room
- 0x1c, // ne?
- 0x31, 0x0e, // bnt [don't close]
- 0x35, 0x00, // ldi 00
- 0xa3, 0x00, // sal local[0]
- 0x38, 0x92, 0x00, // pushi 0092
- 0x78, // push1
- 0x72, // lofsa sDumpSafe
- 0
+// Laura Bow 2
+//
+// Moving away the painting in the room with the hidden safe is problematic
+// for the CD version of the game. safePic::doVerb gets triggered by the mouse-click.
+// This method sets local 0 as signal, which is only meant to get handled, when
+// the player clicks again to move the painting back. This signal is processed by
+// the room doit-script.
+// That doit-script checks safePic::cel to be not equal 0 and would then skip over
+// the "close painting" trigger code. On very fast computers this script may
+// get called too early (which is the case when running under ScummVM and when
+// running the game using Sierra SCI in DOS-Box with cycles 15000) and thinks
+// that it's supposed to move the painting back. Which then results in the painting
+// getting moved to its original position immediately (which means it won't be possible
+// to access the safe behind it).
+//
+// We patch the script, so that we check for cel to be not equal 4 (the final cel) and
+// we also reset the safePic-signal immediately as well.
+//
+// In the floppy version Laura's coordinates are checked directly in rm560::doit
+// and as soon as she moves, the painting will automatically move to its original position.
+// This is not the case for the CD version of the game. The painting will only "move" back,
+// when the player actually exits the room and re-enters.
+//
+// Applies to at least: English PC-CD
+// Responsible method: rm560::doit
+// Fixes bug: #6460
+static const uint16 laurabow2CDSignaturePaintingClosing[] = {
+ 0x39, 0x04, // pushi 04 (cel)
+ 0x76, // push0
+ SIG_MAGICDWORD,
+ 0x7a, // push2
+ 0x38, SIG_UINT16(0x0231), // pushi 0231h (561)
+ 0x76, // push0
+ 0x43, 0x02, 0x04, // kScriptID (get export 0 of script 561)
+ 0x4a, 0x04, // send 04 (gets safePicture::cel)
+ 0x18, // not
+ 0x31, 0x21, // bnt [exit]
+ 0x38, SIG_UINT16(0x0283), // pushi 0283h
+ 0x76, // push0
+ 0x7a, // push2
+ 0x39, 0x20, // pushi 20
+ 0x76, // push0
+ 0x43, 0x02, 0x04, // kScriptID (get export 0 of script 32)
+ 0x4a, 0x04, // send 04 (get sHeimlich::room)
+ 0x36, // push
+ 0x81, 0x0b, // lag global[b] (current room)
+ 0x1c, // ne?
+ 0x31, 0x0e, // bnt [exit]
+ 0x35, 0x00, // ldi 00
+ 0xa3, 0x00, // sal local[0] -> reset safePic signal
+ SIG_END
+};
+
+static const uint16 laurabow2CDPatchPaintingClosing[] = {
+ PATCH_ADDTOOFFSET(+2),
+ 0x3c, // dup (1 additional byte)
+ 0x76, // push0
+ 0x3c, // dup (1 additional byte)
+ 0xab, 0x00, // ssl local[0] -> reset safePic signal
+ 0x7a, // push2
+ 0x38, PATCH_UINT16(0x0231), // pushi 0231h (561)
+ 0x76, // push0
+ 0x43, 0x02, 0x04, // kScriptID (get export 0 of script 561)
+ 0x4a, 0x04, // send 04 (gets safePicture::cel)
+ 0x1a, // eq?
+ 0x31, 0x1d, // bnt [exit]
+ 0x38, PATCH_UINT16(0x0283), // pushi 0283h
+ 0x76, // push0
+ 0x7a, // push2
+ 0x39, 0x20, // pushi 20
+ 0x76, // push0
+ 0x43, 0x02, 0x04, // kScriptID (get export 0 of script 32)
+ 0x4a, 0x04, // send 04 (get sHeimlich::room)
+ 0x36, // push
+ 0x81, 0x0b, // lag global[b] (current room)
+ 0x1a, // eq? (2 opcodes changed, to save 2 bytes)
+ 0x2f, 0x0a, // bt [exit]
+ PATCH_END
+};
+
+// In the CD version the system menu is disabled for certain rooms. LB2::handsOff is called,
+// when leaving the room (and in other cases as well). This method remembers the disabled
+// icons of the icon bar. In the new room LB2::handsOn will get called, which then enables
+// all icons, but also disabled the ones, that were disabled before.
+//
+// Because of this behaviour certain rooms, that should have the system menu enabled, have
+// it disabled, when entering those rooms from rooms, where the menu is supposed to be
+// disabled.
+//
+// We patch this by injecting code into LB2::newRoom (which is called right after a room change)
+// and reset the global variable there, that normally holds the disabled buttons.
+//
+// This patch may cause side-effects and it's difficult to test, because it affects every room
+// in the game. At least for the intro, the speakeasy and plenty of rooms in the beginning it
+// seems to work correctly.
+//
+// Applies to at least: English PC-CD
+// Responsible method: LB2::newRoom, LB2::handsOff, LB2::handsOn
+// Fixes bug: #6440
+static const uint16 laurabow2CDSignatureFixProblematicIconBar[] = {
+ SIG_MAGICDWORD,
+ 0x38, SIG_UINT16(0x00f1), // pushi 00f1 (disable) - hardcoded, we only want to patch the CD version
+ 0x76, // push0
+ 0x81, 0x45, // lag global[45]
+ 0x4a, 0x04, // send 04
+ SIG_END
+};
+
+static const uint16 laurabow2CDPatchFixProblematicIconBar[] = {
+ 0x35, 0x00, // ldi 00
+ 0xa1, 0x74, // sag 74h
+ 0x35, 0x00, // ldi 00 (waste bytes)
+ 0x35, 0x00, // ldi 00
+ PATCH_END
+};
+
+// Opening/Closing the east door in the pterodactyl room doesn't
+// check, if it's locked and will open/close the door internally
+// even when it is.
+//
+// It will get wired shut later in the game by Laura Bow and will be
+// "locked" because of this. We patch in a check for the locked
+// state. We also add code, that will set the "locked" state
+// in case our eastDoor-wired-global is set. This makes the locked
+// state effectively persistent.
+//
+// Applies to at least: English PC-CD, English PC-Floppy
+// Responsible method (CD): eastDoor::doVerb
+// Responsible method (Floppy): eastDoor::<noname300>
+// Fixes bug: #6458 (partly, see additional patch below)
+static const uint16 laurabow2CDSignatureFixWiredEastDoor[] = {
+ 0x30, SIG_UINT16(0x0022), // bnt [skip hand action]
+ 0x67, SIG_ADDTOOFFSET(+1), // pTos CD: doorState, Floppy: state
+ 0x35, 0x00, // ldi 00
+ 0x1a, // eq?
+ 0x31, 0x08, // bnt [close door code]
+ 0x78, // push1
+ SIG_MAGICDWORD,
+ 0x39, 0x63, // pushi 63h
+ 0x45, 0x04, 0x02, // callb export000_4, 02 (sets door-bitflag)
+ 0x33, 0x06, // jmp [super-code]
+ 0x78, // push1
+ 0x39, 0x63, // pushi 63h
+ 0x45, 0x03, 0x02, // callb export000_3, 02 (resets door-bitflag)
+ 0x38, SIG_ADDTOOFFSET(+2), // pushi CD: 011dh, Floppy: 012ch
+ 0x78, // push1
+ 0x8f, 0x01, // lsp param[01]
+ 0x59, 0x02, // rest 02
+ 0x57, SIG_ADDTOOFFSET(+1), 0x06, // super CD: LbDoor, Floppy: Door, 06
+ 0x33, 0x0b, // jmp [ret]
+ SIG_END
+};
+
+static const uint16 laurabow2CDPatchFixWiredEastDoor[] = {
+ 0x31, 0x23, // bnt [skip hand action] (saves 1 byte)
+ 0x81, 97, // lag 97d (get our eastDoor-wired-global)
+ 0x31, 0x04, // bnt [skip setting locked property]
+ 0x35, 0x01, // ldi 01
+ 0x65, 0x6a, // aTop locked (set eastDoor::locked to 1)
+ 0x63, 0x6a, // pToa locked (get eastDoor::locked)
+ 0x2f, 0x17, // bt [skip hand action]
+ 0x63, PATCH_GETORIGINALBYTE(+4), // pToa CD: doorState, Floppy: state
+ 0x78, // push1
+ 0x39, 0x63, // pushi 63h
+ 0x2f, 0x05, // bt [close door code]
+ 0x45, 0x04, 0x02, // callb export000_4, 02 (sets door-bitflag)
+ 0x33, 0x0b, // jmp [super-code]
+ 0x45, 0x03, 0x02, // callb export000_3, 02 (resets door-bitflag)
+ 0x33, 0x06, // jmp [super-code]
+ PATCH_END
+};
+
+// We patch in code, so that our eastDoor-wired-global will get set to 1.
+// This way the wired-state won't get lost when exiting room 430.
+//
+// Applies to at least: English PC-CD, English PC-Floppy
+// Responsible method (CD): sWireItShut::changeState
+// Responsible method (Floppy): sWireItShut::<noname144>
+// Fixes bug: #6458 (partly, see additional patch above)
+static const uint16 laurabow2SignatureRememberWiredEastDoor[] = {
+ SIG_MAGICDWORD,
+ 0x33, 0x27, // jmp [ret]
+ 0x3c, // dup
+ 0x35, 0x06, // ldi 06
+ 0x1a, // eq?
+ 0x31, 0x21, // bnt [skip step]
+ SIG_END
+};
+
+static const uint16 laurabow2PatchRememberWiredEastDoor[] = {
+ PATCH_ADDTOOFFSET(+2), // skip jmp [ret]
+ 0x34, PATCH_UINT16(0x0001), // ldi 0001
+ 0xa1, PATCH_UINT16(97), // sag 97d (set our eastDoor-wired-global)
+ PATCH_END
+};
+
+// Laura Bow 2 CD resets the audio mode to speech on init/restart
+// We already sync the settings from ScummVM (see SciEngine::syncIngameAudioOptions())
+// and this script code would make it impossible to see the intro using "dual" mode w/o using debugger command
+// That's why we remove the corresponding code
+// Patched method: LB2::init, rm100::init
+static const uint16 laurabow2CDSignatureAudioTextSupportModeReset[] = {
+ SIG_MAGICDWORD,
+ 0x35, 0x02, // ldi 02
+ 0xa1, 0x5a, // sag global[5a]
+ SIG_END
+};
+
+static const uint16 laurabow2CDPatchAudioTextSupportModeReset[] = {
+ 0x34, PATCH_UINT16(0x0001), // ldi 0001 (waste bytes)
+ 0x18, // not (waste bytes)
+ PATCH_END
+};
+
+// Directly use global 5a for view-cel id
+// That way it's possible to use a new "dual" mode view in the game menu
+// View 995, loop 13, cel 0 -> "text"
+// View 995, loop 13, cel 1 -> "speech"
+// View 995, loop 13, cel 2 -> "dual" (this view is injected by us into the game)
+// Patched method: gcWin::open
+static const uint16 laurabow2CDSignatureAudioTextMenuSupport1[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x36, // push
+ SIG_END
+};
+
+static const uint16 laurabow2CDPatchAudioTextMenuSupport1[] = {
+ PATCH_ADDTOOFFSET(+2),
+ 0x35, 0x01, // ldi 01
+ 0x04, // sub
+ PATCH_END
};
-const uint16 laurabow2PatchPaintingClosing[] = {
- PATCH_ADDTOOFFSET | +6,
- 0x2f, 0x0e, // bt [don't close]
+// Adds another button state for the text/audio button. We currently use the "speech" view for "dual" mode.
+// Patched method: iconMode::doit
+static const uint16 laurabow2CDSignatureAudioTextMenuSupport2[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg global[5a]
+ 0x3c, // dup
+ 0x1a, // eq?
+ 0x31, 0x0a, // bnt [set text mode]
+ 0x35, 0x02, // ldi 02
+ 0xa1, 0x5a, // sag global[5a]
+ 0x35, 0x01, // ldi 01
+ 0xa5, 0x00, // sat temp[0]
+ 0x33, 0x0e, // jmp [draw cel code]
+ 0x3c, // dup
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x31, 0x08, // bnt [draw cel code]
+ 0x35, 0x01, // ldi 01
+ 0xa1, 0x5a, // sag global[5a]
+ 0x35, 0x00, // ldi 00
+ 0xa5, 0x00, // sat temp[0]
+ 0x3a, // toss
+ SIG_END
+};
+
+static const uint16 laurabow2CDPatchAudioTextMenuSupport2[] = {
+ 0x81, 0x5a, // lag global[5a]
+ 0x78, // push1
+ 0x02, // add
+ 0xa1, 0x5a, // sag global[5a]
+ 0x36, // push
+ 0x35, 0x03, // ldi 03
+ 0x1e, // gt?
+ 0x31, 0x03, // bnt [skip over]
+ 0x78, // push1
+ 0xa9, 0x5a, // ssg global[5a]
+ 0x89, 0x5a, // lsg global[5a]
+ 0x35, 0x01, // ldi 01
+ 0x04, // sub
+ 0xa5, 0x00, // sat temp[0] - calculate global[5a] - 1 to use as view cel id
+ 0x33, 0x07, // jmp [draw cel code, don't do toss]
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature laurabow2Signatures[] = {
- { 560, "painting closing immediately", 1, PATCH_MAGICDWORD(0x36, 0x81, 0x0b, 0x1c), -2, laurabow2SignaturePaintingClosing, laurabow2PatchPaintingClosing },
+// script, description, signature patch
+static const SciScriptPatcherEntry laurabow2Signatures[] = {
+ { true, 560, "CD: painting closing immediately", 1, laurabow2CDSignaturePaintingClosing, laurabow2CDPatchPaintingClosing },
+ { true, 0, "CD: fix problematic icon bar", 1, laurabow2CDSignatureFixProblematicIconBar, laurabow2CDPatchFixProblematicIconBar },
+ { true, 430, "CD/Floppy: make wired east door persistent", 1, laurabow2SignatureRememberWiredEastDoor, laurabow2PatchRememberWiredEastDoor },
+ { true, 430, "CD/Floppy: fix wired east door", 1, laurabow2CDSignatureFixWiredEastDoor, laurabow2CDPatchFixWiredEastDoor },
+ // King's Quest 6 and Laura Bow 2 share basic patches for audio + text support
+ { false, 924, "CD: audio + text support 1", 1, kq6laurabow2CDSignatureAudioTextSupport1, kq6laurabow2CDPatchAudioTextSupport1 },
+ { false, 924, "CD: audio + text support 2", 1, kq6laurabow2CDSignatureAudioTextSupport2, kq6laurabow2CDPatchAudioTextSupport2 },
+ { false, 924, "CD: audio + text support 3", 1, kq6laurabow2CDSignatureAudioTextSupport3, kq6laurabow2CDPatchAudioTextSupport3 },
+ { false, 928, "CD: audio + text support 4", 1, kq6laurabow2CDSignatureAudioTextSupport4, kq6laurabow2CDPatchAudioTextSupport4 },
+ { false, 928, "CD: audio + text support 5", 2, kq6laurabow2CDSignatureAudioTextSupport5, kq6laurabow2CDPatchAudioTextSupport5 },
+ { false, 0, "CD: audio + text support disable mode reset", 1, laurabow2CDSignatureAudioTextSupportModeReset, laurabow2CDPatchAudioTextSupportModeReset },
+ { false, 100, "CD: audio + text support disable mode reset", 1, laurabow2CDSignatureAudioTextSupportModeReset, laurabow2CDPatchAudioTextSupportModeReset },
+ { false, 24, "CD: audio + text support LB2 menu 1", 1, laurabow2CDSignatureAudioTextMenuSupport1, laurabow2CDPatchAudioTextMenuSupport1 },
+ { false, 24, "CD: audio + text support LB2 menu 2", 1, laurabow2CDSignatureAudioTextMenuSupport2, laurabow2CDPatchAudioTextMenuSupport2 },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -922,42 +1783,40 @@ const SciScriptSignature laurabow2Signatures[] = {
// MG::replay somewhat calculates the savedgame-id used when saving again
// this doesn't work right and we remove the code completely.
// We set the savedgame-id directly right after restoring in kRestoreGame.
-const byte mothergoose256SignatureReplay[] = {
- 6,
- 0x36, // push
- 0x35, 0x20, // ldi 20
- 0x04, // sub
- 0xa1, 0xb3, // sag global[b3]
- 0
+static const uint16 mothergoose256SignatureReplay[] = {
+ 0x36, // push
+ 0x35, SIG_MAGICDWORD, 0x20, // ldi 20
+ 0x04, // sub
+ 0xa1, 0xb3, // sag global[b3]
+ SIG_END
};
-const uint16 mothergoose256PatchReplay[] = {
- 0x34, 0x00, 0x00, // ldi 0000 (dummy)
- 0x34, 0x00, 0x00, // ldi 0000 (dummy)
+static const uint16 mothergoose256PatchReplay[] = {
+ 0x34, PATCH_UINT16(0x0000), // ldi 0000 (dummy)
+ 0x34, PATCH_UINT16(0x0000), // ldi 0000 (dummy)
PATCH_END
};
// when saving, it also checks if the savegame ID is below 13.
// we change this to check if below 113 instead
-const byte mothergoose256SignatureSaveLimit[] = {
- 5,
- 0x89, 0xb3, // lsg global[b3]
- 0x35, 0x0d, // ldi 0d
- 0x20, // ge?
- 0
+static const uint16 mothergoose256SignatureSaveLimit[] = {
+ 0x89, SIG_MAGICDWORD, 0xb3, // lsg global[b3]
+ 0x35, 0x0d, // ldi 0d
+ 0x20, // ge?
+ SIG_END
};
-const uint16 mothergoose256PatchSaveLimit[] = {
- PATCH_ADDTOOFFSET | +2,
+static const uint16 mothergoose256PatchSaveLimit[] = {
+ PATCH_ADDTOOFFSET(+2),
0x35, 0x0d + SAVEGAMEID_OFFICIALRANGE_START, // ldi 113d
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature mothergoose256Signatures[] = {
- { 0, "replay save issue", 1, PATCH_MAGICDWORD(0x20, 0x04, 0xa1, 0xb3), -2, mothergoose256SignatureReplay, mothergoose256PatchReplay },
- { 0, "save limit dialog (SCI1.1)", 1, PATCH_MAGICDWORD(0xb3, 0x35, 0x0d, 0x20), -1, mothergoose256SignatureSaveLimit, mothergoose256PatchSaveLimit },
- { 994, "save limit dialog (SCI1)", 1, PATCH_MAGICDWORD(0xb3, 0x35, 0x0d, 0x20), -1, mothergoose256SignatureSaveLimit, mothergoose256PatchSaveLimit },
+// script, description, signature patch
+static const SciScriptPatcherEntry mothergoose256Signatures[] = {
+ { true, 0, "replay save issue", 1, mothergoose256SignatureReplay, mothergoose256PatchReplay },
+ { true, 0, "save limit dialog (SCI1.1)", 1, mothergoose256SignatureSaveLimit, mothergoose256PatchSaveLimit },
+ { true, 994, "save limit dialog (SCI1)", 1, mothergoose256SignatureSaveLimit, mothergoose256PatchSaveLimit },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -971,55 +1830,89 @@ const SciScriptSignature mothergoose256Signatures[] = {
// SSCI.
// This patch changes the code, so that the gun is actually given away
// when the 2 seconds have passed and the locker got closed.
+// Applies to at least: English floppy
// Responsible method: putGun::changeState (script 341)
-// Fixes bug #3036933 / #3303802
-const byte pq1vgaSignaturePutGunInLockerBug[] = {
- 5,
- 0x35, 0x00, // ldi 00
- 0x1a, // eq?
- 0x31, 0x25, // bnt [next state check]
- +22, 29, // [skip 22 bytes]
- 0x38, 0x5f, 0x01, // pushi 15fh
- 0x78, // push1
- 0x76, // push0
- 0x81, 0x00, // lag 00
- 0x4a, 0x06, // send 06 - ego::put(0)
- 0x35, 0x02, // ldi 02
- 0x65, 0x1c, // aTop 1c (set timer to 2 seconds)
- 0x33, 0x0e, // jmp [end of method]
- 0x3c, // dup --- next state check target
- 0x35, 0x01, // ldi 01
- 0x1a, // eq?
- 0x31, 0x08, // bnt [end of method]
- 0x39, 0x6f, // pushi 6fh
- 0x76, // push0
- 0x72, 0x88, 0x00, // lofsa 0088
- 0x4a, 0x04, // send 04 - locker::dispose
- 0
+// Fixes bug: #5705 / #6400
+static const uint16 pq1vgaSignaturePutGunInLockerBug[] = {
+ 0x35, 0x00, // ldi 00
+ 0x1a, // eq?
+ 0x31, 0x25, // bnt [next state check]
+ SIG_ADDTOOFFSET(+22), // [skip 22 bytes]
+ SIG_MAGICDWORD,
+ 0x38, SIG_SELECTOR16(put), // pushi "put"
+ 0x78, // push1
+ 0x76, // push0
+ 0x81, 0x00, // lag 00
+ 0x4a, 0x06, // send 06 - ego::put(0)
+ 0x35, 0x02, // ldi 02
+ 0x65, 0x1c, // aTop 1c (set timer to 2 seconds)
+ 0x33, 0x0e, // jmp [end of method]
+ 0x3c, // dup --- next state check target
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x08, // bnt [end of method]
+ 0x39, SIG_SELECTOR8(dispose), // pushi "dispose"
+ 0x76, // push0
+ 0x72, SIG_UINT16(0x0088), // lofsa 0088
+ 0x4a, 0x04, // send 04 - locker::dispose
+ SIG_END
+};
+
+static const uint16 pq1vgaPatchPutGunInLockerBug[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x31, 0x1c, // bnt [next state check]
+ PATCH_ADDTOOFFSET(+22),
+ 0x35, 0x02, // ldi 02
+ 0x65, 0x1c, // aTop 1c (set timer to 2 seconds)
+ 0x33, 0x17, // jmp [end of method]
+ 0x3c, // dup --- next state check target
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x11, // bnt [end of method]
+ 0x38, PATCH_SELECTOR16(put), // pushi "put"
+ 0x78, // push1
+ 0x76, // push0
+ 0x81, 0x00, // lag 00
+ 0x4a, 0x06, // send 06 - ego::put(0)
+ PATCH_END
};
-const uint16 pq1vgaPatchPutGunInLockerBug[] = {
- PATCH_ADDTOOFFSET | +3,
- 0x31, 0x1c, // bnt [next state check]
- PATCH_ADDTOOFFSET | +22,
- 0x35, 0x02, // ldi 02
- 0x65, 0x1c, // aTop 1c (set timer to 2 seconds)
- 0x33, 0x17, // jmp [end of method]
- 0x3c, // dup --- next state check target
- 0x35, 0x01, // ldi 01
- 0x1a, // eq?
- 0x31, 0x11, // bnt [end of method]
- 0x38, 0x5f, 0x01, // pushi 15fh
- 0x78, // push1
- 0x76, // push0
- 0x81, 0x00, // lag 00
- 0x4a, 0x06, // send 06 - ego::put(0)
- PATCH_END
-};
-
-// script, description, magic DWORD, adjust
-const SciScriptSignature pq1vgaSignatures[] = {
- { 341, "put gun in locker bug", 1, PATCH_MAGICDWORD(0x38, 0x5f, 0x01, 0x78), -27, pq1vgaSignaturePutGunInLockerBug, pq1vgaPatchPutGunInLockerBug },
+// When restoring a saved game, which was made while driving around,
+// the game didn't redraw the map. This also happened in Sierra SCI.
+//
+// The map is a picture resource and drawn over the main picture.
+// This is called an "overlay" in SCI. This wasn't implemented properly.
+// We fix it by actually implementing it properly.
+//
+// Applies to at least: English floppy
+// Responsible method: rm500::init, changeOverlay::changeState (script 500)
+// Fixes bug: #5016
+static const uint16 pq1vgaSignatureMapSaveRestoreBug[] = {
+ 0x39, 0x04, // pushi 04
+ SIG_ADDTOOFFSET(+2), // skip either lsg global[f9] or pTos register
+ SIG_MAGICDWORD,
+ 0x38, 0x64, 0x80, // pushi 8064
+ 0x76, // push0
+ 0x89, 0x28, // lsg global[28]
+ 0x43, 0x08, 0x08, // kDrawPic (8)
+ SIG_END
+};
+
+static const uint16 pq1vgaPatchMapSaveRestoreBug[] = {
+ 0x38, PATCH_SELECTOR16(overlay), // pushi "overlay"
+ 0x7a, // push2
+ 0x89, 0xf9, // lsg global[f9]
+ 0x39, 0x64, // pushi 64 (no transition)
+ 0x81, 0x02, // lag global[02] (current room object)
+ 0x4a, 0x08, // send 08
+ 0x18, // not (waste byte)
+ PATCH_END
+};
+
+// script, description, signature patch
+static const SciScriptPatcherEntry pq1vgaSignatures[] = {
+ { true, 341, "put gun in locker bug", 1, pq1vgaSignaturePutGunInLockerBug, pq1vgaPatchPutGunInLockerBug },
+ { true, 500, "map save/restore bug", 2, pq1vgaSignatureMapSaveRestoreBug, pq1vgaPatchMapSaveRestoreBug },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -1032,43 +1925,45 @@ const SciScriptSignature pq1vgaSignatures[] = {
// not nearly as bad as in our sci, but these differences may be caused by
// timing.
// We just reuse the active event, thus removing the duplicate kGetEvent call.
-const byte qfg1vgaSignatureFightEvents[] = {
- 25,
- 0x39, 0x6d, // pushi 6d (selector new)
- 0x76, // push0
- 0x51, 0x07, // class Event
- 0x4a, 0x04, // send 04 - call Event::new
- 0xa5, 0x00, // sat temp[0]
- 0x78, // push1
- 0x76, // push0
- 0x4a, 0x04, // send 04 - read Event::x
- 0xa5, 0x03, // sat temp[3]
- 0x76, // push0 (selector y)
- 0x76, // push0
- 0x85, 0x00, // lat temp[0]
- 0x4a, 0x04, // send 04 - read Event::y
- 0x36, // push
- 0x35, 0x0a, // ldi 0a
- 0x04, // sub (poor mans localization) ;-)
- 0
-};
-
-const uint16 qfg1vgaPatchFightEvents[] = {
- 0x38, 0x5a, 0x01, // pushi 15a (selector curEvent)
- 0x76, // push0
- 0x81, 0x50, // lag global[50]
- 0x4a, 0x04, // send 04 - read User::curEvent -> needs one byte more than previous code
- 0xa5, 0x00, // sat temp[0]
- 0x78, // push1
- 0x76, // push0
- 0x4a, 0x04, // send 04 - read Event::x
- 0xa5, 0x03, // sat temp[3]
- 0x76, // push0 (selector y)
- 0x76, // push0
- 0x85, 0x00, // lat temp[0]
- 0x4a, 0x04, // send 04 - read Event::y
- 0x39, 0x00, // pushi 00
- 0x02, // add (waste 3 bytes) - we don't need localization, User::doit has already done it
+// Applies to at least: English floppy
+// Responsible method: pointBox::doit
+static const uint16 qfg1vgaSignatureFightEvents[] = {
+ 0x39, SIG_MAGICDWORD,
+ SIG_SELECTOR8(new), // pushi "new"
+ 0x76, // push0
+ 0x51, 0x07, // class Event
+ 0x4a, 0x04, // send 04 - call Event::new
+ 0xa5, 0x00, // sat temp[0]
+ 0x78, // push1
+ 0x76, // push0
+ 0x4a, 0x04, // send 04 - read Event::x
+ 0xa5, 0x03, // sat temp[3]
+ 0x76, // push0 (selector y)
+ 0x76, // push0
+ 0x85, 0x00, // lat temp[0]
+ 0x4a, 0x04, // send 04 - read Event::y
+ 0x36, // push
+ 0x35, 0x0a, // ldi 0a
+ 0x04, // sub (poor mans localization) ;-)
+ SIG_END
+};
+
+static const uint16 qfg1vgaPatchFightEvents[] = {
+ 0x38, PATCH_SELECTOR16(curEvent), // pushi 15a (selector curEvent)
+ 0x76, // push0
+ 0x81, 0x50, // lag global[50]
+ 0x4a, 0x04, // send 04 - read User::curEvent -> needs one byte more than previous code
+ 0xa5, 0x00, // sat temp[0]
+ 0x78, // push1
+ 0x76, // push0
+ 0x4a, 0x04, // send 04 - read Event::x
+ 0xa5, 0x03, // sat temp[3]
+ 0x76, // push0 (selector y)
+ 0x76, // push0
+ 0x85, 0x00, // lat temp[0]
+ 0x4a, 0x04, // send 04 - read Event::y
+ 0x39, 0x00, // pushi 00
+ 0x02, // add (waste 3 bytes) - we don't need localization, User::doit has already done it
PATCH_END
};
@@ -1079,31 +1974,31 @@ const uint16 qfg1vgaPatchFightEvents[] = {
// window text, which erases the window header text because of its length. To
// fix that, we allocate more temp space and move the pointer used for the
// window header a little bit, wherever it's used in script 814.
-// Fixes bug #3568431.
+// Fixes bug: #6139.
// Patch 1: Increase temp space
-const byte qfg1vgaSignatureTempSpace[] = {
- 4,
- 0x3f, 0xba, // link 0xba
- 0x87, 0x00, // lap 0
- 0
+static const uint16 qfg1vgaSignatureTempSpace[] = {
+ SIG_MAGICDWORD,
+ 0x3f, 0xba, // link 0xba
+ 0x87, 0x00, // lap 0
+ SIG_END
};
-const uint16 qfg1vgaPatchTempSpace[] = {
- 0x3f, 0xca, // link 0xca
+static const uint16 qfg1vgaPatchTempSpace[] = {
+ 0x3f, 0xca, // link 0xca
PATCH_END
};
// Patch 2: Move the pointer used for the window header a little bit
-const byte qfg1vgaSignatureDialogHeader[] = {
- 4,
- 0x5b, 0x04, 0x80, // lea temp[0x80]
- 0x36, // push
- 0
+static const uint16 qfg1vgaSignatureDialogHeader[] = {
+ SIG_MAGICDWORD,
+ 0x5b, 0x04, 0x80, // lea temp[0x80]
+ 0x36, // push
+ SIG_END
};
-const uint16 qfg1vgaPatchDialogHeader[] = {
- 0x5b, 0x04, 0x90, // lea temp[0x90]
+static const uint16 qfg1vgaPatchDialogHeader[] = {
+ 0x5b, 0x04, 0x90, // lea temp[0x90]
PATCH_END
};
@@ -1115,63 +2010,65 @@ const uint16 qfg1vgaPatchDialogHeader[] = {
// edge case that can occur when Ego is set to sneak. Normally, when clicking on
// the crusher, ego is supposed to move close to position 79, 165. We change it
// to 85, 165, which is not an edge case thus the freeze is avoided.
-// Fixes bug #3585189.
-const byte qfg1vgaSignatureMoveToCrusher[] = {
- 9,
- 0x51, 0x1f, // class Motion
- 0x36, // push
- 0x39, 0x4f, // pushi 4f (79 - x)
- 0x38, 0xa5, 0x00, // pushi 00a5 (165 - y)
- 0x7c, // pushSelf
- 0
-};
-
-const uint16 qfg1vgaPatchMoveToCrusher[] = {
- PATCH_ADDTOOFFSET | +3,
- 0x39, 0x55, // pushi 55 (85 - x)
+// Fixes bug: #6180
+static const uint16 qfg1vgaSignatureMoveToCrusher[] = {
+ SIG_MAGICDWORD,
+ 0x51, 0x1f, // class Motion
+ 0x36, // push
+ 0x39, 0x4f, // pushi 4f (79 - x)
+ 0x38, SIG_UINT16(0x00a5), // pushi 00a5 (165 - y)
+ 0x7c, // pushSelf
+ SIG_END
+};
+
+static const uint16 qfg1vgaPatchMoveToCrusher[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x39, 0x55, // pushi 55 (85 - x)
PATCH_END
};
// Same pathfinding bug as above, where Ego is set to move to an impossible
// spot when sneaking. In GuardsTrumpet::changeState, we change the final
-// location where Ego is moved from 111, 111 to 114, 114. Fixes bug #3604939.
-const byte qfg1vgaSignatureMoveToCastleGate[] = {
- 7,
- 0x51, 0x1f, // class MoveTo
- 0x36, // push
- 0x39, 0x6f, // pushi 6f (111 - x)
- 0x3c, // dup (111 - y)
- 0x7c, // pushSelf
- 0
-};
-
-const uint16 qfg1vgaPatchMoveToCastleGate[] = {
- PATCH_ADDTOOFFSET | +3,
- 0x39, 0x72, // pushi 72 (114 - x)
+// location where Ego is moved from 111, 111 to 114, 114.
+// Fixes bug: #6248
+static const uint16 qfg1vgaSignatureMoveToCastleGate[] = {
+ SIG_MAGICDWORD,
+ 0x51, 0x1f, // class MoveTo
+ 0x36, // push
+ 0x39, 0x6f, // pushi 6f (111 - x)
+ 0x3c, // dup (111 - y)
+ 0x7c, // pushSelf
+ SIG_END
+};
+
+static const uint16 qfg1vgaPatchMoveToCastleGate[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x39, 0x72, // pushi 72 (114 - x)
PATCH_END
};
// Typo in the original Sierra scripts
// Looking at a cheetaur resulted in a text about a Saurus Rex
// The code treats both monster types the same.
+// Applies to at least: English floppy
// Responsible method: smallMonster::doVerb
-// Fixes bug #3604943.
-const byte qfg1vgaSignatureCheetaurDescription[] = {
- 16,
- 0x34, 0xb8, 0x01, // ldi 01b8
- 0x1a, // eq?
- 0x31, 0x16, // bnt 16
- 0x38, 0x27, 0x01, // pushi 0127
- 0x39, 0x06, // pushi 06
- 0x39, 0x03, // pushi 03
- 0x78, // push1
- 0x39, 0x12, // pushi 12 -> monster type Saurus Rex
- 0
-};
-
-const uint16 qfg1vgaPatchCheetaurDescription[] = {
- PATCH_ADDTOOFFSET | +14,
- 0x39, 0x11, // pushi 11 -> monster type cheetaur
+// Fixes bug #6249
+static const uint16 qfg1vgaSignatureCheetaurDescription[] = {
+ SIG_MAGICDWORD,
+ 0x34, SIG_UINT16(0x01b8), // ldi 01b8
+ 0x1a, // eq?
+ 0x31, 0x16, // bnt 16
+ 0x38, SIG_UINT16(0x0127), // pushi 0127
+ 0x39, 0x06, // pushi 06
+ 0x39, 0x03, // pushi 03
+ 0x78, // push1
+ 0x39, 0x12, // pushi 12 -> monster type Saurus Rex
+ SIG_END
+};
+
+static const uint16 qfg1vgaPatchCheetaurDescription[] = {
+ PATCH_ADDTOOFFSET(+14),
+ 0x39, 0x11, // pushi 11 -> monster type cheetaur
PATCH_END
};
@@ -1185,41 +2082,42 @@ const uint16 qfg1vgaPatchCheetaurDescription[] = {
// Local 5 of that room is a timer, that closes the door (object door11).
// Setting it to 1 during happyFace::changeState(0) stops door11::doit from
// calling goTo6::init, so the whole issue is stopped from happening.
+// Applies to at least: English floppy
// Responsible method: happyFace::changeState, door11::doit
-// Fixes bug #3585793
-const byte qfg1vgaSignatureFunnyRoomFix[] = {
- 14,
- 0x65, 0x14, // aTop 14 (state)
- 0x36, // push
- 0x3c, // dup
- 0x35, 0x00, // ldi 00
- 0x1a, // eq?
- 0x30, 0x25, 0x00, // bnt 0025 [-> next state]
- 0x35, 0x01, // ldi 01
- 0xa3, 0x4e, // sal 4e
- 0
-};
-
-const uint16 qfg1vgaPatchFunnyRoomFix[] = {
- PATCH_ADDTOOFFSET | +3,
- 0x2e, 0x29, 0x00, // bt 0029 [-> next state] - saves 4 bytes
- 0x35, 0x01, // ldi 01
- 0xa3, 0x4e, // sal 4e
- 0xa3, 0x05, // sal 05 (sets local 5 to 1)
- 0xa3, 0x05, // and again to make absolutely sure (actually to waste 2 bytes)
+// Fixes bug #6181
+static const uint16 qfg1vgaSignatureFunnyRoomFix[] = {
+ 0x65, 0x14, // aTop 14 (state)
+ 0x36, // push
+ 0x3c, // dup
+ 0x35, 0x00, // ldi 00
+ 0x1a, // eq?
+ 0x30, SIG_UINT16(0x0025), // bnt 0025 [-> next state]
+ SIG_MAGICDWORD,
+ 0x35, 0x01, // ldi 01
+ 0xa3, 0x4e, // sal 4e
+ SIG_END
+};
+
+static const uint16 qfg1vgaPatchFunnyRoomFix[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x2e, PATCH_UINT16(0x0029), // bt 0029 [-> next state] - saves 4 bytes
+ 0x35, 0x01, // ldi 01
+ 0xa3, 0x4e, // sal 4e
+ 0xa3, 0x05, // sal 05 (sets local 5 to 1)
+ 0xa3, 0x05, // and again to make absolutely sure (actually to waste 2 bytes)
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature qfg1vgaSignatures[] = {
- { 215, "fight event issue", 1, PATCH_MAGICDWORD(0x6d, 0x76, 0x51, 0x07), -1, qfg1vgaSignatureFightEvents, qfg1vgaPatchFightEvents },
- { 216, "weapon master event issue", 1, PATCH_MAGICDWORD(0x6d, 0x76, 0x51, 0x07), -1, qfg1vgaSignatureFightEvents, qfg1vgaPatchFightEvents },
- { 814, "window text temp space", 1, PATCH_MAGICDWORD(0x3f, 0xba, 0x87, 0x00), 0, qfg1vgaSignatureTempSpace, qfg1vgaPatchTempSpace },
- { 814, "dialog header offset", 3, PATCH_MAGICDWORD(0x5b, 0x04, 0x80, 0x36), 0, qfg1vgaSignatureDialogHeader, qfg1vgaPatchDialogHeader },
- { 331, "moving to crusher", 1, PATCH_MAGICDWORD(0x51, 0x1f, 0x36, 0x39), 0, qfg1vgaSignatureMoveToCrusher, qfg1vgaPatchMoveToCrusher },
- { 41, "moving to castle gate", 1, PATCH_MAGICDWORD(0x51, 0x1f, 0x36, 0x39), 0, qfg1vgaSignatureMoveToCastleGate, qfg1vgaPatchMoveToCastleGate },
- { 210, "cheetaur description fixed", 1, PATCH_MAGICDWORD(0x34, 0xb8, 0x01, 0x1a), 0, qfg1vgaSignatureCheetaurDescription, qfg1vgaPatchCheetaurDescription },
- { 96, "funny room script bug fixed", 1, PATCH_MAGICDWORD(0x35, 0x01, 0xa3, 0x4e), -10, qfg1vgaSignatureFunnyRoomFix, qfg1vgaPatchFunnyRoomFix },
+// script, description, signature patch
+static const SciScriptPatcherEntry qfg1vgaSignatures[] = {
+ { true, 215, "fight event issue", 1, qfg1vgaSignatureFightEvents, qfg1vgaPatchFightEvents },
+ { true, 216, "weapon master event issue", 1, qfg1vgaSignatureFightEvents, qfg1vgaPatchFightEvents },
+ { true, 814, "window text temp space", 1, qfg1vgaSignatureTempSpace, qfg1vgaPatchTempSpace },
+ { true, 814, "dialog header offset", 3, qfg1vgaSignatureDialogHeader, qfg1vgaPatchDialogHeader },
+ { true, 331, "moving to crusher", 1, qfg1vgaSignatureMoveToCrusher, qfg1vgaPatchMoveToCrusher },
+ { true, 41, "moving to castle gate", 1, qfg1vgaSignatureMoveToCastleGate, qfg1vgaPatchMoveToCastleGate },
+ { true, 210, "cheetaur description fixed", 1, qfg1vgaSignatureCheetaurDescription, qfg1vgaPatchCheetaurDescription },
+ { true, 96, "funny room script bug fixed", 1, qfg1vgaSignatureFunnyRoomFix, qfg1vgaPatchFunnyRoomFix },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -1235,58 +2133,56 @@ const SciScriptSignature qfg1vgaSignatures[] = {
// deleted entries. We don't allow the user to change the directory, thus the
// contents of the file list are constant, so we can avoid the constant file
// and text entry refreshes whenever a button is pressed, and prevent possible
-// crashes because of these constant quick object reallocations. Fixes bug
-// #3037996.
-const byte qfg2SignatureImportDialog[] = {
- 16,
- 0x63, 0x20, // pToa text
- 0x30, 0x0b, 0x00, // bnt [next state]
- 0x7a, // push2
- 0x39, 0x03, // pushi 03
- 0x36, // push
- 0x43, 0x72, 0x04, // callk Memory 4
- 0x35, 0x00, // ldi 00
- 0x65, 0x20, // aTop text
- 0
-};
-
-const uint16 qfg2PatchImportDialog[] = {
- PATCH_ADDTOOFFSET | +5,
- 0x48, // ret
+// crashes because of these constant quick object reallocations.
+// Fixes bug: #5096
+static const uint16 qfg2SignatureImportDialog[] = {
+ 0x63, SIG_MAGICDWORD, 0x20, // pToa text
+ 0x30, SIG_UINT16(0x000b), // bnt [next state]
+ 0x7a, // push2
+ 0x39, 0x03, // pushi 03
+ 0x36, // push
+ 0x43, 0x72, 0x04, // callk Memory 4
+ 0x35, 0x00, // ldi 00
+ 0x65, 0x20, // aTop text
+ SIG_END
+};
+
+static const uint16 qfg2PatchImportDialog[] = {
+ PATCH_ADDTOOFFSET(+5),
+ 0x48, // ret
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature qfg2Signatures[] = {
- { 944, "import dialog continuous calls", 1, PATCH_MAGICDWORD(0x20, 0x30, 0x0b, 0x00), -1, qfg2SignatureImportDialog, qfg2PatchImportDialog },
+// script, description, signature patch
+static const SciScriptPatcherEntry qfg2Signatures[] = {
+ { true, 944, "import dialog continuous calls", 1, qfg2SignatureImportDialog, qfg2PatchImportDialog },
SCI_SIGNATUREENTRY_TERMINATOR
};
// ===========================================================================
// Patch for the import screen in QFG3, same as the one for QFG2 above
-const byte qfg3SignatureImportDialog[] = {
- 15,
- 0x63, 0x2a, // pToa text
- 0x31, 0x0b, // bnt [next state]
- 0x7a, // push2
- 0x39, 0x03, // pushi 03
- 0x36, // push
- 0x43, 0x72, 0x04, // callk Memory 4
- 0x35, 0x00, // ldi 00
- 0x65, 0x2a, // aTop text
- 0
-};
-
-const uint16 qfg3PatchImportDialog[] = {
- PATCH_ADDTOOFFSET | +4,
- 0x48, // ret
+static const uint16 qfg3SignatureImportDialog[] = {
+ 0x63, SIG_MAGICDWORD, 0x2a, // pToa text
+ 0x31, 0x0b, // bnt [next state]
+ 0x7a, // push2
+ 0x39, 0x03, // pushi 03
+ 0x36, // push
+ 0x43, 0x72, 0x04, // callk Memory 4
+ 0x35, 0x00, // ldi 00
+ 0x65, 0x2a, // aTop text
+ SIG_END
+};
+
+static const uint16 qfg3PatchImportDialog[] = {
+ PATCH_ADDTOOFFSET(+4),
+ 0x48, // ret
PATCH_END
};
// ===========================================================================
-// Patch for the Woo dialog option in Uhura's conversation. Bug #3040722
+// Patch for the Woo dialog option in Uhura's conversation.
// Problem: The Woo dialog option (0xffb5) is negative, and therefore
// treated as an option opening a submenu. This leads to uhuraTell::doChild
// being called, which calls hero::solvePuzzle and then proceeds with
@@ -1298,38 +2194,40 @@ const uint16 qfg3PatchImportDialog[] = {
// hero::solvePuzzle (0xfffc) which does a ret afterwards without going to
// Teller::doChild. We jump to this call of hero::solvePuzzle to get that same
// behaviour.
-
-const byte qfg3SignatureWooDialog[] = {
- 30,
- 0x67, 0x12, // pTos 12 (query)
- 0x35, 0xb6, // ldi b6
- 0x1a, // eq?
- 0x2f, 0x05, // bt 05
- 0x67, 0x12, // pTos 12 (query)
- 0x35, 0x9b, // ldi 9b
- 0x1a, // eq?
- 0x31, 0x0c, // bnt 0c
- 0x38, 0x97, 0x02, // pushi 0297
- 0x7a, // push2
- 0x38, 0x0c, 0x01, // pushi 010c
- 0x7a, // push2
- 0x81, 0x00, // lag 00
- 0x4a, 0x08, // send 08
- 0x67, 0x12, // pTos 12 (query)
- 0x35, 0xb5, // ldi b5
- 0
-};
-
-const uint16 qfg3PatchWooDialog[] = {
- PATCH_ADDTOOFFSET | +0x29,
- 0x33, 0x11, // jmp to 0x6a2, the call to hero::solvePuzzle for 0xFFFC
+// Applies to at least: English, German, Italian, French, Spanish Floppy
+// Responsible method: unknown
+// Fixes bug: #5172
+static const uint16 qfg3SignatureWooDialog[] = {
+ SIG_MAGICDWORD,
+ 0x67, 0x12, // pTos 12 (query)
+ 0x35, 0xb6, // ldi b6
+ 0x1a, // eq?
+ 0x2f, 0x05, // bt 05
+ 0x67, 0x12, // pTos 12 (query)
+ 0x35, 0x9b, // ldi 9b
+ 0x1a, // eq?
+ 0x31, 0x0c, // bnt 0c
+ 0x38, SIG_SELECTOR16(solvePuzzle), // pushi 0297
+ 0x7a, // push2
+ 0x38, SIG_UINT16(0x010c), // pushi 010c
+ 0x7a, // push2
+ 0x81, 0x00, // lag 00
+ 0x4a, 0x08, // send 08
+ 0x67, 0x12, // pTos 12 (query)
+ 0x35, 0xb5, // ldi b5
+ SIG_END
+};
+
+static const uint16 qfg3PatchWooDialog[] = {
+ PATCH_ADDTOOFFSET(+0x29),
+ 0x33, 0x11, // jmp to 0x6a2, the call to hero::solvePuzzle for 0xFFFC
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature qfg3Signatures[] = {
- { 944, "import dialog continuous calls", 1, PATCH_MAGICDWORD(0x2a, 0x31, 0x0b, 0x7a), -1, qfg3SignatureImportDialog, qfg3PatchImportDialog },
- { 440, "dialog crash when asking about Woo", 1, PATCH_MAGICDWORD(0x67, 0x12, 0x35, 0xb5), -26, qfg3SignatureWooDialog, qfg3PatchWooDialog },
+// script, description, signature patch
+static const SciScriptPatcherEntry qfg3Signatures[] = {
+ { true, 944, "import dialog continuous calls", 1, qfg3SignatureImportDialog, qfg3PatchImportDialog },
+ { true, 440, "dialog crash when asking about Woo", 1, qfg3SignatureWooDialog, qfg3PatchWooDialog },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -1339,31 +2237,53 @@ const SciScriptSignature qfg3Signatures[] = {
// adds it to nest::x. The problem is that the script also checks if x exceeds
// we never reach that of course, so the pterodactyl-flight will go endlessly
// we could either calculate property count differently somehow fixing this
-// but I think just patching it out is cleaner (bug #3037938)
-const byte sq4FloppySignatureEndlessFlight[] = {
- 8,
- 0x39, 0x04, // pushi 04 (selector x)
- 0x78, // push1
- 0x67, 0x08, // pTos 08 (property x)
- 0x63, 0x44, // pToa 44 (invalid property)
- 0x02, // add
- 0
-};
-
-// Similar to the above, for the German version (bug #3110215)
-const byte sq4FloppySignatureEndlessFlightGerman[] = {
- 8,
- 0x39, 0x04, // pushi 04 (selector x)
- 0x78, // push1
- 0x67, 0x08, // pTos 08 (property x)
- 0x63, 0x4c, // pToa 4c (invalid property)
- 0x02, // add
- 0
+// but I think just patching it out is cleaner.
+// Fixes bug: #5093
+static const uint16 sq4FloppySignatureEndlessFlight[] = {
+ 0x39, 0x04, // pushi 04 (selector x)
+ SIG_MAGICDWORD,
+ 0x78, // push1
+ 0x67, 0x08, // pTos 08 (property x)
+ 0x63, SIG_ADDTOOFFSET(+1), // pToa (invalid property) - 44h for English floppy, 4ch for German floppy
+ 0x02, // add
+ SIG_END
+};
+
+static const uint16 sq4FloppyPatchEndlessFlight[] = {
+ PATCH_ADDTOOFFSET(+5),
+ 0x35, 0x03, // ldi 03 (which would be the content of the property)
+ PATCH_END
};
-const uint16 sq4FloppyPatchEndlessFlight[] = {
- PATCH_ADDTOOFFSET | +5,
- 0x35, 0x03, // ldi 03 (which would be the content of the property)
+// Floppy-only: When the player tries to throw something at the sequel police in Space Quest X (zero g zone),
+// the game will first show a textbox and then cause a signature mismatch in ScummVM/
+// crash the whole game in Sierra SCI/display garbage (the latter when the Sierra "patch" got applied).
+//
+// All of this is caused by a typo in the script. Right after the code for showing the textbox,
+// there is more similar code for showing another textbox, but without a pointer to the text.
+// This has to be a typo, because there is no unused text to be found within that script.
+//
+// Sierra's "patch" didn't include a proper fix (as in a modified script). Instead they shipped a dummy
+// text resource, which somewhat "solved" the issue in Sierra SCI, but it still showed another textbox
+// with garbage in it. Funnily Sierra must have known that, because that new text resource contains:
+// "Hi! This is a kludge!"
+//
+// We properly fix it by removing the faulty code.
+// Applies to at least: English Floppy
+// Responsible method: sp1::doVerb
+// Fixes bug: found by SCI developer
+static const uint16 sq4FloppySignatureThrowStuffAtSequelPoliceBug[] = {
+ 0x47, 0xff, 0x00, 0x02, // call export 255_0, 2
+ 0x3a, // toss
+ SIG_MAGICDWORD,
+ 0x36, // push
+ 0x47, 0xff, 0x00, 0x02, // call export 255_0, 2
+ SIG_END
+};
+
+static const uint16 sq4FloppyPatchThrowStuffAtSequelPoliceBug[] = {
+ PATCH_ADDTOOFFSET(+5),
+ 0x48, // ret
PATCH_END
};
@@ -1373,40 +2293,40 @@ const uint16 sq4FloppyPatchEndlessFlight[] = {
// Patch 1: iconTextSwitch::show, called when the text options button is shown.
// This is patched to add the "Both" text resource (i.e. we end up with
// "Speech", "Text" and "Both")
-const byte sq4CdSignatureTextOptionsButton[] = {
- 11,
- 0x35, 0x01, // ldi 0x01
- 0xa1, 0x53, // sag 0x53
- 0x39, 0x03, // pushi 0x03
- 0x78, // push1
- 0x39, 0x09, // pushi 0x09
- 0x54, 0x06, // self 0x06
- 0
-};
-
-const uint16 sq4CdPatchTextOptionsButton[] = {
- PATCH_ADDTOOFFSET | +7,
- 0x39, 0x0b, // pushi 0x0b
+static const uint16 sq4CdSignatureTextOptionsButton[] = {
+ SIG_MAGICDWORD,
+ 0x35, 0x01, // ldi 0x01
+ 0xa1, 0x53, // sag 0x53
+ 0x39, 0x03, // pushi 0x03
+ 0x78, // push1
+ 0x39, 0x09, // pushi 0x09
+ 0x54, 0x06, // self 0x06
+ SIG_END
+};
+
+static const uint16 sq4CdPatchTextOptionsButton[] = {
+ PATCH_ADDTOOFFSET(+7),
+ 0x39, 0x0b, // pushi 0x0b
PATCH_END
};
// Patch 2: Adjust a check in babbleIcon::init, which handles the babble icon
// (e.g. the two guys from Andromeda) shown when dying/quitting.
-// Fixes bug #3538418.
-const byte sq4CdSignatureBabbleIcon[] = {
- 7,
- 0x89, 0x5a, // lsg 5a
- 0x35, 0x02, // ldi 02
- 0x1a, // eq?
- 0x31, 0x26, // bnt 26 [02a7]
- 0
-};
-
-const uint16 sq4CdPatchBabbleIcon[] = {
- 0x89, 0x5a, // lsg 5a
- 0x35, 0x01, // ldi 01
- 0x1a, // eq?
- 0x2f, 0x26, // bt 26 [02a7]
+// Fixes bug: #6068
+static const uint16 sq4CdSignatureBabbleIcon[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg 5a
+ 0x35, 0x02, // ldi 02
+ 0x1a, // eq?
+ 0x31, 0x26, // bnt 26 [02a7]
+ SIG_END
+};
+
+static const uint16 sq4CdPatchBabbleIcon[] = {
+ 0x89, 0x5a, // lsg 5a
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x2f, 0x26, // bt 26 [02a7]
PATCH_END
};
@@ -1414,56 +2334,56 @@ const uint16 sq4CdPatchBabbleIcon[] = {
// when the text options button is clicked: "Speech", "Text" and "Both".
// Refer to the patch above for additional details.
// iconTextSwitch::doit (called when the text options button is clicked)
-const byte sq4CdSignatureTextOptions[] = {
- 32,
- 0x89, 0x5a, // lsg 0x5a (load global 90 to stack)
- 0x3c, // dup
- 0x35, 0x01, // ldi 0x01
- 0x1a, // eq? (global 90 == 1)
- 0x31, 0x06, // bnt 0x06 (0x0691)
- 0x35, 0x02, // ldi 0x02
- 0xa1, 0x5a, // sag 0x5a (save acc to global 90)
- 0x33, 0x0a, // jmp 0x0a (0x69b)
- 0x3c, // dup
- 0x35, 0x02, // ldi 0x02
- 0x1a, // eq? (global 90 == 2)
- 0x31, 0x04, // bnt 0x04 (0x069b)
- 0x35, 0x01, // ldi 0x01
- 0xa1, 0x5a, // sag 0x5a (save acc to global 90)
- 0x3a, // toss
- 0x38, 0xd9, 0x00, // pushi 0x00d9
- 0x76, // push0
- 0x54, 0x04, // self 0x04
- 0x48, // ret
- 0
-};
-
-const uint16 sq4CdPatchTextOptions[] = {
- 0x89, 0x5a, // lsg 0x5a (load global 90 to stack)
- 0x3c, // dup
- 0x35, 0x03, // ldi 0x03 (acc = 3)
- 0x1a, // eq? (global 90 == 3)
- 0x2f, 0x07, // bt 0x07
- 0x89, 0x5a, // lsg 0x5a (load global 90 to stack again)
- 0x35, 0x01, // ldi 0x01 (acc = 1)
- 0x02, // add: acc = global 90 (on stack) + 1 (previous acc value)
- 0x33, 0x02, // jmp 0x02
- 0x35, 0x01, // ldi 0x01 (reset acc to 1)
- 0xa1, 0x5a, // sag 0x5a (save acc to global 90)
- 0x33, 0x03, // jmp 0x03 (jump over the wasted bytes below)
- 0x34, 0x00, 0x00, // ldi 0x0000 (waste 3 bytes)
- 0x3a, // toss
+static const uint16 sq4CdSignatureTextOptions[] = {
+ SIG_MAGICDWORD,
+ 0x89, 0x5a, // lsg 0x5a (load global 90 to stack)
+ 0x3c, // dup
+ 0x35, 0x01, // ldi 0x01
+ 0x1a, // eq? (global 90 == 1)
+ 0x31, 0x06, // bnt 0x06 (0x0691)
+ 0x35, 0x02, // ldi 0x02
+ 0xa1, 0x5a, // sag 0x5a (save acc to global 90)
+ 0x33, 0x0a, // jmp 0x0a (0x69b)
+ 0x3c, // dup
+ 0x35, 0x02, // ldi 0x02
+ 0x1a, // eq? (global 90 == 2)
+ 0x31, 0x04, // bnt 0x04 (0x069b)
+ 0x35, 0x01, // ldi 0x01
+ 0xa1, 0x5a, // sag 0x5a (save acc to global 90)
+ 0x3a, // toss
+ 0x38, SIG_SELECTOR16(show), // pushi 0x00d9
+ 0x76, // push0
+ 0x54, 0x04, // self 0x04
+ 0x48, // ret
+ SIG_END
+};
+
+static const uint16 sq4CdPatchTextOptions[] = {
+ 0x89, 0x5a, // lsg 0x5a (load global 90 to stack)
+ 0x3c, // dup
+ 0x35, 0x03, // ldi 0x03 (acc = 3)
+ 0x1a, // eq? (global 90 == 3)
+ 0x2f, 0x07, // bt 0x07
+ 0x89, 0x5a, // lsg 0x5a (load global 90 to stack again)
+ 0x35, 0x01, // ldi 0x01 (acc = 1)
+ 0x02, // add: acc = global 90 (on stack) + 1 (previous acc value)
+ 0x33, 0x02, // jmp 0x02
+ 0x35, 0x01, // ldi 0x01 (reset acc to 1)
+ 0xa1, 0x5a, // sag 0x5a (save acc to global 90)
+ 0x33, 0x03, // jmp 0x03 (jump over the wasted bytes below)
+ 0x34, PATCH_UINT16(0x0000), // ldi 0x0000 (waste 3 bytes)
+ 0x3a, // toss
// (the rest of the code is the same)
PATCH_END
};
-// script, description, magic DWORD, adjust
-const SciScriptSignature sq4Signatures[] = {
- { 298, "Floppy: endless flight", 1, PATCH_MAGICDWORD(0x67, 0x08, 0x63, 0x44), -3, sq4FloppySignatureEndlessFlight, sq4FloppyPatchEndlessFlight },
- { 298, "Floppy (German): endless flight", 1, PATCH_MAGICDWORD(0x67, 0x08, 0x63, 0x4c), -3, sq4FloppySignatureEndlessFlightGerman, sq4FloppyPatchEndlessFlight },
- { 818, "CD: Speech and subtitles option", 1, PATCH_MAGICDWORD(0x89, 0x5a, 0x3c, 0x35), 0, sq4CdSignatureTextOptions, sq4CdPatchTextOptions },
- { 0, "CD: Babble icon speech and subtitles fix", 1, PATCH_MAGICDWORD(0x89, 0x5a, 0x35, 0x02), 0, sq4CdSignatureBabbleIcon, sq4CdPatchBabbleIcon },
- { 818, "CD: Speech and subtitles option button", 1, PATCH_MAGICDWORD(0x35, 0x01, 0xa1, 0x53), 0, sq4CdSignatureTextOptionsButton, sq4CdPatchTextOptionsButton },
+// script, description, signature patch
+static const SciScriptPatcherEntry sq4Signatures[] = {
+ { true, 298, "Floppy: endless flight", 1, sq4FloppySignatureEndlessFlight, sq4FloppyPatchEndlessFlight },
+ { true, 700, "Floppy: throw stuff at sequel police bug", 1, sq4FloppySignatureThrowStuffAtSequelPoliceBug, sq4FloppyPatchThrowStuffAtSequelPoliceBug },
+ { true, 818, "CD: Speech and subtitles option", 1, sq4CdSignatureTextOptions, sq4CdPatchTextOptions },
+ { true, 0, "CD: Babble icon speech and subtitles fix", 1, sq4CdSignatureBabbleIcon, sq4CdPatchBabbleIcon },
+ { true, 818, "CD: Speech and subtitles option button", 1, sq4CdSignatureTextOptionsButton, sq4CdPatchTextOptionsButton },
SCI_SIGNATUREENTRY_TERMINATOR
};
@@ -1478,75 +2398,234 @@ const SciScriptSignature sq4Signatures[] = {
// The same issue happens in Sierra SCI.
// We simply set the correct starting cel number to fix the bug.
// Responsible method: robotIntoShip::changeState(9)
-const byte sq1vgaSignatureUlenceFlatsTimepodGfxGlitch[] = {
- 8,
- 0x39, 0x07, // pushi 07 (ship::cel)
- 0x78, // push1
- 0x39, 0x0a, // pushi 0x0a (set ship::cel to 10)
- 0x38, 0xa0, 0x00, // pushi 0x00a0 (ship::setLoop)
- 0
+static const uint16 sq1vgaSignatureUlenceFlatsTimepodGfxGlitch[] = {
+ 0x39,
+ SIG_MAGICDWORD, SIG_SELECTOR8(cel), // pushi "cel"
+ 0x78, // push1
+ 0x39, 0x0a, // pushi 0x0a (set ship::cel to 10)
+ 0x38, SIG_UINT16(0x00a0), // pushi 0x00a0 (ship::setLoop)
+ SIG_END
+};
+
+static const uint16 sq1vgaPatchUlenceFlatsTimepodGfxGlitch[] = {
+ PATCH_ADDTOOFFSET(+3),
+ 0x39, 0x09, // pushi 0x09 (set ship::cel to 9)
+ PATCH_END
};
-const uint16 sq1vgaPatchUlenceFlatsTimepodGfxGlitch[] = {
- PATCH_ADDTOOFFSET | +3,
- 0x39, 0x09, // pushi 0x09 (set ship::cel to 9)
- PATCH_END
-};
-
-const byte sq1vgaSignatureEgoShowsCard[] = {
- 25,
- 0x38, 0x46, 0x02, // push 0x246 (set up send frame to set timesShownID)
- 0x78, // push1
- 0x38, 0x46, 0x02, // push 0x246 (set up send frame to get timesShownID)
- 0x76, // push0
- 0x51, 0x7c, // class DeltaurRegion
- 0x4a, 0x04, // send 0x04 (get timesShownID)
- 0x36, // push
- 0x35, 0x01, // ldi 1
- 0x02, // add
- 0x36, // push
- 0x51, 0x7c, // class DeltaurRegion
- 0x4a, 0x06, // send 0x06 (set timesShownID)
- 0x36, // push (wrong, acc clobbered by class, above)
- 0x35, 0x03, // ldi 0x03
- 0x22, // lt?
- 0
+static const uint16 sq1vgaSignatureEgoShowsCard[] = {
+ SIG_MAGICDWORD,
+ 0x38, SIG_SELECTOR16(timesShownID), // push "timesShownID"
+ 0x78, // push1
+ 0x38, SIG_SELECTOR16(timesShownID), // push "timesShownID"
+ 0x76, // push0
+ 0x51, 0x7c, // class DeltaurRegion
+ 0x4a, 0x04, // send 0x04 (get timesShownID)
+ 0x36, // push
+ 0x35, 0x01, // ldi 1
+ 0x02, // add
+ 0x36, // push
+ 0x51, 0x7c, // class DeltaurRegion
+ 0x4a, 0x06, // send 0x06 (set timesShownID)
+ 0x36, // push (wrong, acc clobbered by class, above)
+ 0x35, 0x03, // ldi 0x03
+ 0x22, // lt?
+ SIG_END
};
// Note that this script patch is merely a reordering of the
// instructions in the original script.
-const uint16 sq1vgaPatchEgoShowsCard[] = {
- 0x38, 0x46, 0x02, // push 0x246 (set up send frame to get timesShownID)
- 0x76, // push0
- 0x51, 0x7c, // class DeltaurRegion
- 0x4a, 0x04, // send 0x04 (get timesShownID)
- 0x36, // push
- 0x35, 0x01, // ldi 1
- 0x02, // add
- 0x36, // push (this push corresponds to the wrong one above)
- 0x38, 0x46, 0x02, // push 0x246 (set up send frame to set timesShownID)
- 0x78, // push1
- 0x36, // push
- 0x51, 0x7c, // class DeltaurRegion
- 0x4a, 0x06, // send 0x06 (set timesShownID)
- 0x35, 0x03, // ldi 0x03
- 0x22, // lt?
+static const uint16 sq1vgaPatchEgoShowsCard[] = {
+ 0x38, PATCH_SELECTOR16(timesShownID), // push "timesShownID"
+ 0x76, // push0
+ 0x51, 0x7c, // class DeltaurRegion
+ 0x4a, 0x04, // send 0x04 (get timesShownID)
+ 0x36, // push
+ 0x35, 0x01, // ldi 1
+ 0x02, // add
+ 0x36, // push (this push corresponds to the wrong one above)
+ 0x38, PATCH_SELECTOR16(timesShownID), // push "timesShownID"
+ 0x78, // push1
+ 0x36, // push
+ 0x51, 0x7c, // class DeltaurRegion
+ 0x4a, 0x06, // send 0x06 (set timesShownID)
+ 0x35, 0x03, // ldi 0x03
+ 0x22, // lt?
PATCH_END
};
+// The spider droid on planet Korona has a fixed movement speed,
+// which is way faster than the default movement speed of ego.
+// This means that the player would have to turn up movement speed,
+// otherwise it will be impossible to escape it.
+// We fix this issue by making the droid move a bit slower than ego
+// does (relative to movement speed setting).
+//
+// Applies to at least: English PC floppy
+// Responsible method: spider::doit
+static const uint16 sq1vgaSignatureSpiderDroidTiming[] = {
+ SIG_MAGICDWORD,
+ 0x63, 0x4e, // pToa script
+ 0x30, SIG_UINT16(0x0005), // bnt [further method code]
+ 0x35, 0x00, // ldi 00
+ 0x32, SIG_UINT16(0x0062), // jmp [super-call]
+ 0x38, SIG_UINT16(0x0088), // pushi 0088h (script)
+ 0x76, // push0
+ 0x81, 0x02, // lag global[2] (current room)
+ 0x4a, 0x04, // send 04 (get [current room].script)
+ 0x30, SIG_UINT16(0x0005), // bnt [further method code]
+ 0x35, 0x00, // ldi 00
+ 0x32, SIG_UINT16(0x0052), // jmp [super-call]
+ 0x89, 0xa6, // lsg global[a6]
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x30, SIG_UINT16(0x0012), // bnt [2nd code], in case global A6 <> 1
+ 0x81, 0xb5, // lag global[b5]
+ 0x30, SIG_UINT16(0x000d), // bnt [2nd code], in case global B5 == 0
+ 0x38, SIG_UINT16(0x008c), // pushi 008c
+ 0x78, // push1
+ 0x72, SIG_UINT16(0x1cb6), // lofsa 1CB6 (moveToPath)
+ 0x36, // push
+ 0x54, 0x06, // self 06
+ 0x32, SIG_UINT16(0x0038), // jmp [super-call]
+ 0x81, 0xb5, // lag global[B5]
+ 0x18, // not
+ 0x30, SIG_UINT16(0x0032), // bnt [super-call], in case global B5 <> 0
+ SIG_END
+}; // 58 bytes)
+
+static const uint16 sq1vgaPatchSpiderDroidTiming[] = {
+ 0x63, 0x4e, // pToa script
+ 0x2f, 0x68, // bt [super-call]
+ 0x38, PATCH_UINT16(0x0088), // pushi 0088 (script)
+ 0x76, // push0
+ 0x81, 0x02, // lag global[2] (current room)
+ 0x4a, 0x04, // send 04
+ 0x2f, 0x5e, // bt [super-call]
+ // --> 12 bytes saved
+ // new code
+ 0x38, PATCH_UINT16(0x0176), // pushi 0176 (egoMoveSpeed)
+ 0x76, // push0
+ 0x81, 0x01, // lag global[1]
+ 0x4a, 0x04, // send 04 - sq1::egoMoveSpeed
+ 0x36, // push
+ 0x36, // push
+ 0x35, 0x03, // ldi 03
+ 0x0c, // shr
+ 0x02, // add --> egoMoveSpeed + (egoMoveSpeed >> 3)
+ 0x39, 0x01, // push 01 (waste 1 byte)
+ 0x02, // add --> egoMoveSpeed++
+ 0x65, 0x4c, // aTop cycleSpeed
+ 0x65, 0x5e, // aTop moveSpeed
+ // new code end
+ 0x89, 0xb5, // lsg global[B5]
+ 0x31, 0x13, // bnt [2nd code chunk]
+ 0x89, 0xa6, // lsg global[A6]
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x3e, // bnt [super-call]
+ 0x38, PATCH_UINT16(0x008c), // pushi 008c
+ 0x78, // push1
+ 0x72, PATCH_UINT16(0x1cb6), // lofsa moveToPath
+ 0x36, // push
+ 0x54, 0x06, // self 06 - spider::setScript(movePath)
+ 0x33, 0x32, // jmp [super-call]
+ // --> 9 bytes saved
+ PATCH_END
+};
+
+// script, description, signature patch
+static const SciScriptPatcherEntry sq1vgaSignatures[] = {
+ { true, 45, "Ulence Flats: timepod graphic glitch", 1, sq1vgaSignatureUlenceFlatsTimepodGfxGlitch, sq1vgaPatchUlenceFlatsTimepodGfxGlitch },
+ { true, 58, "Sarien armory droid zapping ego first time", 1, sq1vgaSignatureEgoShowsCard, sq1vgaPatchEgoShowsCard },
+ { true, 704, "spider droid timing issue", 1, sq1vgaSignatureSpiderDroidTiming, sq1vgaPatchSpiderDroidTiming },
+ SCI_SIGNATUREENTRY_TERMINATOR
+};
+
+// ===========================================================================
+// The toolbox in sq5 is buggy. When you click on the upper part of the "put
+// in inventory"-button (some items only - for example the hole puncher - at the
+// upper left), points will get awarded correctly and the item will get put into
+// the player's inventory, but you will then get a "not here" message and the
+// item will also remain to be the current mouse cursor.
+// The bug report also says that items may get lost. I wasn't able to reproduce
+// that part.
+// This is caused by the mouse-click event getting reprocessed (which wouldn't
+// be a problem by itself) and during this reprocessing coordinates are not
+// processed the same as during the first click (script 226 includes a local
+// subroutine, which checks coordinates in a hardcoded way w/o port-adjustment).
+// Because of this, the hotspot for the button is lower than it should be, which
+// then results in the game thinking that the user didn't click on the button
+// and also results in the previously mentioned message.
+// This happened in Sierra SCI as well (of course).
+// We fix it by combining state 0 + 1 of takeTool::changeState and so stopping
+// the event to get reprocessed. This was the only way possible, because everything
+// else is done in SCI system scripts and I don't want to touch those.
+// Applies to at least: English/German/French PC floppy
+// Responsible method: takeTool::changeState
+// Fixes bug: #6457
+static const uint16 sq5SignatureToolboxFix[] = {
+ 0x31, 0x13, // bnt [check for state 1]
+ SIG_MAGICDWORD,
+ 0x38, SIG_UINT16(0x00aa), // pushi 00aa
+ 0x39, 0x05, // pushi 05
+ 0x39, 0x16, // pushi 16
+ 0x76, // push0
+ 0x39, 0x03, // pushi 03
+ 0x76, // push0
+ 0x7c, // pushSelf
+ 0x81, 0x5b, // lag 5b
+ 0x4a, 0x0e, // send 0e
+ 0x32, SIG_UINT16(0x0088), // jmp [end-of-method]
+ 0x3c, // dup
+ 0x35, 0x01, // ldi 01
+ 0x1a, // eq?
+ 0x31, 0x28, // bnt [check for state 2]
+ SIG_END
+};
+
+static const uint16 sq5PatchToolboxFix[] = {
+ 0x31, 0x41, // bnt [check for state 2]
+ PATCH_ADDTOOFFSET(+16), // skip to jmp offset
+ 0x35, 0x01, // ldi 01
+ 0x65, 0x14, // aTop [state]
+ 0x36, 0x00, 0x00, // ldi 0000 (waste 3 bytes)
+ 0x35, 0x00, // ldi 00 (waste 2 bytes)
+ PATCH_END
+};
+
+// script, description, signature patch
+static const SciScriptPatcherEntry sq5Signatures[] = {
+ { true, 226, "toolbox fix", 1, sq5SignatureToolboxFix, sq5PatchToolboxFix },
+ SCI_SIGNATUREENTRY_TERMINATOR
+};
+
+// =================================================================================
-// script, description, magic DWORD, adjust
-const SciScriptSignature sq1vgaSignatures[] = {
- { 45, "Ulence Flats: timepod graphic glitch", 1, PATCH_MAGICDWORD( 0x07, 0x78, 0x39, 0x0a ), -1, sq1vgaSignatureUlenceFlatsTimepodGfxGlitch, sq1vgaPatchUlenceFlatsTimepodGfxGlitch },
- { 58, "Sarien armory droid zapping ego first time", 1, PATCH_MAGICDWORD( 0x72, 0x88, 0x15, 0x36 ), -70, sq1vgaSignatureEgoShowsCard, sq1vgaPatchEgoShowsCard },
+ScriptPatcher::ScriptPatcher() {
+ int selectorCount = ARRAYSIZE(selectorNameTable);
+ int selectorNr;
- SCI_SIGNATUREENTRY_TERMINATOR};
+ // Allocate table for selector-IDs and initialize that table as well
+ _selectorIdTable = new Selector[ selectorCount ];
+ for (selectorNr = 0; selectorNr < selectorCount; selectorNr++)
+ _selectorIdTable[selectorNr] = -1;
+
+ _runtimeTable = NULL;
+}
+
+ScriptPatcher::~ScriptPatcher() {
+ delete[] _runtimeTable;
+ delete[] _selectorIdTable;
+}
// will actually patch previously found signature area
-void Script::applyPatch(const uint16 *patch, byte *scriptData, const uint32 scriptSize, int32 signatureOffset) {
+void ScriptPatcher::applyPatch(const SciScriptPatcherEntry *patchEntry, byte *scriptData, const uint32 scriptSize, int32 signatureOffset, const bool isMacSci11) {
+ const uint16 *patchData = patchEntry->patchData;
byte orgData[PATCH_VALUELIMIT];
int32 offset = signatureOffset;
- uint16 patchWord = *patch;
+ uint16 patchWord = *patchEntry->patchData;
+ uint16 patchSelector = 0;
// Copy over original bytes from script
uint32 orgDataSize = scriptSize - offset;
@@ -1555,74 +2634,179 @@ void Script::applyPatch(const uint16 *patch, byte *scriptData, const uint32 scri
memcpy(&orgData, &scriptData[offset], orgDataSize);
while (patchWord != PATCH_END) {
+ uint16 patchCommand = patchWord & PATCH_COMMANDMASK;
uint16 patchValue = patchWord & PATCH_VALUEMASK;
- switch (patchWord & PATCH_COMMANDMASK) {
- case PATCH_ADDTOOFFSET:
+ switch (patchCommand) {
+ case PATCH_CODE_ADDTOOFFSET: {
// add value to offset
- offset += patchValue & ~PATCH_ADDTOOFFSET;
+ offset += patchValue;
break;
- case PATCH_GETORIGINALBYTE:
+ }
+ case PATCH_CODE_GETORIGINALBYTE: {
// get original byte from script
if (patchValue >= orgDataSize)
- error("patching: can not get requested original byte from script");
+ error("Script-Patcher: can not get requested original byte from script");
scriptData[offset] = orgData[patchValue];
offset++;
break;
- case PATCH_ADJUSTWORD: {
- // Adjust word right before current position
- byte *adjustPtr = &scriptData[offset - 2];
- uint16 adjustWord = READ_LE_UINT16(adjustPtr);
- adjustWord += patchValue;
- WRITE_LE_UINT16(adjustPtr, adjustWord);
+ }
+ case PATCH_CODE_GETORIGINALBYTEADJUST: {
+ // get original byte from script and adjust it
+ if (patchValue >= orgDataSize)
+ error("Script-Patcher: can not get requested original byte from script");
+ byte orgByte = orgData[patchValue];
+ int16 adjustValue;
+ patchData++; adjustValue = (int16)(*patchData);
+ scriptData[offset] = orgByte + adjustValue;
+ offset++;
break;
}
- case PATCH_ADJUSTWORD_NEG: {
- // Adjust word right before current position (negative way)
- byte *adjustPtr = &scriptData[offset - 2];
- uint16 adjustWord = READ_LE_UINT16(adjustPtr);
- adjustWord -= patchValue;
- WRITE_LE_UINT16(adjustPtr, adjustWord);
+ case PATCH_CODE_UINT16:
+ case PATCH_CODE_SELECTOR16: {
+ byte byte1;
+ byte byte2;
+
+ switch (patchCommand) {
+ case PATCH_CODE_UINT16: {
+ byte1 = patchValue & PATCH_BYTEMASK;
+ patchData++; patchWord = *patchData;
+ if (patchWord & PATCH_COMMANDMASK)
+ error("Script-Patcher: Patch inconsistent");
+ byte2 = patchWord & PATCH_BYTEMASK;
+ break;
+ }
+ case PATCH_CODE_SELECTOR16: {
+ patchSelector = _selectorIdTable[patchValue];
+ byte1 = patchSelector & 0xFF;
+ byte2 = patchSelector >> 8;
+ break;
+ }
+ default:
+ byte1 = 0; byte2 = 0;
+ }
+ if (!isMacSci11) {
+ scriptData[offset++] = byte1;
+ scriptData[offset++] = byte2;
+ } else {
+ // SCI1.1+ on macintosh had uint16s in script in BE-order
+ scriptData[offset++] = byte2;
+ scriptData[offset++] = byte1;
+ }
break;
}
- default:
- scriptData[offset] = patchValue & 0xFF;
+ case PATCH_CODE_SELECTOR8: {
+ patchSelector = _selectorIdTable[patchValue];
+ if (patchSelector & 0xFF00)
+ error("Script-Patcher: 8 bit selector required, game uses 16 bit selector");
+ scriptData[offset] = patchSelector & 0xFF;
offset++;
+ break;
}
- patch++;
- patchWord = *patch;
+ case PATCH_CODE_BYTE:
+ scriptData[offset] = patchValue & PATCH_BYTEMASK;
+ offset++;
+ }
+ patchData++;
+ patchWord = *patchData;
}
}
// will return -1 if no match was found, otherwise an offset to the start of the signature match
-int32 Script::findSignature(const SciScriptSignature *signature, const byte *scriptData, const uint32 scriptSize) {
+int32 ScriptPatcher::findSignature(const SciScriptPatcherEntry *patchEntry, SciScriptPatcherRuntimeEntry *runtimeEntry, const byte *scriptData, const uint32 scriptSize, const bool isMacSci11) {
if (scriptSize < 4) // we need to find a DWORD, so less than 4 bytes is not okay
return -1;
- const uint32 magicDWord = signature->magicDWord; // is platform-specific BE/LE form, so that the later match will work
+ const uint32 magicDWord = runtimeEntry->magicDWord; // is platform-specific BE/LE form, so that the later match will work
const uint32 searchLimit = scriptSize - 3;
uint32 DWordOffset = 0;
// first search for the magic DWORD
while (DWordOffset < searchLimit) {
if (magicDWord == READ_UINT32(scriptData + DWordOffset)) {
// magic DWORD found, check if actual signature matches
- uint32 offset = DWordOffset + signature->magicOffset;
+ uint32 offset = DWordOffset + runtimeEntry->magicOffset;
uint32 byteOffset = offset;
- const byte *signatureData = signature->data;
- byte matchAdjust = 1;
- while (matchAdjust) {
- byte matchBytesCount = *signatureData++;
- if ((byteOffset + matchBytesCount) > scriptSize) // Out-Of-Bounds?
+ const uint16 *signatureData = patchEntry->signatureData;
+ uint16 sigSelector = 0;
+
+ uint16 sigWord = *signatureData;
+ while (sigWord != SIG_END) {
+ uint16 sigCommand = sigWord & SIG_COMMANDMASK;
+ uint16 sigValue = sigWord & SIG_VALUEMASK;
+ switch (sigCommand) {
+ case SIG_CODE_ADDTOOFFSET: {
+ // add value to offset
+ byteOffset += sigValue;
+ break;
+ }
+ case SIG_CODE_UINT16:
+ case SIG_CODE_SELECTOR16: {
+ if ((byteOffset + 1) < scriptSize) {
+ byte byte1;
+ byte byte2;
+
+ switch (sigCommand) {
+ case SIG_CODE_UINT16: {
+ byte1 = sigValue & SIG_BYTEMASK;
+ signatureData++; sigWord = *signatureData;
+ if (sigWord & SIG_COMMANDMASK)
+ error("Script-Patcher: signature inconsistent\nFaulty patch: '%s'", patchEntry->description);
+ byte2 = sigWord & SIG_BYTEMASK;
+ break;
+ }
+ case SIG_CODE_SELECTOR16: {
+ sigSelector = _selectorIdTable[sigValue];
+ byte1 = sigSelector & 0xFF;
+ byte2 = sigSelector >> 8;
+ break;
+ }
+ default:
+ byte1 = 0; byte2 = 0;
+ }
+ if (!isMacSci11) {
+ if ((scriptData[byteOffset] != byte1) || (scriptData[byteOffset + 1] != byte2))
+ sigWord = SIG_MISMATCH;
+ } else {
+ // SCI1.1+ on macintosh had uint16s in script in BE-order
+ if ((scriptData[byteOffset] != byte2) || (scriptData[byteOffset + 1] != byte1))
+ sigWord = SIG_MISMATCH;
+ }
+ byteOffset += 2;
+ } else {
+ sigWord = SIG_MISMATCH;
+ }
break;
- if (memcmp(signatureData, &scriptData[byteOffset], matchBytesCount)) // Byte-Mismatch?
+ }
+ case SIG_CODE_SELECTOR8: {
+ if (byteOffset < scriptSize) {
+ sigSelector = _selectorIdTable[sigValue];
+ if (sigSelector & 0xFF00)
+ error("Script-Patcher: 8 bit selector required, game uses 16 bit selector\nFaulty patch: '%s'", patchEntry->description);
+ if (scriptData[byteOffset] != (sigSelector & 0xFF))
+ sigWord = SIG_MISMATCH;
+ byteOffset++;
+ } else {
+ sigWord = SIG_MISMATCH; // out of bounds
+ }
+ break;
+ }
+ case SIG_CODE_BYTE:
+ if (byteOffset < scriptSize) {
+ if (scriptData[byteOffset] != sigWord)
+ sigWord = SIG_MISMATCH;
+ byteOffset++;
+ } else {
+ sigWord = SIG_MISMATCH; // out of bounds
+ }
+ }
+
+ if (sigWord == SIG_MISMATCH)
break;
- // those bytes matched, adjust offsets accordingly
- signatureData += matchBytesCount;
- byteOffset += matchBytesCount;
- // get offset...
- matchAdjust = *signatureData++;
- byteOffset += matchAdjust;
+
+ signatureData++;
+ sigWord = *signatureData;
}
- if (!matchAdjust) // all matches worked?
+
+ if (sigWord == SIG_END) // signature fully matched?
return offset;
}
DWordOffset++;
@@ -1631,9 +2815,182 @@ int32 Script::findSignature(const SciScriptSignature *signature, const byte *scr
return -1;
}
-void Script::matchSignatureAndPatch(uint16 scriptNr, byte *scriptData, const uint32 scriptSize) {
- const SciScriptSignature *signatureTable = NULL;
- switch (g_sci->getGameId()) {
+// This method calculates the magic DWORD for each entry in the signature table
+// and it also initializes the selector table for selectors used in the signatures/patches of the current game
+void ScriptPatcher::initSignature(const SciScriptPatcherEntry *patchTable, bool isMacSci11) {
+ const SciScriptPatcherEntry *curEntry = patchTable;
+ SciScriptPatcherRuntimeEntry *curRuntimeEntry;
+ Selector curSelector = -1;
+ int step;
+ int magicOffset;
+ byte magicDWord[4];
+ int magicDWordLeft = 0;
+ const uint16 *curData;
+ uint16 curWord;
+ uint16 curCommand;
+ uint32 curValue;
+ byte byte1 = 0;
+ byte byte2 = 0;
+ int patchEntryCount = 0;
+
+ // Count entries and allocate runtime data
+ while (curEntry->signatureData) {
+ patchEntryCount++; curEntry++;
+ }
+ _runtimeTable = new SciScriptPatcherRuntimeEntry[patchEntryCount];
+ memset(_runtimeTable, 0, sizeof(SciScriptPatcherRuntimeEntry) * patchEntryCount);
+
+ curEntry = patchTable;
+ curRuntimeEntry = _runtimeTable;
+ while (curEntry->signatureData) {
+ // process signature
+ memset(magicDWord, 0, sizeof(magicDWord));
+
+ curRuntimeEntry->active = curEntry->defaultActive;
+ curRuntimeEntry->magicDWord = 0;
+ curRuntimeEntry->magicOffset = 0;
+
+ for (step = 0; step < 2; step++) {
+ switch (step) {
+ case 0: curData = curEntry->signatureData; break;
+ case 1: curData = curEntry->patchData; break;
+ }
+
+ curWord = *curData;
+ magicOffset = 0;
+ while (curWord != SIG_END) {
+ curCommand = curWord & SIG_COMMANDMASK;
+ curValue = curWord & SIG_VALUEMASK;
+ switch (curCommand) {
+ case SIG_MAGICDWORD: {
+ if (step == 0) {
+ if ((curRuntimeEntry->magicDWord) || (magicDWordLeft))
+ error("Script-Patcher: Magic-DWORD specified multiple times in signature\nFaulty patch: '%s'", curEntry->description);
+ magicDWordLeft = 4;
+ curRuntimeEntry->magicOffset = magicOffset;
+ }
+ break;
+ }
+ case SIG_CODE_ADDTOOFFSET: {
+ magicOffset -= curValue;
+ if (magicDWordLeft)
+ error("Script-Patcher: Magic-DWORD contains AddToOffset command\nFaulty patch: '%s'", curEntry->description);
+ break;
+ }
+ case SIG_CODE_UINT16:
+ case SIG_CODE_SELECTOR16: {
+ // UINT16 or 1
+ switch (curCommand) {
+ case SIG_CODE_UINT16: {
+ curData++; curWord = *curData;
+ if (curWord & SIG_COMMANDMASK)
+ error("Script-Patcher: signature entry inconsistent\nFaulty patch: '%s'", curEntry->description);
+ if (!isMacSci11) {
+ byte1 = curValue;
+ byte2 = curWord & SIG_BYTEMASK;
+ } else {
+ byte1 = curWord & SIG_BYTEMASK;
+ byte2 = curValue;
+ }
+ break;
+ }
+ case SIG_CODE_SELECTOR16: {
+ curSelector = _selectorIdTable[curValue];
+ if (curSelector == -1) {
+ curSelector = g_sci->getKernel()->findSelector(selectorNameTable[curValue]);
+ _selectorIdTable[curValue] = curSelector;
+ }
+ if (!isMacSci11) {
+ byte1 = curSelector & 0x00FF;
+ byte2 = curSelector >> 8;
+ } else {
+ byte1 = curSelector >> 8;
+ byte2 = curSelector & 0x00FF;
+ }
+ break;
+ }
+ }
+ magicOffset -= 2;
+ if (magicDWordLeft) {
+ // Remember current word for Magic DWORD
+ magicDWord[4 - magicDWordLeft] = byte1;
+ magicDWordLeft--;
+ if (magicDWordLeft) {
+ magicDWord[4 - magicDWordLeft] = byte2;
+ magicDWordLeft--;
+ }
+ if (!magicDWordLeft) {
+ curRuntimeEntry->magicDWord = READ_LE_UINT32(magicDWord);
+ }
+ }
+ break;
+ }
+ case SIG_CODE_BYTE:
+ case SIG_CODE_SELECTOR8: {
+ if (curCommand == SIG_CODE_SELECTOR8) {
+ curSelector = _selectorIdTable[curValue];
+ if (curSelector == -1) {
+ curSelector = g_sci->getKernel()->findSelector(selectorNameTable[curValue]);
+ _selectorIdTable[curValue] = curSelector;
+ if (curSelector != -1) {
+ if (curSelector & 0xFF00)
+ error("Script-Patcher: 8 bit selector required, game uses 16 bit selector\nFaulty patch: '%s'", curEntry->description);
+ }
+ }
+ curValue = curSelector;
+ }
+ magicOffset--;
+ if (magicDWordLeft) {
+ // Remember current byte for Magic DWORD
+ magicDWord[4 - magicDWordLeft] = (byte)curValue;
+ magicDWordLeft--;
+ if (!magicDWordLeft) {
+ curRuntimeEntry->magicDWord = READ_LE_UINT32(magicDWord);
+ }
+ }
+ }
+ }
+ curData++;
+ curWord = *curData;
+ }
+ }
+ if (magicDWordLeft)
+ error("Script-Patcher: Magic-DWORD beyond End-Of-Signature\nFaulty patch: '%s'", curEntry->description);
+ if (!curRuntimeEntry->magicDWord)
+ error("Script-Patcher: Magic-DWORD not specified in signature\nFaulty patch: '%s'", curEntry->description);
+
+ curEntry++; curRuntimeEntry++;
+ }
+}
+
+// This method enables certain patches
+// It's used for patches, which are not meant to get applied all the time
+void ScriptPatcher::enablePatch(const SciScriptPatcherEntry *patchTable, const char *searchDescription) {
+ const SciScriptPatcherEntry *curEntry = patchTable;
+ SciScriptPatcherRuntimeEntry *runtimeEntry = _runtimeTable;
+ int searchDescriptionLen = strlen(searchDescription);
+ int matchCount = 0;
+
+ while (curEntry->signatureData) {
+ if (strncmp(curEntry->description, searchDescription, searchDescriptionLen) == 0) {
+ // match found, enable patch
+ runtimeEntry->active = true;
+ matchCount++;
+ }
+ curEntry++; runtimeEntry++;
+ }
+
+ if (!matchCount)
+ error("Script-Patcher: no patch found to enable");
+}
+
+void ScriptPatcher::processScript(uint16 scriptNr, byte *scriptData, const uint32 scriptSize) {
+ const SciScriptPatcherEntry *signatureTable = NULL;
+ const SciScriptPatcherEntry *curEntry = NULL;
+ SciScriptPatcherRuntimeEntry *curRuntimeEntry = NULL;
+ const Sci::SciGameId gameId = g_sci->getGameId();
+
+ switch (gameId) {
case GID_CAMELOT:
signatureTable = camelotSignatures;
break;
@@ -1653,11 +3010,7 @@ void Script::matchSignatureAndPatch(uint16 scriptNr, byte *scriptData, const uin
signatureTable = gk1Signatures;
break;
case GID_KQ5:
- // See the explanation in the kq5SignatureWinGMSignals comment
- if (g_sci->_features->useAltWinGMSound())
- signatureTable = kq5WinGMSignatures;
- else
- signatureTable = kq5Signatures;
+ signatureTable = kq5Signatures;
break;
case GID_KQ6:
signatureTable = kq6Signatures;
@@ -1671,6 +3024,9 @@ void Script::matchSignatureAndPatch(uint16 scriptNr, byte *scriptData, const uin
case GID_LSL2:
signatureTable = larry2Signatures;
break;
+ case GID_LSL5:
+ signatureTable = larry5Signatures;
+ break;
case GID_LSL6:
signatureTable = larry6Signatures;
break;
@@ -1695,26 +3051,67 @@ void Script::matchSignatureAndPatch(uint16 scriptNr, byte *scriptData, const uin
case GID_SQ4:
signatureTable = sq4Signatures;
break;
+ case GID_SQ5:
+ signatureTable = sq5Signatures;
+ break;
default:
break;
}
if (signatureTable) {
- while (signatureTable->data) {
- if (scriptNr == signatureTable->scriptNr) {
+ bool isMacSci11 = (g_sci->getPlatform() == Common::kPlatformMacintosh && getSciVersion() >= SCI_VERSION_1_1);
+
+ if (!_runtimeTable) {
+ // Abort, in case selectors are not yet initialized (happens for games w/o selector-dictionary)
+ if (!g_sci->getKernel()->selectorNamesAvailable())
+ return;
+
+ // signature table needs to get initialized (Magic DWORD set, selector table set)
+ initSignature(signatureTable, isMacSci11);
+
+ // Do additional game-specific initialization
+ switch (gameId) {
+ case GID_KQ5:
+ if (g_sci->_features->useAltWinGMSound()) {
+ // See the explanation in the kq5SignatureWinGMSignals comment
+ enablePatch(signatureTable, "Win: GM Music signal checks");
+ }
+ break;
+ case GID_KQ6:
+ if (g_sci->isCD()) {
+ // Enables Dual mode patches (audio + subtitles at the same time) for King's Quest 6
+ enablePatch(signatureTable, "CD: audio + text support");
+ }
+ break;
+ case GID_LAURABOW2:
+ if (g_sci->isCD()) {
+ // Enables Dual mode patches (audio + subtitles at the same time) for Laura Bow 2
+ enablePatch(signatureTable, "CD: audio + text support");
+ }
+ break;
+ default:
+ break;
+ }
+ }
+
+ curEntry = signatureTable;
+ curRuntimeEntry = _runtimeTable;
+
+ while (curEntry->signatureData) {
+ if ((scriptNr == curEntry->scriptNr) && (curRuntimeEntry->active)) {
int32 foundOffset = 0;
- int16 applyCount = signatureTable->applyCount;
+ int16 applyCount = curEntry->applyCount;
do {
- foundOffset = findSignature(signatureTable, scriptData, scriptSize);
+ foundOffset = findSignature(curEntry, curRuntimeEntry, scriptData, scriptSize, isMacSci11);
if (foundOffset != -1) {
// found, so apply the patch
- debugC(kDebugLevelScripts, "matched and patched %s on script %d offset %d", signatureTable->description, scriptNr, foundOffset);
- applyPatch(signatureTable->patch, scriptData, scriptSize, foundOffset);
+ debugC(kDebugLevelScriptPatcher, "Script-Patcher: '%s' on script %d offset %d", curEntry->description, scriptNr, foundOffset);
+ applyPatch(curEntry, scriptData, scriptSize, foundOffset, isMacSci11);
}
applyCount--;
} while ((foundOffset != -1) && (applyCount));
}
- signatureTable++;
+ curEntry++; curRuntimeEntry++;
}
}
}
diff --git a/engines/sci/engine/script_patches.h b/engines/sci/engine/script_patches.h
new file mode 100644
index 0000000000..0b35792949
--- /dev/null
+++ b/engines/sci/engine/script_patches.h
@@ -0,0 +1,108 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ */
+
+#ifndef SCI_ENGINE_SCRIPT_PATCHES_H
+#define SCI_ENGINE_SCRIPT_PATCHES_H
+
+#include "sci/sci.h"
+
+namespace Sci {
+
+// Please do not use the #defines, that are called SIG_CODE_* / PATCH_CODE_* inside signature/patch-tables
+#define SIG_END 0xFFFF
+#define SIG_MISMATCH 0xFFFE
+#define SIG_COMMANDMASK 0xF000
+#define SIG_VALUEMASK 0x0FFF
+#define SIG_BYTEMASK 0x00FF
+#define SIG_MAGICDWORD 0xF000
+#define SIG_CODE_ADDTOOFFSET 0xE000
+#define SIG_ADDTOOFFSET(_offset_) SIG_CODE_ADDTOOFFSET | _offset_
+#define SIG_CODE_SELECTOR16 0x9000
+#define SIG_SELECTOR16(_selectorID_) SIG_CODE_SELECTOR16 | SELECTOR_##_selectorID_
+#define SIG_CODE_SELECTOR8 0x8000
+#define SIG_SELECTOR8(_selectorID_) SIG_CODE_SELECTOR8 | SELECTOR_##_selectorID_
+#define SIG_CODE_UINT16 0x1000
+#define SIG_UINT16(_value_) SIG_CODE_UINT16 | (_value_ & 0xFF), (_value_ >> 8)
+#define SIG_CODE_BYTE 0x0000
+
+#define PATCH_END SIG_END
+#define PATCH_COMMANDMASK SIG_COMMANDMASK
+#define PATCH_VALUEMASK SIG_VALUEMASK
+#define PATCH_BYTEMASK SIG_BYTEMASK
+#define PATCH_CODE_ADDTOOFFSET SIG_CODE_ADDTOOFFSET
+#define PATCH_ADDTOOFFSET(_offset_) SIG_CODE_ADDTOOFFSET | _offset_
+#define PATCH_CODE_GETORIGINALBYTE 0xD000
+#define PATCH_GETORIGINALBYTE(_offset_) PATCH_CODE_GETORIGINALBYTE | _offset_
+#define PATCH_CODE_GETORIGINALBYTEADJUST 0xC000
+#define PATCH_GETORIGINALBYTEADJUST(_offset_, _adjustValue_) PATCH_CODE_GETORIGINALBYTEADJUST | _offset_, (uint16)(_adjustValue_)
+#define PATCH_CODE_SELECTOR16 SIG_CODE_SELECTOR16
+#define PATCH_SELECTOR16(_selectorID_) SIG_CODE_SELECTOR16 | SELECTOR_##_selectorID_
+#define PATCH_CODE_SELECTOR8 SIG_CODE_SELECTOR8
+#define PATCH_SELECTOR8(_selectorID_) SIG_CODE_SELECTOR8 | SELECTOR_##_selectorID_
+#define PATCH_CODE_UINT16 SIG_CODE_UINT16
+#define PATCH_UINT16(_value_) SIG_CODE_UINT16 | (_value_ & 0xFF), (_value_ >> 8)
+#define PATCH_CODE_BYTE SIG_CODE_BYTE
+
+// defines maximum scratch area for getting original bytes from unpatched script data
+#define PATCH_VALUELIMIT 4096
+
+struct SciScriptPatcherEntry {
+ bool defaultActive;
+ uint16 scriptNr;
+ const char *description;
+ int16 applyCount;
+ const uint16 *signatureData;
+ const uint16 *patchData;
+};
+
+//#define SCI_SIGNATUREENTRY_TERMINATOR { false, 0, NULL, 0, 0, 0, NULL, NULL }
+#define SCI_SIGNATUREENTRY_TERMINATOR { false, 0, NULL, 0, NULL, NULL }
+
+struct SciScriptPatcherRuntimeEntry {
+ bool active;
+ uint32 magicDWord;
+ int magicOffset;
+};
+
+/**
+ * ScriptPatcher class, handles on-the-fly patching of script data
+ */
+class ScriptPatcher {
+public:
+ ScriptPatcher();
+ ~ScriptPatcher();
+
+ void processScript(uint16 scriptNr, byte *scriptData, const uint32 scriptSize);
+
+private:
+ void initSignature(const SciScriptPatcherEntry *patchTable, bool isMacSci11);
+ void enablePatch(const SciScriptPatcherEntry *patchTable, const char *searchDescription);
+ int32 findSignature(const SciScriptPatcherEntry *patchEntry, SciScriptPatcherRuntimeEntry *runtimeEntry, const byte *scriptData, const uint32 scriptSize, bool isMacSci11);
+ void applyPatch(const SciScriptPatcherEntry *patchEntry, byte *scriptData, const uint32 scriptSize, int32 signatureOffset, bool isMacSci11);
+
+ Selector *_selectorIdTable;
+ SciScriptPatcherRuntimeEntry *_runtimeTable;
+};
+
+} // End of namespace Sci
+
+#endif // SCI_ENGINE_WORKAROUNDS_H
diff --git a/engines/sci/engine/scriptdebug.cpp b/engines/sci/engine/scriptdebug.cpp
index 277437109c..f0157a6569 100644
--- a/engines/sci/engine/scriptdebug.cpp
+++ b/engines/sci/engine/scriptdebug.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -604,7 +604,7 @@ bool SciEngine::checkSelectorBreakpoint(BreakpointType breakpointType, reg_t sen
Common::List<Breakpoint>::const_iterator bpIter;
for (bpIter = _debugState._breakpoints.begin(); bpIter != _debugState._breakpoints.end(); ++bpIter) {
if ((*bpIter).type == breakpointType && (*bpIter).name == methodName) {
- _console->DebugPrintf("Break on %s (in [%04x:%04x])\n", methodName.c_str(), PRINT_REG(send_obj));
+ _console->debugPrintf("Break on %s (in [%04x:%04x])\n", methodName.c_str(), PRINT_REG(send_obj));
_debugState.debugging = true;
_debugState.breakpointWasHit = true;
return true;
@@ -620,7 +620,7 @@ bool SciEngine::checkExportBreakpoint(uint16 script, uint16 pubfunct) {
Common::List<Breakpoint>::const_iterator bp;
for (bp = _debugState._breakpoints.begin(); bp != _debugState._breakpoints.end(); ++bp) {
if (bp->type == BREAK_EXPORT && bp->address == bpaddress) {
- _console->DebugPrintf("Break on script %d, export %d\n", script, pubfunct);
+ _console->debugPrintf("Break on script %d, export %d\n", script, pubfunct);
_debugState.debugging = true;
_debugState.breakpointWasHit = true;
return true;
@@ -666,12 +666,12 @@ void debugSelectorCall(reg_t send_obj, Selector selector, int argc, StackPtr arg
reg_t selectorValue = *varp.getPointer(segMan);
if (!argc && (activeBreakpointTypes & BREAK_SELECTORREAD)) {
if (g_sci->checkSelectorBreakpoint(BREAK_SELECTORREAD, send_obj, selector))
- con->DebugPrintf("Read from selector (%s:%s): %04x:%04x\n",
+ con->debugPrintf("Read from selector (%s:%s): %04x:%04x\n",
objectName, selectorName,
PRINT_REG(selectorValue));
} else if (argc && (activeBreakpointTypes & BREAK_SELECTORWRITE)) {
if (g_sci->checkSelectorBreakpoint(BREAK_SELECTORWRITE, send_obj, selector))
- con->DebugPrintf("Write to selector (%s:%s): change %04x:%04x to %04x:%04x\n",
+ con->debugPrintf("Write to selector (%s:%s): change %04x:%04x to %04x:%04x\n",
objectName, selectorName,
PRINT_REG(selectorValue), PRINT_REG(argp[1]));
}
@@ -690,13 +690,13 @@ void debugSelectorCall(reg_t send_obj, Selector selector, int argc, StackPtr arg
if (true) {
if (true) {
#endif
- con->DebugPrintf("%s::%s(", objectName, selectorName);
+ con->debugPrintf("%s::%s(", objectName, selectorName);
for (int i = 0; i < argc; i++) {
- con->DebugPrintf("%04x:%04x", PRINT_REG(argp[i+1]));
+ con->debugPrintf("%04x:%04x", PRINT_REG(argp[i+1]));
if (i + 1 < argc)
- con->DebugPrintf(", ");
+ con->debugPrintf(", ");
}
- con->DebugPrintf(") at %04x:%04x\n", PRINT_REG(funcp));
+ con->debugPrintf(") at %04x:%04x\n", PRINT_REG(funcp));
}
}
break;
@@ -737,37 +737,39 @@ void logKernelCall(const KernelFunction *kernelCall, const KernelSubFunction *ke
case SIG_TYPE_REFERENCE:
{
SegmentObj *mobj = s->_segMan->getSegmentObj(argv[parmNr].getSegment());
- switch (mobj->getType()) {
- case SEG_TYPE_HUNK:
- {
- HunkTable *ht = (HunkTable *)mobj;
- int index = argv[parmNr].getOffset();
- if (ht->isValidEntry(index)) {
- // NOTE: This ", deleted" isn't as useful as it could
- // be because it prints the status _after_ the kernel
- // call.
- debugN(" ('%s' hunk%s)", ht->_table[index].type, ht->_table[index].mem ? "" : ", deleted");
- } else
- debugN(" (INVALID hunk ref)");
- break;
- }
- default:
- // TODO: Any other segment types which could
- // use special handling?
-
- if (kernelCall->function == kSaid) {
- SegmentRef saidSpec = s->_segMan->dereference(argv[parmNr]);
- if (saidSpec.isRaw) {
- debugN(" ('");
- g_sci->getVocabulary()->debugDecipherSaidBlock(saidSpec.raw);
- debugN("')");
+ if (mobj) {
+ switch (mobj->getType()) {
+ case SEG_TYPE_HUNK:
+ {
+ HunkTable *ht = (HunkTable *)mobj;
+ int index = argv[parmNr].getOffset();
+ if (ht->isValidEntry(index)) {
+ // NOTE: This ", deleted" isn't as useful as it could
+ // be because it prints the status _after_ the kernel
+ // call.
+ debugN(" ('%s' hunk%s)", ht->_table[index].type, ht->_table[index].mem ? "" : ", deleted");
+ } else
+ debugN(" (INVALID hunk ref)");
+ break;
+ }
+ default:
+ // TODO: Any other segment types which could
+ // use special handling?
+
+ if (kernelCall->function == kSaid) {
+ SegmentRef saidSpec = s->_segMan->dereference(argv[parmNr]);
+ if (saidSpec.isRaw) {
+ debugN(" ('");
+ g_sci->getVocabulary()->debugDecipherSaidBlock(saidSpec.raw);
+ debugN("')");
+ } else {
+ debugN(" (non-raw said-spec)");
+ }
} else {
- debugN(" (non-raw said-spec)");
+ debugN(" ('%s')", s->_segMan->getString(argv[parmNr]).c_str());
}
- } else {
- debugN(" ('%s')", s->_segMan->getString(argv[parmNr]).c_str());
+ break;
}
- break;
}
}
default:
diff --git a/engines/sci/engine/seg_manager.cpp b/engines/sci/engine/seg_manager.cpp
index 97e33f256b..3738fd3dcb 100644
--- a/engines/sci/engine/seg_manager.cpp
+++ b/engines/sci/engine/seg_manager.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -28,7 +28,8 @@
namespace Sci {
-SegManager::SegManager(ResourceManager *resMan) {
+SegManager::SegManager(ResourceManager *resMan, ScriptPatcher *scriptPatcher)
+ : _resMan(resMan), _scriptPatcher(scriptPatcher) {
_heap.push_back(0);
_clonesSegId = 0;
@@ -44,8 +45,6 @@ SegManager::SegManager(ResourceManager *resMan) {
_stringSegId = 0;
#endif
- _resMan = resMan;
-
createClassTable();
}
@@ -262,8 +261,14 @@ const char *SegManager::getObjectName(reg_t pos) {
const char *name = 0;
if (nameReg.getSegment())
name = derefString(nameReg);
- if (!name)
- return "<invalid name>";
+ if (!name) {
+ // Crazy Nick Laura Bow is missing some object names needed for the static
+ // selector vocabulary
+ if (g_sci->getGameId() == GID_CNICK_LAURABOW && pos == make_reg(1, 0x2267))
+ return "Character";
+ else
+ return "<invalid name>";
+ }
return name;
}
@@ -977,7 +982,7 @@ int SegManager::instantiateScript(int scriptNum) {
scr = allocateScript(scriptNum, &segmentId);
}
- scr->load(scriptNum, _resMan);
+ scr->load(scriptNum, _resMan, _scriptPatcher);
scr->initializeLocals(this);
scr->initializeClasses(this);
scr->initializeObjects(this, segmentId);
diff --git a/engines/sci/engine/seg_manager.h b/engines/sci/engine/seg_manager.h
index 074d3f6b0a..2d6e624f6f 100644
--- a/engines/sci/engine/seg_manager.h
+++ b/engines/sci/engine/seg_manager.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -49,7 +49,7 @@ public:
/**
* Initialize the segment manager.
*/
- SegManager(ResourceManager *resMan);
+ SegManager(ResourceManager *resMan, ScriptPatcher *scriptPatcher);
/**
* Deallocate all memory associated with the segment manager.
@@ -224,7 +224,7 @@ public:
* Allocate a fresh chunk of the hunk
* @param[in] size Number of bytes to allocate for the hunk entry
* @param[in] hunk_type A descriptive string for the hunk entry, for
- * debugging purposes
+ * debugging purposes
* @return The offset of the freshly allocated hunk entry
*/
reg_t allocateHunkEntry(const char *hunk_type, int size);
@@ -448,6 +448,7 @@ private:
Common::HashMap<int, SegmentId> _scriptSegMap;
ResourceManager *_resMan;
+ ScriptPatcher *_scriptPatcher;
SegmentId _clonesSegId; ///< ID of the (a) clones segment
SegmentId _listsSegId; ///< ID of the (a) list segment
diff --git a/engines/sci/engine/segment.cpp b/engines/sci/engine/segment.cpp
index a7f147a15a..bb90698e6a 100644
--- a/engines/sci/engine/segment.cpp
+++ b/engines/sci/engine/segment.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/segment.h b/engines/sci/engine/segment.h
index 0d54b651e1..de7f60ac16 100644
--- a/engines/sci/engine/segment.h
+++ b/engines/sci/engine/segment.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/selector.cpp b/engines/sci/engine/selector.cpp
index 2f6b4d58dd..910f1f885f 100644
--- a/engines/sci/engine/selector.cpp
+++ b/engines/sci/engine/selector.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/selector.h b/engines/sci/engine/selector.h
index 5d3d0752ac..b3dd393708 100644
--- a/engines/sci/engine/selector.h
+++ b/engines/sci/engine/selector.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/state.cpp b/engines/sci/engine/state.cpp
index 0f0c8dcd66..7701822f6d 100644
--- a/engines/sci/engine/state.cpp
+++ b/engines/sci/engine/state.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -252,7 +252,7 @@ Common::String SciEngine::getSciLanguageString(const Common::String &str, kLangu
}
}
- if (seeker)
+ if (*seeker)
return Common::String(str.c_str(), seeker - str.c_str());
else
return str;
diff --git a/engines/sci/engine/state.h b/engines/sci/engine/state.h
index 25110ce0ca..ecc8cb7dfe 100644
--- a/engines/sci/engine/state.h
+++ b/engines/sci/engine/state.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/static_selectors.cpp b/engines/sci/engine/static_selectors.cpp
index 74d2851024..188da3d5a2 100644
--- a/engines/sci/engine/static_selectors.cpp
+++ b/engines/sci/engine/static_selectors.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp
index ef8f165084..06858540ec 100644
--- a/engines/sci/engine/vm.cpp
+++ b/engines/sci/engine/vm.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -200,11 +200,18 @@ static void write_var(EngineState *s, int type, int index, reg_t value) {
s->variables[type][index] = value;
- // If the game is trying to change its speech/subtitle settings, apply the ScummVM audio
- // options first, if they haven't been applied yet
- if (type == VAR_GLOBAL && index == 90 && !g_sci->getEngineState()->_syncedAudioOptions) {
- g_sci->syncIngameAudioOptions();
- g_sci->getEngineState()->_syncedAudioOptions = true;
+ if (type == VAR_GLOBAL && index == 90) {
+ // The game is trying to change its speech/subtitle settings
+ if (!g_sci->getEngineState()->_syncedAudioOptions || s->variables[VAR_GLOBAL][4] == TRUE_REG) {
+ // ScummVM audio options haven't been applied yet, so apply them.
+ // We also force the ScummVM audio options when loading a game from
+ // the launcher.
+ g_sci->syncIngameAudioOptions();
+ g_sci->getEngineState()->_syncedAudioOptions = true;
+ } else {
+ // Update ScummVM's audio options
+ g_sci->updateScummVMAudioOptions();
+ }
}
}
}
diff --git a/engines/sci/engine/vm.h b/engines/sci/engine/vm.h
index 8b38faa013..cf65803929 100644
--- a/engines/sci/engine/vm.h
+++ b/engines/sci/engine/vm.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/engine/vm_types.cpp b/engines/sci/engine/vm_types.cpp
index 5327dd1a2e..65a82832cc 100644
--- a/engines/sci/engine/vm_types.cpp
+++ b/engines/sci/engine/vm_types.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -28,6 +28,43 @@
namespace Sci {
+SegmentId reg_t::getSegment() const {
+ if (getSciVersion() <= SCI_VERSION_2_1) {
+ return _segment;
+ } else {
+ // Return the lower 14 bits of the segment
+ return (_segment & 0x3FFF);
+ }
+}
+
+void reg_t::setSegment(SegmentId segment) {
+ if (getSciVersion() <= SCI_VERSION_2_1) {
+ _segment = segment;
+ } else {
+ // Set the lower 14 bits of the segment, and preserve the upper 2 ones for the offset
+ _segment = (_segment & 0xC000) | (segment & 0x3FFF);
+ }
+}
+
+uint32 reg_t::getOffset() const {
+ if (getSciVersion() <= SCI_VERSION_2_1) {
+ return _offset;
+ } else {
+ // Return the lower 16 bits from the offset, and the 17th and 18th bits from the segment
+ return ((_segment & 0xC000) << 2) | _offset;
+ }
+}
+
+void reg_t::setOffset(uint32 offset) {
+ if (getSciVersion() <= SCI_VERSION_2_1) {
+ _offset = offset;
+ } else {
+ // Store the lower 16 bits in the offset, and the 17th and 18th bits in the segment
+ _offset = offset & 0xFFFF;
+ _segment = ((offset & 0x30000) >> 2) | (_segment & 0x3FFF);
+ }
+}
+
reg_t reg_t::lookForWorkaround(const reg_t right, const char *operation) const {
SciTrackOriginReply originReply;
SciWorkaroundSolution solution = trackOriginAndFindWorkaround(0, arithmeticWorkarounds, &originReply);
diff --git a/engines/sci/engine/vm_types.h b/engines/sci/engine/vm_types.h
index 22bd8beaa1..af78bd0b84 100644
--- a/engines/sci/engine/vm_types.h
+++ b/engines/sci/engine/vm_types.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -35,36 +35,25 @@ struct reg_t {
SegmentId _segment;
uint16 _offset;
- inline SegmentId getSegment() const {
- return _segment;
- }
-
- inline void setSegment(SegmentId segment) {
- _segment = segment;
- }
-
- inline uint16 getOffset() const {
- return _offset;
- }
-
- inline void setOffset(uint16 offset) {
- _offset = offset;
- }
+ SegmentId getSegment() const;
+ void setSegment(SegmentId segment);
+ uint32 getOffset() const;
+ void setOffset(uint32 offset);
inline void incOffset(int16 offset) {
setOffset(getOffset() + offset);
}
inline bool isNull() const {
- return (_offset | getSegment()) == 0;
+ return (getOffset() | getSegment()) == 0;
}
inline uint16 toUint16() const {
- return _offset;
+ return (uint16)getOffset();
}
inline int16 toSint16() const {
- return (int16)_offset;
+ return (int16)getOffset();
}
bool isNumber() const {
diff --git a/engines/sci/engine/workarounds.cpp b/engines/sci/engine/workarounds.cpp
index 154ac8f8b4..37e46b7a96 100644
--- a/engines/sci/engine/workarounds.cpp
+++ b/engines/sci/engine/workarounds.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -32,126 +32,139 @@ namespace Sci {
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry arithmeticWorkarounds[] = {
- { GID_CAMELOT, 92, 92, 0, "endingCartoon2", "changeState", 0x20d, 0, { WORKAROUND_FAKE, 0 } }, // op_lai: during the ending, sub gets called with no parameters, uses parameter 1 which is theGrail in this case - bug #3044734
- { GID_ECOQUEST2, 100, 0, 0, "Rain", "points", 0xcc6, 0, { WORKAROUND_FAKE, 0 } }, // op_or: when giving the papers to the customs officer, gets called against a pointer instead of a number - bug #3034464
- { GID_ECOQUEST2, 100, 0, 0, "Rain", "points", 0xce0, 0, { WORKAROUND_FAKE, 0 } }, // Same as above, for the Spanish version - bug #3313962
- { GID_FANMADE, 516, 983, 0, "Wander", "setTarget", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_mul: The Legend of the Lost Jewel Demo (fan made): called with object as second parameter when attacked by insects - bug #3038913
+ { GID_CAMELOT, 92, 92, 0, "endingCartoon2", "changeState", 0x20d, 0, { WORKAROUND_FAKE, 0 } }, // op_lai: during the ending, sub gets called with no parameters, uses parameter 1 which is theGrail in this case - bug #5237
+ { GID_ECOQUEST2, 100, 0, 0, "Rain", "points", 0xcc6, 0, { WORKAROUND_FAKE, 0 } }, // op_or: when giving the papers to the customs officer, gets called against a pointer instead of a number - bug #4939
+ { GID_ECOQUEST2, 100, 0, 0, "Rain", "points", 0xce0, 0, { WORKAROUND_FAKE, 0 } }, // Same as above, for the Spanish version - bug #5750
+ { GID_FANMADE, 516, 983, 0, "Wander", "setTarget", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_mul: The Legend of the Lost Jewel Demo (fan made): called with object as second parameter when attacked by insects - bug #5124
{ GID_GK1, 800,64992, 0, "Fwd", "doit", -1, 0, { WORKAROUND_FAKE, 1 } }, // op_gt: when Mosely finds Gabriel and Grace near the end of the game, compares the Grooper object with 7
{ GID_HOYLE4, 700, -1, 1, "Code", "doit", -1, 0, { WORKAROUND_FAKE, 1 } }, // op_add: while bidding in Bridge, an object ("Bid") is added to an object in another segment ("hand3")
{ GID_ICEMAN, 199, 977, 0, "Grooper", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_add: While dancing with the girl
{ GID_MOTHERGOOSE256, -1, 999, 0, "Event", "new", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_and: constantly during the game (SCI1 version)
- { GID_MOTHERGOOSE256, -1, 4, 0, "rm004", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_or: when going north and reaching the castle (rooms 4 and 37) - bug #3038228
+ { GID_MOTHERGOOSE256, -1, 4, 0, "rm004", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_or: when going north and reaching the castle (rooms 4 and 37) - bug #5101
{ GID_MOTHERGOOSEHIRES,90, 90, 0, "newGameButton", "select", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_ge: MUMG Deluxe, when selecting "New Game" in the main menu. It tries to compare an integer with a list. Needs to return false for the game to continue.
{ GID_PHANTASMAGORIA, 902, 0, 0, "", "export 7", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_shr: when starting a chapter in Phantasmagoria
{ GID_QFG1VGA, 301, 928, 0, "Blink", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_div: when entering the inn, gets called with 1 parameter, but 2nd parameter is used for div which happens to be an object
- { GID_QFG2, 200, 200, 0, "astro", "messages", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_lsi: when getting asked for your name by the astrologer bug #3039879
+ { GID_QFG2, 200, 200, 0, "astro", "messages", -1, 0, { WORKAROUND_FAKE, 0 } }, // op_lsi: when getting asked for your name by the astrologer bug #5152
{ GID_QFG4, 710,64941, 0, "RandCycle", "doit", -1, 0, { WORKAROUND_FAKE, 1 } }, // op_gt: when the tentacle appears in the third room of the caves
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry uninitializedReadWorkarounds[] = {
- { GID_CAMELOT, 40, 40, 0, "Rm40", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // when looking at the ground at the pool of Siloam - bug #3614968
- { GID_CASTLEBRAIN, 280, 280, 0, "programmer", "dispatchEvent", -1, 0, { WORKAROUND_FAKE, 0xf } }, // pressing 'q' on the computer screen in the robot room, and closing the help dialog that pops up (bug #3039656). Moves the cursor to the view with the ID returned (in this case, the robot hand)
- { GID_CNICK_KQ, -1, 0, 1, "Character", "say", -1, -1, { WORKAROUND_FAKE, 0 } }, // checkers/backgammon, like in hoyle 3 - temps 504 and 505 - bug #3606025
+ { GID_CAMELOT, 40, 40, 0, "Rm40", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // when looking at the ground at the pool of Siloam - bug #6401
+ { GID_CASTLEBRAIN, 280, 280, 0, "programmer", "dispatchEvent", -1, 0, { WORKAROUND_FAKE, 0xf } }, // pressing 'q' on the computer screen in the robot room, and closing the help dialog that pops up (bug #5143). Moves the cursor to the view with the ID returned (in this case, the robot hand)
+ { GID_CNICK_KQ, -1, 0, 1, "Character", "say", -1, -1, { WORKAROUND_FAKE, 0 } }, // checkers/backgammon, like in hoyle 3 - temps 504 and 505 - bug #6255
{ GID_CNICK_KQ, -1, 700, 0, "gcWindow", "open", -1, -1, { WORKAROUND_FAKE, 0 } }, // when entering the control menu, like in hoyle 3
+ { GID_CNICK_KQ, 300, 303, 0, "theDoubleCube", "<noname520>", -1, 5, { WORKAROUND_FAKE, 0 } }, // while playing backgammon with doubling enabled - bug #6426 (same as the theDoubleCube::make workaround for Hoyle 3)
+ { GID_CNICK_KQ, 300, 303, 0, "theDoubleCube", "<noname519>", -1, 9, { WORKAROUND_FAKE, 0 } }, // when accepting a double, while playing backgammon with doubling enabled (same as the theDoubleCube::accept workaround for Hoyle 3)
+ { GID_CNICK_LAURABOW, -1, 0, 1, "Character", "say", -1, -1, { WORKAROUND_FAKE, 0 } }, // Yatch, like in hoyle 3 - temps 504 and 505 - bug #6424
+ { GID_CNICK_LAURABOW, -1, 700, 0, NULL, "open", -1, -1, { WORKAROUND_FAKE, 0 } }, // when entering control menu - bug #6423 (same as the gcWindow workaround for Hoyle 3)
+ { GID_CNICK_LAURABOW,100, 100, 0, NULL, "<noname144>", -1, 1, { WORKAROUND_FAKE, 0 } }, // while playing domino - bug #6429 (same as the dominoHand2 workaround for Hoyle 3)
+ { GID_CNICK_LAURABOW,100, 110, 0, NULL, "doit", -1, -1, { WORKAROUND_FAKE, 0 } }, // when changing the "Dominoes per hand" setting - bug #6430
{ GID_CNICK_LONGBOW, 0, 0, 0, "RH Budget", "init", -1, 1, { WORKAROUND_FAKE, 0 } }, // when starting the game
{ GID_ECOQUEST, -1, -1, 0, NULL, "doVerb", -1, 0, { WORKAROUND_FAKE, 0 } }, // almost clicking anywhere triggers this in almost all rooms
{ GID_FANMADE, 516, 979, 0, "", "export 0", -1, 20, { WORKAROUND_FAKE, 0 } }, // Happens in Grotesteing after the logos
- { GID_FANMADE, 528, 990, 0, "GDialog", "doit", -1, 4, { WORKAROUND_FAKE, 0 } }, // Happens in Cascade Quest when closing the glossary - bug #3038757
- { GID_FANMADE, 488, 1, 0, "RoomScript", "doit", 0x1f17, 1, { WORKAROUND_FAKE, 0 } }, // Happens in Ocean Battle while playing - bug #3059871
+ { GID_FANMADE, 528, 990, 0, "GDialog", "doit", -1, 4, { WORKAROUND_FAKE, 0 } }, // Happens in Cascade Quest when closing the glossary - bug #5116
+ { GID_FANMADE, 488, 1, 0, "RoomScript", "doit", 0x1f17, 1, { WORKAROUND_FAKE, 0 } }, // Happens in Ocean Battle while playing - bug #5335
{ GID_FREDDYPHARKAS, -1, 24, 0, "gcWin", "open", -1, 5, { WORKAROUND_FAKE, 0xf } }, // is used as priority for game menu
{ GID_FREDDYPHARKAS, -1, 31, 0, "quitWin", "open", -1, 5, { WORKAROUND_FAKE, 0xf } }, // is used as priority for game menu
- { GID_FREDDYPHARKAS, 540, 540, 0, "WaverCode", "init", -1, -1, { WORKAROUND_FAKE, 0 } }, // Gun pratice mini-game (bug #3044218)
+ { GID_FREDDYPHARKAS, 540, 540, 0, "WaverCode", "init", -1, -1, { WORKAROUND_FAKE, 0 } }, // Gun pratice mini-game - bug #5232
{ GID_GK1, -1, 64950, -1, "Feature", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // sometimes when walk-clicking
{ GID_GK2, -1, 11, 0, "", "export 10", -1, 3, { WORKAROUND_FAKE, 0 } }, // called when the game starts
{ GID_GK2, -1, 11, 0, "", "export 10", -1, 4, { WORKAROUND_FAKE, 0 } }, // called during the game
{ GID_HOYLE1, 4, 104, 0, "GinRummyCardList", "calcRuns", -1, 4, { WORKAROUND_FAKE, 0 } }, // Gin Rummy / right when the game starts
{ GID_HOYLE1, 5, 204, 0, "tableau", "checkRuns", -1, 2, { WORKAROUND_FAKE, 0 } }, // Cribbage / during the game
- { GID_HOYLE1, 3, 16, 0, "", "export 0", 0x37c, 3, { WORKAROUND_FAKE, 0 } }, // Hearts / during the game - bug #3052359
- { GID_HOYLE1, -1, 997, 0, "MenuBar", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // When changing game speed settings - bug #3108012
+ { GID_HOYLE1, 3, 16, 0, "", "export 0", 0x37c, 3, { WORKAROUND_FAKE, 0 } }, // Hearts / during the game - bug #5299
+ { GID_HOYLE1, -1, 997, 0, "MenuBar", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // When changing game speed settings - bug #5512
{ GID_HOYLE3, -1, 0, 1, "Character", "say", -1, -1, { WORKAROUND_FAKE, 0 } }, // when starting checkers or dominoes, first time a character says something - temps 504 and 505
{ GID_HOYLE3, -1, 700, 0, "gcWindow", "open", -1, -1, { WORKAROUND_FAKE, 0 } }, // when entering control menu
- { GID_HOYLE3, 100, 100, 0, "dominoHand2", "cue", -1, 1, { WORKAROUND_FAKE, 0 } }, // while playing domino - bug #3036918
- { GID_HOYLE4, -1, 0, 0, NULL, "open", -1, -1, { WORKAROUND_FAKE, 0 } }, // when selecting "Control" from the menu (temp vars 0-3) - bug #3039294
- { GID_HOYLE4, 910, 18, 0, NULL, "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // during tutorial - bug #3042756
- { GID_HOYLE4, 910, 910, 0, NULL, "setup", -1, 3, { WORKAROUND_FAKE, 0 } }, // when selecting "Tutorial" from the main menu - bug #3039294
+ { GID_HOYLE3, 100, 100, 0, "dominoHand2", "cue", -1, 1, { WORKAROUND_FAKE, 0 } }, // while playing domino - bug #5042
+ { GID_HOYLE3, 100, 110, 0, "OKButton", "doit", -1, -1, { WORKAROUND_FAKE, 0 } }, // when changing the "Dominoes per hand" setting - bug #6430
+ { GID_HOYLE3, 300, 303, 0, "theDoubleCube", "make", -1, 5, { WORKAROUND_FAKE, 0 } }, // while playing backgammon with doubling enabled
+ { GID_HOYLE3, 300, 303, 0, "theDoubleCube", "accept", -1, 9, { WORKAROUND_FAKE, 0 } }, // when accepting a double, while playing backgammon with doubling enabled
+ { GID_HOYLE4, -1, 0, 0, NULL, "open", -1, -1, { WORKAROUND_FAKE, 0 } }, // when selecting "Control" from the menu (temp vars 0-3) - bug #5132
+ { GID_HOYLE4, 910, 18, 0, NULL, "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // during tutorial - bug #5213
+ { GID_HOYLE4, 910, 910, 0, NULL, "setup", -1, 3, { WORKAROUND_FAKE, 0 } }, // when selecting "Tutorial" from the main menu - bug #5132
{ GID_HOYLE4, 700, 700, 1, "BridgeHand", "calcQTS", -1, 3, { WORKAROUND_FAKE, 0 } }, // when placing a bid in bridge (always)
- { GID_HOYLE4, 700, 710, 1, "BridgeStrategyPlay", "checkSplitTops", -1, 10, { WORKAROUND_FAKE, 0 } }, // while playing bridge, objects LeadReturn_Trump, SecondSeat_Trump, ThirdSeat_Trump and others - bug #3361925
+ { GID_HOYLE4, 700, 710, 1, "BridgeStrategyPlay", "checkSplitTops", -1, 10, { WORKAROUND_FAKE, 0 } }, // while playing bridge, objects LeadReturn_Trump, SecondSeat_Trump, ThirdSeat_Trump and others - bug #5794
{ GID_HOYLE4, 700, -1, 1, "BridgeDefense", "think", -1, -1, { WORKAROUND_FAKE, 0 } }, // sometimes while playing bridge, temp var 3, 17 and others, objects LeadReturn_Trump, ThirdSeat_Trump and others
{ GID_HOYLE4, 700, 730, 1, "BridgeDefense", "beatTheirBest", -1, 3, { WORKAROUND_FAKE, 0 } }, // rarely while playing bridge
- { GID_HOYLE4, 700, -1, 1, "Code", "doit", -1, -1, { WORKAROUND_FAKE, 0 } }, // when placing a bid in bridge (always), temp var 11, 24, 27, 46, 75, objects compete_tree, compwe_tree, other1_tree, b1 - bugs #3292332 and #3361925
+ { GID_HOYLE4, 700, -1, 1, "Code", "doit", -1, -1, { WORKAROUND_FAKE, 0 } }, // when placing a bid in bridge (always), temp var 11, 24, 27, 46, 75, objects compete_tree, compwe_tree, other1_tree, b1 - bugs #5663 and #5794
+ { GID_HOYLE4, 700, 921, 0, "Print", "addEdit", -1, -1, { WORKAROUND_FAKE, 0 } }, // when saving the game (may also occur in other situations) - bug #6601
{ GID_HOYLE4, 300, 300, 0, "", "export 2", 0x1d4d, 0, { WORKAROUND_FAKE, 0 } }, // after passing around cards in hearts
- { GID_HOYLE4, 400, 400, 1, "GinHand", "calcRuns", -1, 4, { WORKAROUND_FAKE, 0 } }, // sometimes while playing Gin Rummy (e.g. when knocking and placing a card) - bug #3292334
- { GID_HOYLE4, 500, 17, 1, "Character", "say", -1, 504, { WORKAROUND_FAKE, 0 } }, // sometimes while playing Cribbage (e.g. when the opponent says "Last Card") - bug #3292327
- { GID_ISLANDBRAIN, 100, 937, 0, "IconBar", "dispatchEvent", -1, 58, { WORKAROUND_FAKE, 0 } }, // when using ENTER at the startup menu - bug #3045225
+ { GID_HOYLE4, 400, 400, 1, "GinHand", "calcRuns", -1, 4, { WORKAROUND_FAKE, 0 } }, // sometimes while playing Gin Rummy (e.g. when knocking and placing a card) - bug #5665
+ { GID_HOYLE4, 500, 17, 1, "Character", "say", -1, 504, { WORKAROUND_FAKE, 0 } }, // sometimes while playing Cribbage (e.g. when the opponent says "Last Card") - bug #5662
+ { GID_HOYLE4, -1, 937, 0, "IconBar", "dispatchEvent", -1, 408, { WORKAROUND_FAKE, 0 } }, // pressing ENTER on scoreboard while mouse is not on OK button, may not happen all the time - bug #6603
+ { GID_ISLANDBRAIN, 100, 937, 0, "IconBar", "dispatchEvent", -1, 58, { WORKAROUND_FAKE, 0 } }, // when using ENTER at the startup menu - bug #5241
{ GID_ISLANDBRAIN, 140, 140, 0, "piece", "init", -1, 3, { WORKAROUND_FAKE, 1 } }, // first puzzle right at the start, some initialization variable. bnt is done on it, and it should be non-0
{ GID_ISLANDBRAIN, 200, 268, 0, "anElement", "select", -1, 0, { WORKAROUND_FAKE, 0 } }, // elements puzzle, gets used before super TextIcon
{ GID_JONES, 1, 232, 0, "weekendText", "draw", 0x3d3, 0, { WORKAROUND_FAKE, 0 } }, // jones/cd only - gets called during the game
{ GID_JONES, 1, 255, 0, "", "export 0", -1, -1, { WORKAROUND_FAKE, 0 } }, // jones/cd only - called when a game ends, temps 13 and 14
{ GID_JONES, 764, 255, 0, "", "export 0", -1, -1, { WORKAROUND_FAKE, 0 } }, // jones/ega&vga only - called when the game starts, temps 13 and 14
- //{ GID_KQ5, -1, 0, 0, "", "export 29", -1, 3, { WORKAROUND_FAKE, 0xf } }, // called when playing harp for the harpies or when aborting dialog in toy shop, is used for kDoAudio - bug #3034700
+ //{ GID_KQ5, -1, 0, 0, "", "export 29", -1, 3, { WORKAROUND_FAKE, 0xf } }, // called when playing harp for the harpies or when aborting dialog in toy shop, is used for kDoAudio - bug #4961
// ^^ shouldn't be needed anymore, we got a script patch instead (kq5PatchCdHarpyVolume)
{ GID_KQ5, 25, 25, 0, "rm025", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // inside witch forest, when going to the room where the walking rock is
- { GID_KQ5, 55, 55, 0, "helpScript", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // when giving the tambourine to the monster in the labyrinth (only happens at one of the locations) - bug #3041262
+ { GID_KQ5, 55, 55, 0, "helpScript", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // when giving the tambourine to the monster in the labyrinth (only happens at one of the locations) - bug #5198
{ GID_KQ5, -1, 755, 0, "gcWin", "open", -1, -1, { WORKAROUND_FAKE, 0 } }, // when entering control menu in the FM-Towns version
- { GID_KQ6, -1, 30, 0, "rats", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // rats in the catacombs (temps 1 - 5) - bugs #3034597, #3035495, #3035824
- { GID_KQ6, 210, 210, 0, "rm210", "scriptCheck", -1, 0, { WORKAROUND_FAKE, 1 } }, // using inventory in that room - bug #3034565
+ { GID_KQ6, -1, 30, 0, "rats", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // rats in the catacombs (temps 1 - 5) - bugs #4958, #4998, #5017
+ { GID_KQ6, 210, 210, 0, "rm210", "scriptCheck", -1, 0, { WORKAROUND_FAKE, 1 } }, // using inventory in that room - bug #4953
{ GID_KQ6, 500, 500, 0, "rm500", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // going to island of the beast
{ GID_KQ6, 520, 520, 0, "rm520", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // going to boiling water trap on beast isle
{ GID_KQ6, -1, 903, 0, "controlWin", "open", -1, 4, { WORKAROUND_FAKE, 0 } }, // when opening the controls window (save, load etc)
- { GID_KQ6, -1, 907, 0, "tomato", "doVerb", -1, 2, { WORKAROUND_FAKE, 0 } }, // when looking at the rotten tomato in the inventory - bug #3059544
+ { GID_KQ6, -1, 907, 0, "tomato", "doVerb", -1, 2, { WORKAROUND_FAKE, 0 } }, // when looking at the rotten tomato in the inventory - bug #5331
+ { GID_KQ6, -1, 928, 0, NULL, "startText", -1, 0, { WORKAROUND_FAKE, 0 } }, // gets caused by Text+Audio support (see script patcher)
{ GID_KQ7, -1, 64996, 0, "User", "handleEvent", -1, 1, { WORKAROUND_FAKE, 0 } }, // called when pushing a keyboard key
- { GID_LAURABOW, 37, 0, 0, "CB1", "doit", -1, 1, { WORKAROUND_FAKE, 0 } }, // when going up the stairs (bug #3037694)
- { GID_LAURABOW, -1, 967, 0, "myIcon", "cycle", -1, 1, { WORKAROUND_FAKE, 0 } }, // having any portrait conversation coming up (initial bug #3034985)
+ { GID_LAURABOW, 37, 0, 0, "CB1", "doit", -1, 1, { WORKAROUND_FAKE, 0 } }, // when going up the stairs - bug #5084
+ { GID_LAURABOW, -1, 967, 0, "myIcon", "cycle", -1, 1, { WORKAROUND_FAKE, 0 } }, // having any portrait conversation coming up - initial bug #4971
{ GID_LAURABOW2, -1, 24, 0, "gcWin", "open", -1, 5, { WORKAROUND_FAKE, 0xf } }, // is used as priority for game menu
- { GID_LAURABOW2, -1, 21, 0, "dropCluesCode", "doit", -1, 1, { WORKAROUND_FAKE, 0x7fff } }, // when asking some questions (e.g. the reporter about the burglary, or the policeman about Ziggy). Must be big, as the game scripts perform lt on it and start deleting journal entries - bugs #3035068, #3036274
- { GID_LAURABOW2, -1, 90, 1, "MuseumActor", "init", -1, 6, { WORKAROUND_FAKE, 0 } }, // Random actors in museum (bug #3041257)
- { GID_LAURABOW2, 240, 240, 0, "sSteveAnimates", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // Steve Dorian's idle animation at the docks - bug #3036291
- { GID_LONGBOW, -1, 0, 0, "Longbow", "restart", -1, 0, { WORKAROUND_FAKE, 0 } }, // When canceling a restart game - bug #3046200
+ { GID_LAURABOW2, -1, 21, 0, "dropCluesCode", "doit", -1, 1, { WORKAROUND_FAKE, 0x7fff } }, // when asking some questions (e.g. the reporter about the burglary, or the policeman about Ziggy). Must be big, as the game scripts perform lt on it and start deleting journal entries - bugs #4979, #5026
+ { GID_LAURABOW2, -1, 90, 1, "MuseumActor", "init", -1, 6, { WORKAROUND_FAKE, 0 } }, // Random actors in museum - bug #5197
+ { GID_LAURABOW2, 240, 240, 0, "sSteveAnimates", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // Steve Dorian's idle animation at the docks - bug #5028
+ { GID_LAURABOW2, -1, 928, 0, NULL, "startText", -1, 0, { WORKAROUND_FAKE, 0 } }, // gets caused by Text+Audio support (see script patcher)
+ { GID_LONGBOW, -1, 0, 0, "Longbow", "restart", -1, 0, { WORKAROUND_FAKE, 0 } }, // When canceling a restart game - bug #5244
{ GID_LONGBOW, -1, 213, 0, "clear", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // When giving an answer using the druid hand sign code in any room
- { GID_LONGBOW, -1, 213, 0, "letter", "handleEvent", 0xa8, 1, { WORKAROUND_FAKE, 0 } }, // When using the druid hand sign code in any room - bug #3036601
+ { GID_LONGBOW, -1, 213, 0, "letter", "handleEvent", 0xa8, 1, { WORKAROUND_FAKE, 0 } }, // When using the druid hand sign code in any room - bug #5035
{ GID_LSL1, 250, 250, 0, "increase", "handleEvent", -1, 2, { WORKAROUND_FAKE, 0 } }, // casino, playing game, increasing bet
{ GID_LSL1, 720, 720, 0, "rm720", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // age check room
- { GID_LSL2, 38, 38, 0, "cloudScript", "changeState", -1, 1, { WORKAROUND_FAKE, 0 } }, // entering the room in the middle deck of the ship - bug #3036483
+ { GID_LSL2, 38, 38, 0, "cloudScript", "changeState", -1, 1, { WORKAROUND_FAKE, 0 } }, // entering the room in the middle deck of the ship - bug #5034
{ GID_LSL3, 340, 340, 0, "ComicScript", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // right after entering the 3 ethnic groups inside comedy club (temps 200, 201, 202, 203)
{ GID_LSL3, -1, 997, 0, "TheMenuBar", "handleEvent", -1, 1, { WORKAROUND_FAKE, 0xf } }, // when setting volume the first time, this temp is used to set volume on entry (normally it would have been initialized to 's')
- { GID_LSL6, 820, 82, 0, "", "export 0", -1, -1, { WORKAROUND_FAKE, 0 } }, // when touching the electric fence - bug #3038326
+ { GID_LSL6, 820, 82, 0, "", "export 0", -1, -1, { WORKAROUND_FAKE, 0 } }, // when touching the electric fence - bug #5103
{ GID_LSL6, -1, 85, 0, "washcloth", "doVerb", -1, 0, { WORKAROUND_FAKE, 0 } }, // washcloth in inventory
{ GID_LSL6, -1, 928, -1, "Narrator", "startText", -1, 0, { WORKAROUND_FAKE, 0 } }, // used by various objects that are even translated in foreign versions, that's why we use the base-class
{ GID_LSL6HIRES, 0, 85, 0, "LL6Inv", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // on startup
{ GID_LSL6HIRES, -1, 64950, 1, "Feature", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // at least when entering swimming pool area
{ GID_LSL6HIRES, -1, 64964, 0, "DPath", "init", -1, 1, { WORKAROUND_FAKE, 0 } }, // during the game
- { GID_MOTHERGOOSE256, -1, 0, 0, "MG", "doit", -1, 5, { WORKAROUND_FAKE, 0 } }, // SCI1.1: When moving the cursor all the way to the left during the game (bug #3043955)
- { GID_MOTHERGOOSE256, -1, 992, 0, "AIPath", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // Happens in the demo and full version. In the demo, it happens when walking two screens from mother goose's house to the north. In the full version, it happens in rooms 7 and 23 - bug #3049146
- { GID_MOTHERGOOSE256, 90, 90, 0, "introScript", "changeState", -1, 65, { WORKAROUND_FAKE, 0 } }, // SCI1(CD): At the very end, after the game is completed and restarted - bug #3268076
- { GID_MOTHERGOOSE256, 94, 94, 0, "sunrise", "changeState", -1, 367, { WORKAROUND_FAKE, 0 } }, // At the very end, after the game is completed - bug #3051163
+ { GID_MOTHERGOOSE256, -1, 0, 0, "MG", "doit", -1, 5, { WORKAROUND_FAKE, 0 } }, // SCI1.1: When moving the cursor all the way to the left during the game - bug #5224
+ { GID_MOTHERGOOSE256, -1, 992, 0, "AIPath", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // Happens in the demo and full version. In the demo, it happens when walking two screens from mother goose's house to the north. In the full version, it happens in rooms 7 and 23 - bug #5269
+ { GID_MOTHERGOOSE256, 90, 90, 0, "introScript", "changeState", -1, 65, { WORKAROUND_FAKE, 0 } }, // SCI1(CD): At the very end, after the game is completed and restarted - bug #5626
+ { GID_MOTHERGOOSE256, 94, 94, 0, "sunrise", "changeState", -1, 367, { WORKAROUND_FAKE, 0 } }, // At the very end, after the game is completed - bug #5294
{ GID_MOTHERGOOSEHIRES,-1,64950, 1, "Feature", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // right when clicking on a child at the start and probably also later
{ GID_MOTHERGOOSEHIRES,-1,64950, 1, "View", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // see above
- { GID_PEPPER, -1, 894, 0, "Package", "doVerb", -1, 3, { WORKAROUND_FAKE, 0 } }, // using the hand on the book in the inventory - bug #3040012
+ { GID_PEPPER, -1, 894, 0, "Package", "doVerb", -1, 3, { WORKAROUND_FAKE, 0 } }, // using the hand on the book in the inventory - bug #5154
{ GID_PEPPER, 150, 928, 0, "Narrator", "startText", -1, 0, { WORKAROUND_FAKE, 0 } }, // happens during the non-interactive demo of Pepper
{ GID_PQ4, -1, 25, 0, "iconToggle", "select", -1, 1, { WORKAROUND_FAKE, 0 } }, // when toggling the icon bar to auto-hide or not
{ GID_PQSWAT, -1, 64950, 0, "View", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // Using the menu in the beginning
{ GID_QFG1, -1, 210, 0, "Encounter", "init", 0xbd0, 0, { WORKAROUND_FAKE, 0 } }, // hq1: going to the brigands hideout
{ GID_QFG1, -1, 210, 0, "Encounter", "init", 0xbe4, 0, { WORKAROUND_FAKE, 0 } }, // qfg1: going to the brigands hideout
- { GID_QFG1VGA, 16, 16, 0, "lassoFailed", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // qfg1vga: casting the "fetch" spell in the screen with the flowers, temps 0 and 1 - bug #3053268
- { GID_QFG1VGA, -1, 210, 0, "Encounter", "init", 0xcee, 0, { WORKAROUND_FAKE, 0 } }, // qfg1vga: going to the brigands hideout - bug #3109299
+ { GID_QFG1VGA, 16, 16, 0, "lassoFailed", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // qfg1vga: casting the "fetch" spell in the screen with the flowers, temps 0 and 1 - bug #5309
+ { GID_QFG1VGA, -1, 210, 0, "Encounter", "init", 0xcee, 0, { WORKAROUND_FAKE, 0 } }, // qfg1vga: going to the brigands hideout - bug #5515
{ GID_QFG1VGA, -1, 210, 0, "Encounter", "init", 0xce7, 0, { WORKAROUND_FAKE, 0 } }, // qfg1vga: going to room 92
{ GID_QFG2, -1, 71, 0, "theInvSheet", "doit", -1, 1, { WORKAROUND_FAKE, 0 } }, // accessing the inventory
- { GID_QFG2, -1, 701, -1, "Alley", "at", -1, 0, { WORKAROUND_FAKE, 0 } }, // when walking inside the alleys in the town - bug #3035835 & #3038367
+ { GID_QFG2, -1, 701, -1, "Alley", "at", -1, 0, { WORKAROUND_FAKE, 0 } }, // when walking inside the alleys in the town - bug #5019 & #5106
{ GID_QFG2, -1, 990, 0, "Restore", "doit", -1, 364, { WORKAROUND_FAKE, 0 } }, // when pressing enter in restore dialog w/o any saved games present
- { GID_QFG2, 260, 260, 0, "abdulS", "changeState",0x2d22, -1, { WORKAROUND_FAKE, 0 } }, // During the thief's first mission (in the house), just before Abdul is about to enter the house (where you have to hide in the wardrobe), bug #3039891, temps 1 and 2
- { GID_QFG2, 260, 260, 0, "jabbarS", "changeState",0x2d22, -1, { WORKAROUND_FAKE, 0 } }, // During the thief's first mission (in the house), just before Jabbar is about to enter the house (where you have to hide in the wardrobe), bug #3040469, temps 1 and 2
- { GID_QFG2, 500, 500, 0, "lightNextCandleS", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // Inside the last room, while Ad Avis performs the ritual to summon the genie - bug #3148418
- { GID_QFG2, -1, 700, 0, NULL, "showSign", -1, 10, { WORKAROUND_FAKE, 0 } }, // Occurs sometimes when reading a sign in Raseir, Shapeir et al - bugs #3272735, #3275413
- { GID_QFG3, 510, 510, 0, "awardPrize", "changeState", -1, 0, { WORKAROUND_FAKE, 1 } }, // Simbani warrior challenge, after throwing the spears and retrieving the ring - bug #3049435. Must be non-zero, otherwise the prize is awarded twice - bug #3575570.
- { GID_QFG3, 140, 140, 0, "rm140", "init", 0x1008, 0, { WORKAROUND_FAKE, 0 } }, // when importing a character and selecting the previous profession - bug #3040460
- { GID_QFG3, 330, 330, -1, "Teller", "doChild", -1, -1, { WORKAROUND_FAKE, 0 } }, // when talking to King Rajah about "Rajah" (bug #3036390, temp 1) or "Tarna" (temp 0), or when clicking on yourself and saying "Greet" (bug #3039774, temp 1)
- { GID_QFG3, 700, 700, -1, "monsterIsDead", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // in the jungle, after winning any fight, bug #3040624
- { GID_QFG3, 470, 470, -1, "rm470", "notify", -1, 0, { WORKAROUND_FAKE, 0 } }, // closing the character screen in the Simbani village in the room with the bridge, bug #3040565
- { GID_QFG3, 490, 490, -1, "computersMove", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // when finishing awari game, bug #3040579
+ { GID_QFG2, 260, 260, 0, "abdulS", "changeState",0x2d22, -1, { WORKAROUND_FAKE, 0 } }, // During the thief's first mission (in the house), just before Abdul is about to enter the house (where you have to hide in the wardrobe), bug #5153, temps 1 and 2
+ { GID_QFG2, 260, 260, 0, "jabbarS", "changeState",0x2d22, -1, { WORKAROUND_FAKE, 0 } }, // During the thief's first mission (in the house), just before Jabbar is about to enter the house (where you have to hide in the wardrobe), bug #5164, temps 1 and 2
+ { GID_QFG2, 500, 500, 0, "lightNextCandleS", "changeState", -1, -1, { WORKAROUND_FAKE, 0 } }, // Inside the last room, while Ad Avis performs the ritual to summon the genie - bug #5566
+ { GID_QFG2, -1, 700, 0, NULL, "showSign", -1, 10, { WORKAROUND_FAKE, 0 } }, // Occurs sometimes when reading a sign in Raseir, Shapeir et al - bugs #5627, #5635
+ { GID_QFG3, 510, 510, 0, "awardPrize", "changeState", -1, 0, { WORKAROUND_FAKE, 1 } }, // Simbani warrior challenge, after throwing the spears and retrieving the ring - bug #5277. Must be non-zero, otherwise the prize is awarded twice - bug #6160
+ { GID_QFG3, 140, 140, 0, "rm140", "init", 0x1008, 0, { WORKAROUND_FAKE, 0 } }, // when importing a character and selecting the previous profession - bug #5163
+ { GID_QFG3, 330, 330, -1, "Teller", "doChild", -1, -1, { WORKAROUND_FAKE, 0 } }, // when talking to King Rajah about "Rajah" (bug #5033, temp 1) or "Tarna" (temp 0), or when clicking on yourself and saying "Greet" (bug #5148, temp 1)
+ { GID_QFG3, 700, 700, -1, "monsterIsDead", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // in the jungle, after winning any fight, bug #5169
+ { GID_QFG3, 470, 470, -1, "rm470", "notify", -1, 0, { WORKAROUND_FAKE, 0 } }, // closing the character screen in the Simbani village in the room with the bridge, bug #5165
+ { GID_QFG3, 490, 490, -1, "computersMove", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // when finishing awari game, bug #5167
{ GID_QFG3, 490, 490, -1, "computersMove", "changeState", 0xf53, 4, { WORKAROUND_FAKE, 0 } }, // also when finishing awari game
- { GID_QFG3, 851, 32, -1, "ProjObj", "doit", -1, 1, { WORKAROUND_FAKE, 0 } }, // near the end, when throwing the spear of death, bug #3050122
+ { GID_QFG3, 851, 32, -1, "ProjObj", "doit", -1, 1, { WORKAROUND_FAKE, 0 } }, // near the end, when throwing the spear of death, bug #5282
{ GID_QFG4, -1, 15, -1, "charInitScreen", "dispatchEvent", -1, 5, { WORKAROUND_FAKE, 0 } }, // floppy version, when viewing the character screen
{ GID_QFG4, -1, 64917, -1, "controlPlane", "setBitmap", -1, 3, { WORKAROUND_FAKE, 0 } }, // floppy version, when entering the game menu
{ GID_QFG4, -1, 64917, -1, "Plane", "setBitmap", -1, 3, { WORKAROUND_FAKE, 0 } }, // floppy version, happens sometimes in fight scenes
@@ -171,7 +184,10 @@ const SciWorkaroundEntry uninitializedReadWorkarounds[] = {
{ GID_SQ1, -1, 703, 0, "firePulsar", "changeState", 0x18a, 0, { WORKAROUND_FAKE, 0 } }, // export 1, but called locally (when shooting at aliens)
{ GID_SQ4, -1, 398, 0, "showBox", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // CD: called when rummaging in Software Excess bargain bin
{ GID_SQ4, -1, 928, -1, "Narrator", "startText", -1, 1000, { WORKAROUND_FAKE, 1 } }, // CD: happens in the options dialog and in-game when speech and subtitles are used simultaneously
- { GID_SQ5, 201, 201, 0, "buttonPanel", "doVerb", -1, 0, { WORKAROUND_FAKE, 1 } }, // when looking at the orange or red button - bug #3038563
+ { GID_SQ4, -1, 708, -1, "exitBut", "doVerb", -1, 0, { WORKAROUND_FAKE, 0 } }, // Floppy: happens, when looking at the "close" button in the sq4 hintbook - bug #6447
+ { GID_SQ4, -1, 708, -1, "prevBut", "doVerb", -1, 0, { WORKAROUND_FAKE, 0 } }, // Floppy: happens, when looking at the "previous" button in the sq4 hintbook - bug #6447
+ { GID_SQ4, -1, 708, -1, "nextBut", "doVerb", -1, 0, { WORKAROUND_FAKE, 0 } }, // Floppy: happens, when looking at the "next" button in the sq4 hintbook - bug #6447
+ { GID_SQ5, 201, 201, 0, "buttonPanel", "doVerb", -1, 0, { WORKAROUND_FAKE, 1 } }, // when looking at the orange or red button - bug #5112
{ GID_SQ6, -1, 0, 0, "SQ6", "init", -1, 2, { WORKAROUND_FAKE, 0 } }, // Demo and full version: called when the game starts (demo: room 0, full: room 100)
{ GID_SQ6, -1, 64950, -1, "Feature", "handleEvent", -1, 0, { WORKAROUND_FAKE, 0 } }, // called when pressing "Start game" in the main menu, when entering the Orion's Belt bar (room 300), and perhaps other places
{ GID_SQ6, -1, 64964, 0, "DPath", "init", -1, 1, { WORKAROUND_FAKE, 0 } }, // during the game
@@ -185,25 +201,33 @@ const SciWorkaroundEntry kAbs_workarounds[] = {
{ GID_HOYLE1, 2, 2, 0, "room2", "doit", -1, 0, { WORKAROUND_FAKE, 0x3e9 } }, // old maid - called with objects instead of integers
{ GID_HOYLE1, 3, 3, 0, "room3", "doit", -1, 0, { WORKAROUND_FAKE, 0x3e9 } }, // hearts - called with objects instead of integers
{ GID_QFG1VGA, -1, -1, 0, NULL, "doit", -1, 0, { WORKAROUND_FAKE, 0x3e9 } }, // when the game is patched with the NRS patch
- { GID_QFG3 , -1, -1, 0, NULL, "doit", -1, 0, { WORKAROUND_FAKE, 0x3e9 } }, // when the game is patched with the NRS patch (bugs #3528416, #3528542)
+ { GID_QFG3 , -1, -1, 0, NULL, "doit", -1, 0, { WORKAROUND_FAKE, 0x3e9 } }, // when the game is patched with the NRS patch - bugs #6042, #6043
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kCelHigh_workarounds[] = {
- { GID_KQ5, -1, 255, 0, "deathIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // english floppy: when getting beaten up in the inn and probably more, called with 2nd parameter as object - bug #3037003
+ { GID_KQ5, -1, 255, 0, "deathIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // english floppy: when getting beaten up in the inn and probably more, called with 2nd parameter as object - bug #5049
{ GID_PQ2, -1, 255, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when showing picture within windows, called with 2nd/3rd parameters as objects
- { GID_SQ1, 1, 255, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // DEMO: Called with 2nd/3rd parameters as objects when clicking on the menu - bug #3035720
- { GID_FANMADE, -1, 979, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // In The Gem Scenario and perhaps other fanmade games, this is called with 2nd/3rd parameters as objects - bug #3039679
+ { GID_SQ1, 1, 255, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // DEMO: Called with 2nd/3rd parameters as objects when clicking on the menu - bug #5012
+ { GID_FANMADE, -1, 979, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // In The Gem Scenario and perhaps other fanmade games, this is called with 2nd/3rd parameters as objects - bug #5144
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kCelWide_workarounds[] = {
- { GID_KQ5, -1, 255, 0, "deathIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // english floppy: when getting beaten up in the inn and probably more, called with 2nd parameter as object - bug #3037003
+ { GID_KQ5, -1, 255, 0, "deathIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // english floppy: when getting beaten up in the inn and probably more, called with 2nd parameter as object - bug #5049
{ GID_PQ2, -1, 255, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when showing picture within windows, called with 2nd/3rd parameters as objects
- { GID_SQ1, 1, 255, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // DEMO: Called with 2nd/3rd parameters as objects when clicking on the menu - bug #3035720
- { GID_FANMADE, -1, 979, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // In The Gem Scenario and perhaps other fanmade games, this is called with 2nd/3rd parameters as objects - bug #3039679
+ { GID_SQ1, 1, 255, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // DEMO: Called with 2nd/3rd parameters as objects when clicking on the menu - bug #5012
+ { GID_FANMADE, -1, 979, 0, "DIcon", "setSize", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // In The Gem Scenario and perhaps other fanmade games, this is called with 2nd/3rd parameters as objects - bug #5144
+ SCI_WORKAROUNDENTRY_TERMINATOR
+};
+
+// gameID, room,script,lvl, object-name, method-name, call,index, workaround
+const SciWorkaroundEntry kDeleteKey_workarounds[] = {
+ { GID_HOYLE4, 300, 999, 0, "handleEventList", "delete", -1, 0, { WORKAROUND_IGNORE, 0 } }, // restarting hearts, while tray is shown - bug #6604
+ { GID_HOYLE4, 500, 999, 0, "handleEventList", "delete", -1, 0, { WORKAROUND_IGNORE, 0 } }, // restarting cribbage, while tray is shown - bug #6604
+ { GID_HOYLE4, 975, 999, 0, "handleEventList", "delete", -1, 0, { WORKAROUND_IGNORE, 0 } }, // going back to gamelist from hearts/cribbage, while tray is shown - bug #6604
SCI_WORKAROUNDENTRY_TERMINATOR
};
@@ -212,6 +236,7 @@ const SciWorkaroundEntry kDeviceInfo_workarounds[] = {
{ GID_FANMADE, -1, 994, 1, "Game", "save", 0xd1c, 0, { WORKAROUND_STILLCALL, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (Cascade Quest)
{ GID_FANMADE, -1, 994, 1, "Game", "save", 0xe55, 0, { WORKAROUND_STILLCALL, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (Demo Quest)
{ GID_FANMADE, -1, 994, 1, "Game", "save", 0xe57, 0, { WORKAROUND_STILLCALL, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (I Want My C64 Back)
+ { GID_FANMADE, -1, 994, 0, "Black", "save", 0xa, 0, { WORKAROUND_IGNORE, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (Black Cauldron Remake)
{ GID_FANMADE, -1, 994, 1, "Game", "save", 0xe5c, 0, { WORKAROUND_STILLCALL, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (Most of them)
{ GID_FANMADE, -1, 994, 1, "Game", "restore", 0xd1c, 0, { WORKAROUND_STILLCALL, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (Cascade Quest)
{ GID_FANMADE, -1, 994, 1, "Game", "restore", 0xe55, 0, { WORKAROUND_STILLCALL, 0 } }, // In fanmade games, this is called with one parameter for CurDevice (Demo Quest)
@@ -224,9 +249,9 @@ const SciWorkaroundEntry kDeviceInfo_workarounds[] = {
const SciWorkaroundEntry kDisplay_workarounds[] = {
{ GID_ISLANDBRAIN, 300, 300, 0, "geneDude", "show", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when looking at the gene explanation chart - a parameter is an object
{ GID_PQ2, 23, 23, 0, "rm23Script", "elements", 0x4ae, 0, { WORKAROUND_IGNORE, 0 } }, // when looking at the 2nd page of pate's file - 0x75 as id
- { GID_PQ2, 23, 23, 0, "rm23Script", "elements", 0x4c1, 0, { WORKAROUND_IGNORE, 0 } }, // when looking at the 2nd page of pate's file - 0x75 as id (another pq2 version, bug #3043904)
+ { GID_PQ2, 23, 23, 0, "rm23Script", "elements", 0x4c1, 0, { WORKAROUND_IGNORE, 0 } }, // when looking at the 2nd page of pate's file - 0x75 as id (another pq2 version, bug #5223)
{ GID_QFG1, 11, 11, 0, "battle", "<noname90>", -1, 0, { WORKAROUND_IGNORE, 0 } }, // DEMO: When entering battle, 0x75 as id
- { GID_SQ4, 397, 0, 0, "", "export 12", -1, 0, { WORKAROUND_IGNORE, 0 } }, // FLOPPY: when going into the computer store (bug #3044044)
+ { GID_SQ4, 397, 0, 0, "", "export 12", -1, 0, { WORKAROUND_IGNORE, 0 } }, // FLOPPY: when going into the computer store - bug #5227
{ GID_SQ4, 391, 391, 0, "doCatalog", "mode", 0x84, 0, { WORKAROUND_IGNORE, 0 } }, // CD: clicking on catalog in roboter sale - a parameter is an object
{ GID_SQ4, 391, 391, 0, "choosePlug", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // CD: ordering connector in roboter sale - a parameter is an object
SCI_WORKAROUNDENTRY_TERMINATOR
@@ -234,13 +259,13 @@ const SciWorkaroundEntry kDisplay_workarounds[] = {
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kDirLoop_workarounds[] = {
- { GID_KQ4, 4, 992, 0, "Avoid", "doit", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when the ogre catches you in front of his house, second parameter points to the same object as the first parameter, instead of being an integer (the angle) - bug #3042964
+ { GID_KQ4, 4, 992, 0, "Avoid", "doit", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when the ogre catches you in front of his house, second parameter points to the same object as the first parameter, instead of being an integer (the angle) - bug #5217
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kDisposeScript_workarounds[] = {
- { GID_LAURABOW, 777, 777, 0, "myStab", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // DEMO: after the will is signed, parameter 0 is an object - bug #3034907
+ { GID_LAURABOW, 777, 777, 0, "myStab", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // DEMO: after the will is signed, parameter 0 is an object - bug #4967
{ GID_QFG1, -1, 64, 0, "rm64", "dispose", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when leaving graveyard, parameter 0 is an object
{ GID_SQ4, 150, 151, 0, "fightScript", "dispose", -1, 0, { WORKAROUND_IGNORE, 0 } }, // during fight with Vohaul, parameter 0 is an object
{ GID_SQ4, 150, 152, 0, "driveCloseUp", "dispose", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when choosing "beam download", parameter 0 is an object
@@ -249,26 +274,26 @@ const SciWorkaroundEntry kDisposeScript_workarounds[] = {
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kDoSoundFade_workarounds[] = {
- { GID_KQ5, 213, 989, 0, "globalSound3", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // english floppy: when bandits leave the secret temple, parameter 4 is an object - bug #3037594
+ { GID_KQ5, 213, 989, 0, "globalSound3", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // english floppy: when bandits leave the secret temple, parameter 4 is an object - bug #5078
{ GID_KQ6, 105, 989, 0, "globalSound", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // floppy: during intro, parameter 4 is an object
- { GID_KQ6, 460, 989, 0, "globalSound2", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // after pulling the black widow's web on the isle of wonder, parameter 4 is an object - bug #3034567
+ { GID_KQ6, 460, 989, 0, "globalSound2", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // after pulling the black widow's web on the isle of wonder, parameter 4 is an object - bug #4954
{ GID_QFG4, -1, 64989, 0, "longSong", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // CD version: many places, parameter 4 is an object (longSong)
- { GID_SQ5, 800, 989, 0, "sq5Music1", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when cutting the wrong part of Goliath with the laser - bug #3614145
+ { GID_SQ5, 800, 989, 0, "sq5Music1", "fade", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when cutting the wrong part of Goliath with the laser - bug #6341
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kGetAngle_workarounds[] = {
{ GID_FANMADE, 516, 992, 0, "Motion", "init", -1, 0, { WORKAROUND_FAKE, 0 } }, // The Legend of the Lost Jewel Demo (fan made): called with third/fourth parameters as objects
- { GID_KQ6, -1, 752, 0, "throwDazzle", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // room 740/790 after the Genie is exposed in the Palace (short and long ending), it starts shooting lightning bolts around. An extra 5th parameter is passed - bug #3034610 & #3041734
- { GID_SQ1, -1, 927, 0, "PAvoider", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // all rooms in Ulence Flats after getting the Pilot Droid: called with a single parameter when the droid is in Roger's path - bug #3513207
+ { GID_KQ6, -1, 752, 0, "throwDazzle", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // room 740/790 after the Genie is exposed in the Palace (short and long ending), it starts shooting lightning bolts around. An extra 5th parameter is passed - bug #4959 & #5203
+ { GID_SQ1, -1, 927, 0, "PAvoider", "doit", -1, 0, { WORKAROUND_FAKE, 0 } }, // all rooms in Ulence Flats after getting the Pilot Droid: called with a single parameter when the droid is in Roger's path - bug #6016
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kFindKey_workarounds[] = {
- { GID_ECOQUEST2, 100, 999, 0, "myList", "contains", -1, 0, { WORKAROUND_FAKE, 0 } }, // When Noah Greene gives Adam the Ecorder, and just before the game gives a demonstration, a null reference to a list is passed - bug #3035186
- { GID_HOYLE4, 300, 999, 0, "Piles", "contains", -1, 0, { WORKAROUND_FAKE, 0 } }, // When passing the three cards in Hearts, a null reference to a list is passed - bug #3292333
+ { GID_ECOQUEST2, 100, 999, 0, "myList", "contains", -1, 0, { WORKAROUND_FAKE, 0 } }, // When Noah Greene gives Adam the Ecorder, and just before the game gives a demonstration, a null reference to a list is passed - bug #4987
+ { GID_HOYLE4, 300, 999, 0, "Piles", "contains", -1, 0, { WORKAROUND_FAKE, 0 } }, // When passing the three cards in Hearts, a null reference to a list is passed - bug #5664
SCI_WORKAROUNDENTRY_TERMINATOR
};
@@ -276,18 +301,18 @@ const SciWorkaroundEntry kFindKey_workarounds[] = {
const SciWorkaroundEntry kGraphDrawLine_workarounds[] = {
{ GID_ISLANDBRAIN, 300, 300, 0, "dudeViewer", "show", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when looking at the gene explanation chart, gets called with 1 extra parameter
{ GID_SQ1, 43, 43, 0, "someoneDied", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when ordering beer, gets called with 1 extra parameter
- { GID_SQ1, 71, 71, 0, "destroyXenon", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // during the Xenon destruction cutscene (which results in death), gets called with 1 extra parameter - bug #3040894
- { GID_SQ1, 53, 53, 0, "blastEgo", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when Roger is found and zapped by the cleaning robot, gets called with 1 extra parameter - bug #3040905
+ { GID_SQ1, 71, 71, 0, "destroyXenon", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // during the Xenon destruction cutscene (which results in death), gets called with 1 extra parameter - bug #5176
+ { GID_SQ1, 53, 53, 0, "blastEgo", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when Roger is found and zapped by the cleaning robot, gets called with 1 extra parameter - bug #5177
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kGraphSaveBox_workarounds[] = {
{ GID_CASTLEBRAIN, 420, 427, 0, "alienIcon", "select", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when selecting a card during the alien card game, gets called with 1 extra parameter
- { GID_ISLANDBRAIN, 290, 291, 0, "upElevator", "changeState",0x201f, 0, { WORKAROUND_STILLCALL, 0 } }, // when testing in the elevator puzzle, gets called with 1 argument less - 15 is on stack - bug #3034485
+ { GID_ISLANDBRAIN, 290, 291, 0, "upElevator", "changeState",0x201f, 0, { WORKAROUND_STILLCALL, 0 } }, // when testing in the elevator puzzle, gets called with 1 argument less - 15 is on stack - bug #4943
{ GID_ISLANDBRAIN, 290, 291, 0, "downElevator", "changeState",0x201f, 0, { WORKAROUND_STILLCALL, 0 } }, // see above
{ GID_ISLANDBRAIN, 290, 291, 0, "correctElevator", "changeState",0x201f, 0, { WORKAROUND_STILLCALL, 0 } }, // see above (when testing the correct solution)
- { GID_PQ3, 202, 202, 0, "MapEdit", "movePt", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters - bug #3038077
+ { GID_PQ3, 202, 202, 0, "MapEdit", "movePt", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters - bug #5099
SCI_WORKAROUNDENTRY_TERMINATOR
};
@@ -317,12 +342,12 @@ const SciWorkaroundEntry kGraphRedrawBox_workarounds[] = {
{ GID_SQ4, 406, 406, 0, "swimAndShoot", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // skateOrama when "swimming" in the air - accidental additional parameter specified
{ GID_SQ4, 410, 410, 0, "swimAfterEgo", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // skateOrama when "swimming" in the air - accidental additional parameter specified
{ GID_SQ4, 411, 411, 0, "swimAndShoot", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // skateOrama when "swimming" in the air - accidental additional parameter specified
- { GID_SQ4, 150, 150, 0, "laserScript", "changeState", 0xb2, 0, { WORKAROUND_STILLCALL, 0 } }, // when visiting the pedestral where Roger Jr. is trapped, before trashing the brain icon in the programming chapter, accidental additional parameter specified - bug #3094235
- { GID_SQ4, 150, 150, 0, "laserScript", "changeState", 0x16, 0, { WORKAROUND_STILLCALL, 0 } }, // same as above, for the German version - bug #3116892
+ { GID_SQ4, 150, 150, 0, "laserScript", "changeState", 0xb2, 0, { WORKAROUND_STILLCALL, 0 } }, // when visiting the pedestral where Roger Jr. is trapped, before trashing the brain icon in the programming chapter, accidental additional parameter specified - bug #5479
+ { GID_SQ4, 150, 150, 0, "laserScript", "changeState", 0x16, 0, { WORKAROUND_STILLCALL, 0 } }, // same as above, for the German version - bug #5527
{ GID_SQ4, -1, 704, 0, "shootEgo", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // When shot by Droid in Super Computer Maze (Rooms 500, 505, 510...) - accidental additional parameter specified
- { GID_KQ5, -1, 981, 0, "myWindow", "dispose", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // Happens in the floppy version, when closing any dialog box, accidental additional parameter specified - bug #3036331
+ { GID_KQ5, -1, 981, 0, "myWindow", "dispose", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // Happens in the floppy version, when closing any dialog box, accidental additional parameter specified - bug #5031
{ GID_KQ5, -1, 995, 0, "invW", "doit", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // Happens in the floppy version, when closing the inventory window, accidental additional parameter specified
- { GID_KQ5, -1, 995, 0, "", "export 0", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // Happens in the floppy version, when opening the gem pouch, accidental additional parameter specified - bug #3039395
+ { GID_KQ5, -1, 995, 0, "", "export 0", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // Happens in the floppy version, when opening the gem pouch, accidental additional parameter specified - bug #5138
{ GID_KQ5, -1, 403, 0, "KQ5Window", "dispose", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // Happens in the FM Towns version when closing any dialog box, accidental additional parameter specified
SCI_WORKAROUNDENTRY_TERMINATOR
};
@@ -330,42 +355,49 @@ const SciWorkaroundEntry kGraphRedrawBox_workarounds[] = {
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kGraphUpdateBox_workarounds[] = {
{ GID_ECOQUEST2, 100, 333, 0, "showEcorder", "changeState", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // necessary workaround for our ecorder script patch, because there isn't enough space to patch the function
- { GID_PQ3, 202, 202, 0, "MapEdit", "addPt", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters - bug #3038077
- { GID_PQ3, 202, 202, 0, "MapEdit", "movePt", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters - bug #3038077
+ { GID_PQ3, 202, 202, 0, "MapEdit", "addPt", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters - bug #5099
+ { GID_PQ3, 202, 202, 0, "MapEdit", "movePt", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters - bug #5099
{ GID_PQ3, 202, 202, 0, "MapEdit", "dispose", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // when plotting crimes, gets called with 2 extra parameters
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kIsObject_workarounds[] = {
- { GID_GK1, 50, 999, 0, "List", "eachElementDo", -1, 0, { WORKAROUND_FAKE, 0 } }, // GK1 demo, when asking Grace for messages it gets called with an invalid parameter (type "error") - bug #3034519
- { GID_ISLANDBRAIN, -1, 999, 0, "List", "eachElementDo", -1, 0, { WORKAROUND_FAKE, 0 } }, // when going to the game options, choosing "Info" and selecting anything from the list, gets called with an invalid parameter (type "error") - bug #3035262
+ { GID_GK1, 50, 999, 0, "List", "eachElementDo", -1, 0, { WORKAROUND_FAKE, 0 } }, // GK1 demo, when asking Grace for messages it gets called with an invalid parameter (type "error") - bug #4950
+ { GID_ISLANDBRAIN, -1, 999, 0, "List", "eachElementDo", -1, 0, { WORKAROUND_FAKE, 0 } }, // when going to the game options, choosing "Info" and selecting anything from the list, gets called with an invalid parameter (type "error") - bug #4989
{ GID_QFG3, -1, 999, 0, "List", "eachElementDo", -1, 0, { WORKAROUND_FAKE, 0 } }, // when asking for something, gets called with type error parameter
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kMemory_workarounds[] = {
- { GID_LAURABOW2, -1, 999, 0, "", "export 6", -1, 0, { WORKAROUND_FAKE, 0 } }, // during the intro, when exiting the train (room 160), talking to Mr. Augustini, etc. - bug #3034490
- { GID_SQ1, -1, 999, 0, "", "export 6", -1, 0, { WORKAROUND_FAKE, 0 } }, // during walking Roger around Ulence Flats - bug #3513765
+ { GID_LAURABOW2, -1, 999, 0, "", "export 6", -1, 0, { WORKAROUND_FAKE, 0 } }, // during the intro, when exiting the train (room 160), talking to Mr. Augustini, etc. - bug #4944
+ { GID_SQ1, -1, 999, 0, "", "export 6", -1, 0, { WORKAROUND_FAKE, 0 } }, // during walking Roger around Ulence Flats - bug #6017
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kMoveCursor_workarounds[] = {
- { GID_KQ5, -1, 937, 0, "IconBar", "handleEvent", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when pressing escape to open the menu, gets called with one parameter instead of 2 - bug #3156472
+ { GID_KQ5, -1, 937, 0, "IconBar", "handleEvent", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when pressing escape to open the menu, gets called with one parameter instead of 2 - bug #5575
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kNewWindow_workarounds[] = {
- { GID_ECOQUEST, -1, 981, 0, "SysWindow", "open", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // EcoQuest 1 demo uses an in-between interpreter from SCI1 to SCI1.1. It's SCI1.1, but uses the SCI1 semantics for this call - bug #3035057
+ { GID_ECOQUEST, -1, 981, 0, "SysWindow", "open", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // EcoQuest 1 demo uses an in-between interpreter from SCI1 to SCI1.1. It's SCI1.1, but uses the SCI1 semantics for this call - bug #4976
+ SCI_WORKAROUNDENTRY_TERMINATOR
+};
+
+// gameID, room,script,lvl, object-name, method-name, call,index, workaround
+const SciWorkaroundEntry kReadNumber_workarounds[] = {
+ { GID_CNICK_LAURABOW,100, 101, 0, "dominoes.opt", "doit", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // When dominoes.opt is present, the game scripts call kReadNumber with an extra integer parameter - bug #6425
+ { GID_HOYLE3, 100, 101, 0, "dominoes.opt", "doit", -1, 0, { WORKAROUND_STILLCALL, 0 } }, // When dominoes.opt is present, the game scripts call kReadNumber with an extra integer parameter - bug #6425
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kPaletteUnsetFlag_workarounds[] = {
- { GID_QFG4, 100, 100, 0, "doMovie", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // after the Sierra logo, no flags are passed, thus the call is meaningless - bug #3034506
+ { GID_QFG4, 100, 100, 0, "doMovie", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // after the Sierra logo, no flags are passed, thus the call is meaningless - bug #4947
SCI_WORKAROUNDENTRY_TERMINATOR
};
@@ -378,28 +410,33 @@ const SciWorkaroundEntry kSetCursor_workarounds[] = {
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kSetPort_workarounds[] = {
{ GID_LSL6, 740, 740, 0, "rm740", "drawPic", -1, 0, { WORKAROUND_IGNORE, 0 } }, // ending scene, is called with additional 3 (!) parameters
- { GID_QFG3, 830, 830, 0, "portalOpens", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when the portal appears during the end, gets called with 4 parameters (bug #3040844)
+ { GID_QFG3, 830, 830, 0, "portalOpens", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // when the portal appears during the end, gets called with 4 parameters - bug #5174
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kStrAt_workarounds[] = {
- { GID_CASTLEBRAIN, 220, 220, 0, "robotJokes", "animateOnce", -1, 0, { WORKAROUND_FAKE, 0 } }, // when trying to view the terminal at the end of the maze without having collected any robot jokes - bug #3039036
- { GID_ISLANDBRAIN, 300, 310, 0, "childBreed", "changeState",0x1c7c, 0, { WORKAROUND_FAKE, 0 } }, // when clicking Breed to get the second-generation cyborg hybrid (Standard difficulty), the two parameters are swapped - bug #3037835
+ { GID_CASTLEBRAIN, 220, 220, 0, "robotJokes", "animateOnce", -1, 0, { WORKAROUND_FAKE, 0 } }, // when trying to view the terminal at the end of the maze without having collected any robot jokes - bug #5127
+ { GID_ISLANDBRAIN, 300, 310, 0, "childBreed", "changeState",0x1c7c, 0, { WORKAROUND_FAKE, 0 } }, // when clicking Breed to get the second-generation cyborg hybrid (Standard difficulty), the two parameters are swapped - bug #5088
+ SCI_WORKAROUNDENTRY_TERMINATOR
+};
+
+const SciWorkaroundEntry kStrCpy_workarounds[] = {
+ { GID_MOTHERGOOSE, 23, 23, 0, "talkScript", "changeState", -1, 0, { WORKAROUND_FAKE, 0 } }, // when talking to the girl in scene 23, there's no destination parameter (script bug - wrong instruction order). The original source is used directly afterwards in kDisplay, to show the girl's text - bug #6485
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kStrLen_workarounds[] = {
- { GID_QFG2, 210, 2, 0, "", "export 21", 0xdeb, 0, { WORKAROUND_FAKE, 0 } }, // When saying something incorrect at the WIT, an integer is passed instead of a reference - bug #3100292
+ { GID_QFG2, 210, 2, 0, "", "export 21", 0xdeb, 0, { WORKAROUND_FAKE, 0 } }, // When saying something incorrect at the WIT, an integer is passed instead of a reference - bug #5489
SCI_WORKAROUNDENTRY_TERMINATOR
};
// gameID, room,script,lvl, object-name, method-name, call,index, workaround
const SciWorkaroundEntry kUnLoad_workarounds[] = {
{ GID_ECOQUEST, 380, 61, 0, "gotIt", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // CD version: after talking to the dolphin the first time, a 3rd parameter is passed by accident
- { GID_ECOQUEST, 380, 69, 0, "lookAtBlackBoard", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // German version, when closing the blackboard closeup in the dolphin room, a 3rd parameter is passed by accident - bug #3098353
- { GID_LAURABOW2, -1, -1, 0, "sCartoon", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // DEMO: during the intro, a 3rd parameter is passed by accident - bug #3034902
+ { GID_ECOQUEST, 380, 69, 0, "lookAtBlackBoard", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // German version, when closing the blackboard closeup in the dolphin room, a 3rd parameter is passed by accident - bug #5483
+ { GID_LAURABOW2, -1, -1, 0, "sCartoon", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // DEMO: during the intro, a 3rd parameter is passed by accident - bug #4966
{ GID_LSL6, 130, 130, 0, "recruitLarryScr", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // during intro, a 3rd parameter is passed by accident
{ GID_LSL6, 740, 740, 0, "showCartoon", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // during ending, 4 additional parameters are passed by accident
{ GID_LSL6HIRES, 130, 130, 0, "recruitLarryScr", "changeState", -1, 0, { WORKAROUND_IGNORE, 0 } }, // during intro, a 3rd parameter is passed by accident
@@ -465,7 +502,7 @@ SciWorkaroundSolution trackOriginAndFindWorkaround(int index, const SciWorkaroun
// Special case: in the fanmade Russian translation of SQ4, all
// of the object names have been deleted or renamed to Russian,
- // thus we disable checking of the object name. Fixes bug #3155550.
+ // thus we disable checking of the object name. Fixes bug #5573.
if (g_sci->getLanguage() == Common::RU_RUS && g_sci->getGameId() == GID_SQ4)
objectNameMatches = true;
diff --git a/engines/sci/engine/workarounds.h b/engines/sci/engine/workarounds.h
index 59054ae552..9cad618481 100644
--- a/engines/sci/engine/workarounds.h
+++ b/engines/sci/engine/workarounds.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -76,6 +76,7 @@ extern const SciWorkaroundEntry kDirLoop_workarounds[];
extern const SciWorkaroundEntry kDisposeScript_workarounds[];
extern const SciWorkaroundEntry kDoSoundFade_workarounds[];
extern const SciWorkaroundEntry kFindKey_workarounds[];
+extern const SciWorkaroundEntry kDeleteKey_workarounds[];
extern const SciWorkaroundEntry kGetAngle_workarounds[];
extern const SciWorkaroundEntry kGraphDrawLine_workarounds[];
extern const SciWorkaroundEntry kGraphSaveBox_workarounds[];
@@ -88,10 +89,12 @@ extern const SciWorkaroundEntry kIsObject_workarounds[];
extern const SciWorkaroundEntry kMemory_workarounds[];
extern const SciWorkaroundEntry kMoveCursor_workarounds[];
extern const SciWorkaroundEntry kNewWindow_workarounds[];
+extern const SciWorkaroundEntry kReadNumber_workarounds[];
extern const SciWorkaroundEntry kPaletteUnsetFlag_workarounds[];
extern const SciWorkaroundEntry kSetCursor_workarounds[];
extern const SciWorkaroundEntry kSetPort_workarounds[];
extern const SciWorkaroundEntry kStrAt_workarounds[];
+extern const SciWorkaroundEntry kStrCpy_workarounds[];
extern const SciWorkaroundEntry kStrLen_workarounds[];
extern const SciWorkaroundEntry kUnLoad_workarounds[];
diff --git a/engines/sci/event.cpp b/engines/sci/event.cpp
index 7318fe2f68..511d2014bd 100644
--- a/engines/sci/event.cpp
+++ b/engines/sci/event.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/event.h b/engines/sci/event.h
index 930001160a..82e93a9373 100644
--- a/engines/sci/event.h
+++ b/engines/sci/event.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/animate.cpp b/engines/sci/graphics/animate.cpp
index 53715613fc..7957ed6a55 100644
--- a/engines/sci/graphics/animate.cpp
+++ b/engines/sci/graphics/animate.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -726,7 +726,7 @@ void GfxAnimate::printAnimateList(Console *con) {
Script *scr = _s->_segMan->getScriptIfLoaded(it->object.getSegment());
int16 scriptNo = scr ? scr->getScriptNumber() : -1;
- con->DebugPrintf("%04x:%04x (%s), script %d, view %d (%d, %d), pal %d, "
+ con->debugPrintf("%04x:%04x (%s), script %d, view %d (%d, %d), pal %d, "
"at %d, %d, scale %d, %d / %d (z: %d, prio: %d, shown: %d, signal: %d)\n",
PRINT_REG(it->object), _s->_segMan->getObjectName(it->object),
scriptNo, it->viewId, it->loopNo, it->celNo, it->paletteNo,
diff --git a/engines/sci/graphics/animate.h b/engines/sci/graphics/animate.h
index 52da7d6ec6..6c1822c903 100644
--- a/engines/sci/graphics/animate.h
+++ b/engines/sci/graphics/animate.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/cache.cpp b/engines/sci/graphics/cache.cpp
index 55f8624c49..59af8334eb 100644
--- a/engines/sci/graphics/cache.cpp
+++ b/engines/sci/graphics/cache.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/cache.h b/engines/sci/graphics/cache.h
index 2f462fe042..33fa4fe399 100644
--- a/engines/sci/graphics/cache.h
+++ b/engines/sci/graphics/cache.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/compare.cpp b/engines/sci/graphics/compare.cpp
index b42063b119..3c2285a470 100644
--- a/engines/sci/graphics/compare.cpp
+++ b/engines/sci/graphics/compare.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -241,21 +241,13 @@ void GfxCompare::kernelBaseSetter(reg_t object) {
}
}
-Common::Rect GfxCompare::getNSRect(reg_t object, bool fixRect) {
+Common::Rect GfxCompare::getNSRect(reg_t object) {
Common::Rect nsRect;
nsRect.top = readSelectorValue(_segMan, object, SELECTOR(nsTop));
nsRect.left = readSelectorValue(_segMan, object, SELECTOR(nsLeft));
nsRect.bottom = readSelectorValue(_segMan, object, SELECTOR(nsBottom));
nsRect.right = readSelectorValue(_segMan, object, SELECTOR(nsRight));
- if (fixRect) {
- // nsRect top/left may be negative, adjust accordingly
- if (nsRect.top < 0)
- nsRect.top = 0;
- if (nsRect.left < 0)
- nsRect.left = 0;
- }
-
return nsRect;
}
diff --git a/engines/sci/graphics/compare.h b/engines/sci/graphics/compare.h
index 0080406a3b..88b44aeeb1 100644
--- a/engines/sci/graphics/compare.h
+++ b/engines/sci/graphics/compare.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -42,7 +42,7 @@ public:
reg_t kernelCanBeHere(reg_t curObject, reg_t listReference);
bool kernelIsItSkip(GuiResourceId viewId, int16 loopNo, int16 celNo, Common::Point position);
void kernelBaseSetter(reg_t object);
- Common::Rect getNSRect(reg_t object, bool fixRect = false);
+ Common::Rect getNSRect(reg_t object);
void setNSRect(reg_t object, Common::Rect nsRect);
private:
diff --git a/engines/sci/graphics/controls16.cpp b/engines/sci/graphics/controls16.cpp
index 0098f7b9ef..f2b2ccdfe6 100644
--- a/engines/sci/graphics/controls16.cpp
+++ b/engines/sci/graphics/controls16.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/controls16.h b/engines/sci/graphics/controls16.h
index 2cde86d4b1..6a70c71aae 100644
--- a/engines/sci/graphics/controls16.h
+++ b/engines/sci/graphics/controls16.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/controls32.cpp b/engines/sci/graphics/controls32.cpp
index 5b61e1a86a..90b5cd558c 100644
--- a/engines/sci/graphics/controls32.cpp
+++ b/engines/sci/graphics/controls32.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/controls32.h b/engines/sci/graphics/controls32.h
index 1b705988c2..5af7c20f16 100644
--- a/engines/sci/graphics/controls32.h
+++ b/engines/sci/graphics/controls32.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/coordadjuster.cpp b/engines/sci/graphics/coordadjuster.cpp
index 1446888cf4..93dff10382 100644
--- a/engines/sci/graphics/coordadjuster.cpp
+++ b/engines/sci/graphics/coordadjuster.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/coordadjuster.h b/engines/sci/graphics/coordadjuster.h
index 25279b34b1..cb0227fbe4 100644
--- a/engines/sci/graphics/coordadjuster.h
+++ b/engines/sci/graphics/coordadjuster.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/cursor.cpp b/engines/sci/graphics/cursor.cpp
index a9c741670f..048ec1e9b9 100644
--- a/engines/sci/graphics/cursor.cpp
+++ b/engines/sci/graphics/cursor.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/cursor.h b/engines/sci/graphics/cursor.h
index 369bd22a0b..c2d7998eb3 100644
--- a/engines/sci/graphics/cursor.h
+++ b/engines/sci/graphics/cursor.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/font.cpp b/engines/sci/graphics/font.cpp
index 30184cc091..e4684ff134 100644
--- a/engines/sci/graphics/font.cpp
+++ b/engines/sci/graphics/font.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/font.h b/engines/sci/graphics/font.h
index 8e5c980e2c..58b2ba4813 100644
--- a/engines/sci/graphics/font.h
+++ b/engines/sci/graphics/font.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/fontsjis.cpp b/engines/sci/graphics/fontsjis.cpp
index ac58c55423..9c942eadd1 100644
--- a/engines/sci/graphics/fontsjis.cpp
+++ b/engines/sci/graphics/fontsjis.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/fontsjis.h b/engines/sci/graphics/fontsjis.h
index ae5eaa43f9..57403ad98e 100644
--- a/engines/sci/graphics/fontsjis.h
+++ b/engines/sci/graphics/fontsjis.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/frameout.cpp b/engines/sci/graphics/frameout.cpp
index 76510fa53b..a322eb8e61 100644
--- a/engines/sci/graphics/frameout.cpp
+++ b/engines/sci/graphics/frameout.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -852,21 +852,21 @@ void GfxFrameout::printPlaneList(Console *con) {
Common::Rect r = p.upscaledPlaneRect;
Common::Rect cr = p.upscaledPlaneClipRect;
- con->DebugPrintf("%04x:%04x (%s): prio %d, lastprio %d, offsetX %d, offsetY %d, pic %d, mirror %d, back %d\n",
+ con->debugPrintf("%04x:%04x (%s): prio %d, lastprio %d, offsetX %d, offsetY %d, pic %d, mirror %d, back %d\n",
PRINT_REG(p.object), curPlaneName.c_str(),
(int16)p.priority, (int16)p.lastPriority,
p.planeOffsetX, p.planeOffsetY, p.pictureId,
p.planePictureMirrored, p.planeBack);
- con->DebugPrintf(" rect: (%d, %d, %d, %d), clip rect: (%d, %d, %d, %d)\n",
+ con->debugPrintf(" rect: (%d, %d, %d, %d), clip rect: (%d, %d, %d, %d)\n",
r.left, r.top, r.right, r.bottom,
cr.left, cr.top, cr.right, cr.bottom);
if (p.pictureId != 0xffff && p.pictureId != 0xfffe) {
- con->DebugPrintf("Pictures:\n");
+ con->debugPrintf("Pictures:\n");
for (PlanePictureList::iterator pictureIt = _planePictures.begin(); pictureIt != _planePictures.end(); pictureIt++) {
if (pictureIt->object == p.object) {
- con->DebugPrintf(" Picture %d: x %d, y %d\n", pictureIt->pictureId, pictureIt->startX, pictureIt->startY);
+ con->debugPrintf(" Picture %d: x %d, y %d\n", pictureIt->pictureId, pictureIt->startX, pictureIt->startY);
}
}
}
@@ -883,7 +883,7 @@ void GfxFrameout::printPlaneItemList(Console *con, reg_t planeObject) {
Common::Rect icr = e->celRect;
GuiResourceId picId = e->picture ? e->picture->getResourceId() : 0;
- con->DebugPrintf("%d: %04x:%04x (%s), view %d, loop %d, cel %d, x %d, y %d, z %d, "
+ con->debugPrintf("%d: %04x:%04x (%s), view %d, loop %d, cel %d, x %d, y %d, z %d, "
"signal %d, scale signal %d, scaleX %d, scaleY %d, rect (%d, %d, %d, %d), "
"pic %d, picX %d, picY %d, visible %d\n",
e->givenOrderNr, PRINT_REG(e->object), curItemName.c_str(),
diff --git a/engines/sci/graphics/frameout.h b/engines/sci/graphics/frameout.h
index 5ef770486f..e0c60f92c1 100644
--- a/engines/sci/graphics/frameout.h
+++ b/engines/sci/graphics/frameout.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/helpers.h b/engines/sci/graphics/helpers.h
index 773f83a00e..4889f12bd2 100644
--- a/engines/sci/graphics/helpers.h
+++ b/engines/sci/graphics/helpers.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/maciconbar.cpp b/engines/sci/graphics/maciconbar.cpp
index 4df80b289f..8e2e12b7bd 100644
--- a/engines/sci/graphics/maciconbar.cpp
+++ b/engines/sci/graphics/maciconbar.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -32,7 +32,7 @@
#include "common/memstream.h"
#include "common/system.h"
#include "graphics/surface.h"
-#include "graphics/decoders/pict.h"
+#include "image/pict.h"
namespace Sci {
@@ -201,12 +201,12 @@ void GfxMacIconBar::setInventoryIcon(int16 icon) {
}
Graphics::Surface *GfxMacIconBar::loadPict(ResourceId id) {
- Graphics::PICTDecoder pictDecoder;
Resource *res = g_sci->getResMan()->findResource(id, false);
if (!res || res->size == 0)
return 0;
+ Image::PICTDecoder pictDecoder;
Common::MemoryReadStream stream(res->data, res->size);
if (!pictDecoder.loadStream(stream))
return 0;
diff --git a/engines/sci/graphics/maciconbar.h b/engines/sci/graphics/maciconbar.h
index eca10b804c..86cbc74039 100644
--- a/engines/sci/graphics/maciconbar.h
+++ b/engines/sci/graphics/maciconbar.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/menu.cpp b/engines/sci/graphics/menu.cpp
index d2416ab4e0..8e8c1d64c2 100644
--- a/engines/sci/graphics/menu.cpp
+++ b/engines/sci/graphics/menu.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/menu.h b/engines/sci/graphics/menu.h
index aa3550da4e..95fd4f6c20 100644
--- a/engines/sci/graphics/menu.h
+++ b/engines/sci/graphics/menu.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/paint.cpp b/engines/sci/graphics/paint.cpp
index 7befa99afe..482b81aff1 100644
--- a/engines/sci/graphics/paint.cpp
+++ b/engines/sci/graphics/paint.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/paint.h b/engines/sci/graphics/paint.h
index 27f7e428b6..b2277131d5 100644
--- a/engines/sci/graphics/paint.h
+++ b/engines/sci/graphics/paint.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/paint16.cpp b/engines/sci/graphics/paint16.cpp
index 940a1ac3cf..b835eb92ca 100644
--- a/engines/sci/graphics/paint16.cpp
+++ b/engines/sci/graphics/paint16.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/paint16.h b/engines/sci/graphics/paint16.h
index e06021c3e7..882f311a5b 100644
--- a/engines/sci/graphics/paint16.h
+++ b/engines/sci/graphics/paint16.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/paint32.cpp b/engines/sci/graphics/paint32.cpp
index a03e77dfa6..7d106b5b02 100644
--- a/engines/sci/graphics/paint32.cpp
+++ b/engines/sci/graphics/paint32.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -43,8 +43,12 @@ GfxPaint32::~GfxPaint32() {
void GfxPaint32::fillRect(Common::Rect rect, byte color) {
int16 y, x;
- for (y = rect.top; y < rect.bottom; y++) {
- for (x = rect.left; x < rect.right; x++) {
+ Common::Rect clipRect = rect;
+
+ clipRect.clip(_screen->getWidth(), _screen->getHeight());
+
+ for (y = clipRect.top; y < clipRect.bottom; y++) {
+ for (x = clipRect.left; x < clipRect.right; x++) {
_screen->putPixel(x, y, GFX_SCREEN_MASK_VISUAL, color, 0, 0);
}
}
diff --git a/engines/sci/graphics/paint32.h b/engines/sci/graphics/paint32.h
index 81e355f77f..e7a3ec256d 100644
--- a/engines/sci/graphics/paint32.h
+++ b/engines/sci/graphics/paint32.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/palette.cpp b/engines/sci/graphics/palette.cpp
index d8d788b00a..a3624c7959 100644
--- a/engines/sci/graphics/palette.cpp
+++ b/engines/sci/graphics/palette.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/palette.h b/engines/sci/graphics/palette.h
index e974781d49..347695deb8 100644
--- a/engines/sci/graphics/palette.h
+++ b/engines/sci/graphics/palette.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/picture.cpp b/engines/sci/graphics/picture.cpp
index 8ad4f535f9..434a490109 100644
--- a/engines/sci/graphics/picture.cpp
+++ b/engines/sci/graphics/picture.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -132,7 +132,7 @@ void GfxPicture::drawSci11Vga() {
_palette->createFromData(inbuffer + palette_data_ptr, size - palette_data_ptr, &palette);
_palette->set(&palette, true);
- drawCelData(inbuffer, size, cel_headerPos, cel_RlePos, cel_LiteralPos, 0, 0, 0, 0);
+ drawCelData(inbuffer, size, cel_headerPos, cel_RlePos, cel_LiteralPos, 0, 0, 0, 0, false);
}
// process vector data
@@ -224,14 +224,14 @@ void GfxPicture::drawSci32Vga(int16 celNo, int16 drawX, int16 drawY, int16 pictu
cel_RlePos = READ_SCI11ENDIAN_UINT32(inbuffer + cel_headerPos + 24);
cel_LiteralPos = READ_SCI11ENDIAN_UINT32(inbuffer + cel_headerPos + 28);
- drawCelData(inbuffer, size, cel_headerPos, cel_RlePos, cel_LiteralPos, drawX, drawY, pictureX, pictureY);
+ drawCelData(inbuffer, size, cel_headerPos, cel_RlePos, cel_LiteralPos, drawX, drawY, pictureX, pictureY, false);
cel_headerPos += 42;
}
#endif
extern void unpackCelData(byte *inBuffer, byte *celBitmap, byte clearColor, int pixelCount, int rlePos, int literalPos, ViewType viewType, uint16 width, bool isMacSci11ViewData);
-void GfxPicture::drawCelData(byte *inbuffer, int size, int headerPos, int rlePos, int literalPos, int16 drawX, int16 drawY, int16 pictureX, int16 pictureY) {
+void GfxPicture::drawCelData(byte *inbuffer, int size, int headerPos, int rlePos, int literalPos, int16 drawX, int16 drawY, int16 pictureX, int16 pictureY, bool isEGA) {
byte *celBitmap = NULL;
byte *ptr = NULL;
byte *headerPtr = inbuffer + headerPos;
@@ -239,13 +239,17 @@ void GfxPicture::drawCelData(byte *inbuffer, int size, int headerPos, int rlePos
// displaceX, displaceY fields are ignored, and may contain garbage
// (e.g. pic 261 in Dr. Brain 1 Spanish - bug #3614914)
//int16 displaceX, displaceY;
- byte priority = _addToFlag ? _priority : 0;
+ byte priority = _priority;
byte clearColor;
bool compression = true;
byte curByte;
int16 y, lastY, x, leftX, rightX;
int pixelCount;
uint16 width, height;
+
+ // if the picture is not an overlay and we are also not in EGA mode, use priority 0
+ if (!isEGA && !_addToFlag)
+ priority = 0;
#ifdef ENABLE_SCI32
if (_resourceType != SCI_PICTURE_TYPE_SCI32) {
@@ -279,8 +283,6 @@ void GfxPicture::drawCelData(byte *inbuffer, int size, int headerPos, int rlePos
// That needs to be done cause a mirrored picture may be requested
pixelCount = width * height;
celBitmap = new byte[pixelCount];
- if (!celBitmap)
- error("Unable to allocate temporary memory for picture drawing");
if (g_sci->getPlatform() == Common::kPlatformMacintosh && getSciVersion() >= SCI_VERSION_2) {
// See GfxView::unpackCel() for why this black/white swap is done
@@ -360,37 +362,78 @@ void GfxPicture::drawCelData(byte *inbuffer, int size, int headerPos, int rlePos
ptr = celBitmap;
ptr += skipCelBitmapPixels;
ptr += skipCelBitmapLines * width;
- if (!_mirroredFlag) {
- // Draw bitmap to screen
- x = leftX;
- while (y < lastY) {
- curByte = *ptr++;
- if ((curByte != clearColor) && (priority >= _screen->getPriority(x, y)))
- _screen->putPixel(x, y, drawMask, curByte, priority, 0);
-
- x++;
-
- if (x >= rightX) {
- ptr += sourcePixelSkipPerRow;
- x = leftX;
- y++;
+
+ if ((!isEGA) || (priority < 16)) {
+ // VGA + EGA, EGA only checks priority, when given priority is below 16
+ if (!_mirroredFlag) {
+ // Draw bitmap to screen
+ x = leftX;
+ while (y < lastY) {
+ curByte = *ptr++;
+ if ((curByte != clearColor) && (priority >= _screen->getPriority(x, y)))
+ _screen->putPixel(x, y, drawMask, curByte, priority, 0);
+
+ x++;
+
+ if (x >= rightX) {
+ ptr += sourcePixelSkipPerRow;
+ x = leftX;
+ y++;
+ }
+ }
+ } else {
+ // Draw bitmap to screen (mirrored)
+ x = rightX - 1;
+ while (y < lastY) {
+ curByte = *ptr++;
+ if ((curByte != clearColor) && (priority >= _screen->getPriority(x, y)))
+ _screen->putPixel(x, y, drawMask, curByte, priority, 0);
+
+ if (x == leftX) {
+ ptr += sourcePixelSkipPerRow;
+ x = rightX;
+ y++;
+ }
+
+ x--;
}
}
} else {
- // Draw bitmap to screen (mirrored)
- x = rightX - 1;
- while (y < lastY) {
- curByte = *ptr++;
- if ((curByte != clearColor) && (priority >= _screen->getPriority(x, y)))
- _screen->putPixel(x, y, drawMask, curByte, priority, 0);
-
- if (x == leftX) {
- ptr += sourcePixelSkipPerRow;
- x = rightX;
- y++;
+ // EGA, when priority is above 15
+ // we don't check priority and also won't set priority at all
+ // fixes picture 48 of kq5 (island overview). Bug #5182
+ if (!_mirroredFlag) {
+ // EGA+priority>15: Draw bitmap to screen
+ x = leftX;
+ while (y < lastY) {
+ curByte = *ptr++;
+ if (curByte != clearColor)
+ _screen->putPixel(x, y, GFX_SCREEN_MASK_VISUAL, curByte, 0, 0);
+
+ x++;
+
+ if (x >= rightX) {
+ ptr += sourcePixelSkipPerRow;
+ x = leftX;
+ y++;
+ }
}
+ } else {
+ // EGA+priority>15: Draw bitmap to screen (mirrored)
+ x = rightX - 1;
+ while (y < lastY) {
+ curByte = *ptr++;
+ if (curByte != clearColor)
+ _screen->putPixel(x, y, GFX_SCREEN_MASK_VISUAL, curByte, 0, 0);
+
+ if (x == leftX) {
+ ptr += sourcePixelSkipPerRow;
+ x = rightX;
+ y++;
+ }
- x--;
+ x--;
+ }
}
}
}
@@ -540,22 +583,6 @@ void GfxPicture::drawVectorData(byte *data, int dataSize) {
if ((_screen->isUnditheringEnabled()) && ((_resourceId >= 53 && _resourceId <= 58) || (_resourceId == 61)))
icemanDrawFix = true;
}
- if (g_sci->getGameId() == GID_KQ5) {
- // WORKAROUND: ignore the seemingly broken priority of picture 48
- // (island overview). Fixes bug #3041044.
- if (_resourceId == 48)
- ignoreBrokenPriority = true;
- }
- if (g_sci->getGameId() == GID_SQ4) {
- // WORKAROUND: ignore the seemingly broken priority of pictures 546
- // and 547 (Vohaul's head and Roger Jr trapped). Fixes bug #3046543.
- if (_resourceId == 546 || _resourceId == 547)
- ignoreBrokenPriority = true;
- // WORKAROUND: ignore the seemingly broken priority of picture 631
- // (SQ1 view from the cockpit). Fixes bug #3046513.
- if (_resourceId == 631)
- ignoreBrokenPriority = true;
- }
}
// Drawing
@@ -740,8 +767,15 @@ void GfxPicture::drawVectorData(byte *data, int dataSize) {
case PIC_OPX_EGA_EMBEDDED_VIEW:
vectorGetAbsCoordsNoMirror(data, curPos, x, y);
size = READ_LE_UINT16(data + curPos); curPos += 2;
- _priority = pic_priority; // set global priority so the cel gets drawn using current priority as well
- drawCelData(data, _resource->size, curPos, curPos + 8, 0, x, y, 0, 0);
+ // hardcoded in SSCI, 16 for SCI1early excluding Space Quest 4, 0 for anything else
+ // fixes sq4 pictures 546+547 (Vohaul's head and Roger Jr trapped). Bug #5250
+ // fixes sq4 picture 631 (SQ1 view from cockpit). Bug 5249
+ if ((getSciVersion() <= SCI_VERSION_1_EARLY) && (g_sci->getGameId() != GID_SQ4)) {
+ _priority = 16;
+ } else {
+ _priority = 0;
+ }
+ drawCelData(data, _resource->size, curPos, curPos + 8, 0, x, y, 0, 0, true);
curPos += size;
break;
case PIC_OPX_EGA_SET_PRIORITY_TABLE:
@@ -783,8 +817,14 @@ void GfxPicture::drawVectorData(byte *data, int dataSize) {
case PIC_OPX_VGA_EMBEDDED_VIEW: // draw cel
vectorGetAbsCoordsNoMirror(data, curPos, x, y);
size = READ_LE_UINT16(data + curPos); curPos += 2;
- _priority = pic_priority; // set global priority so the cel gets drawn using current priority as well
- drawCelData(data, _resource->size, curPos, curPos + 8, 0, x, y, 0, 0);
+ if (getSciVersion() <= SCI_VERSION_1_EARLY) {
+ // During SCI1Early sierra always used 0 as priority for cels inside picture resources
+ // fixes Space Quest 4 orange ship lifting off (bug #6446)
+ _priority = 0;
+ } else {
+ _priority = pic_priority; // set global priority so the cel gets drawn using current priority as well
+ }
+ drawCelData(data, _resource->size, curPos, curPos + 8, 0, x, y, 0, 0, false);
curPos += size;
break;
case PIC_OPX_VGA_PRIORITY_TABLE_EQDIST:
@@ -967,6 +1007,12 @@ void GfxPicture::vectorFloodFill(int16 x, int16 y, byte color, byte priority, by
_screen->putPixel(--w, p.y, screenMask, color, priority, control);
while (e < r && (matchedMask = _screen->isFillMatch(e + 1, p.y, matchMask, searchColor, searchPriority, searchControl, isEGA)))
_screen->putPixel(++e, p.y, screenMask, color, priority, control);
+#if 0
+ // debug code for floodfill
+ _screen->copyToScreen();
+ g_system->updateScreen();
+ g_system->delayMillis(100);
+#endif
// checking lines above and below for possible flood targets
a_set = b_set = 0;
while (w <= e) {
diff --git a/engines/sci/graphics/picture.h b/engines/sci/graphics/picture.h
index 4f075a6226..2404f99b41 100644
--- a/engines/sci/graphics/picture.h
+++ b/engines/sci/graphics/picture.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -65,7 +65,7 @@ private:
void initData(GuiResourceId resourceId);
void reset();
void drawSci11Vga();
- void drawCelData(byte *inbuffer, int size, int headerPos, int rlePos, int literalPos, int16 drawX, int16 drawY, int16 pictureX, int16 pictureY);
+ void drawCelData(byte *inbuffer, int size, int headerPos, int rlePos, int literalPos, int16 drawX, int16 drawY, int16 pictureX, int16 pictureY, bool isEGA);
void drawVectorData(byte *data, int size);
bool vectorIsNonOpcode(byte pixel);
void vectorGetAbsCoords(byte *data, int &curPos, int16 &x, int16 &y);
diff --git a/engines/sci/graphics/portrait.cpp b/engines/sci/graphics/portrait.cpp
index d5227126e2..488450485d 100644
--- a/engines/sci/graphics/portrait.cpp
+++ b/engines/sci/graphics/portrait.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -21,6 +21,7 @@
*/
#include "common/archive.h"
+#include "common/file.h" // for DumpFile
#include "common/system.h"
#include "sci/sci.h"
@@ -39,6 +40,7 @@ Portrait::Portrait(ResourceManager *resMan, EventManager *event, GfxScreen *scre
}
Portrait::~Portrait() {
+ delete[] _lipSyncDataOffsetTable;
delete[] _bitmaps;
delete[] _fileData;
}
@@ -51,7 +53,7 @@ void Portrait::init() {
// 2 bytes main height (should be the same as first bitmap header height)
// 2 bytes animation count
// 2 bytes unknown
- // 2 bytes unknown
+ // 2 bytes lip sync ID count
// 4 bytes paletteSize (base 1)
// -> 17 bytes
// paletteSize bytes paletteData
@@ -81,6 +83,8 @@ void Portrait::init() {
_width = READ_LE_UINT16(_fileData + 3);
_height = READ_LE_UINT16(_fileData + 5);
_bitmapCount = READ_LE_UINT16(_fileData + 7);
+ _lipSyncIDCount = READ_LE_UINT16(_fileData + 11);
+
_bitmaps = new PortraitBitmap[_bitmapCount];
uint16 portraitPaletteSize = READ_LE_UINT16(_fileData + 13);
@@ -128,17 +132,103 @@ void Portrait::init() {
}
data += offsetTableSize;
- // raw lip-sync data follows
+ // raw lip-sync ID table follows
+ uint32 lipSyncIDTableSize;
+
+ lipSyncIDTableSize = READ_LE_UINT32(data);
+ data += 4;
+ assert( lipSyncIDTableSize == (_lipSyncIDCount * 4) );
+ _lipSyncIDTable = data;
+ data += lipSyncIDTableSize;
+
+ // raw lip-sync frame table follows
+ uint32 lipSyncDataTableSize;
+ uint32 lipSyncDataTableLastOffset;
+ byte lipSyncData;
+ uint16 lipSyncDataNr;
+ uint16 lipSyncCurOffset;
+
+ lipSyncDataTableSize = READ_LE_UINT32(data);
+ data += 4;
+ assert( lipSyncDataTableSize == 0x220 ); // always this size, just a safety-check
+
+ _lipSyncData = data;
+ lipSyncDataTableLastOffset = lipSyncDataTableSize - 1;
+ _lipSyncDataOffsetTable = new uint16[ _lipSyncIDCount ];
+
+ lipSyncDataNr = 0;
+ lipSyncCurOffset = 0;
+ while ( (lipSyncCurOffset < lipSyncDataTableSize) && (lipSyncDataNr < _lipSyncIDCount) ) {
+ // We are currently at the start of ID-frame data
+ _lipSyncDataOffsetTable[lipSyncDataNr] = lipSyncCurOffset;
+
+ // Look for end of ID-frame data
+ lipSyncData = *data++; lipSyncCurOffset++;
+ while ( (lipSyncData != 0xFF) && (lipSyncCurOffset < lipSyncDataTableLastOffset) ) {
+ // Either terminator (0xFF) or frame-data (1 byte tick count and 1 byte bitmap ID)
+ data++;
+ lipSyncData = *data++;
+ lipSyncCurOffset += 2;
+ }
+ lipSyncDataNr++;
+ }
+ _lipSyncDataOffsetTableEnd = data;
+ // last 4 bytes seem to be garbage
}
+// use this to print out kPortrait debug data
+//#define DEBUG_PORTRAIT
+// use this to use sync resources instead of rave resources (rave resources are better though)
+//#define DEBUG_PORTRAIT_USE_SYNC_RESOURCES
+
void Portrait::doit(Common::Point position, uint16 resourceId, uint16 noun, uint16 verb, uint16 cond, uint16 seq) {
_position = position;
// Now init audio and sync resource
uint32 audioNumber = ((noun & 0xff) << 24) | ((verb & 0xff) << 16) | ((cond & 0xff) << 8) | (seq & 0xff);
+#ifndef DEBUG_PORTRAIT_USE_SYNC_RESOURCES
+ ResourceId raveResourceId = ResourceId(kResourceTypeRave, resourceId, noun, verb, cond, seq);
+ Resource *raveResource = _resMan->findResource(raveResourceId, true);
+ uint raveOffset = 0;
+#else
ResourceId syncResourceId = ResourceId(kResourceTypeSync36, resourceId, noun, verb, cond, seq);
Resource *syncResource = _resMan->findResource(syncResourceId, true);
uint syncOffset = 0;
+#endif
+
+#ifdef DEBUG_PORTRAIT
+ // prints out the current lip sync ASCII data
+ char debugPrint[4000];
+ if (raveResource->size < 4000) {
+ memcpy(debugPrint, raveResource->data, raveResource->size);
+ debugPrint[raveResource->size] = 0; // set terminating NUL
+ debug("kPortrait (noun %d, verb %d, cond %d, seq %d)", noun, verb, cond, seq);
+ debug("kPortrait: %s", debugPrint);
+ }
+#endif
+
+ // TODO: maybe try to create the missing sync resources for low-res KQ6 out of the rave resources
+
+#ifdef DEBUG_PORTRAIT_USE_SYNC_RESOURCES
+ // Dump the sync resources to disk
+ Common::DumpFile *outFile = new Common::DumpFile();
+ Common::String outName = syncResourceId.toPatchNameBase36() + ".sync36";
+ outFile->open(outName);
+ syncResource->writeToStream(outFile);
+ outFile->finalize();
+ outFile->close();
+
+ ResourceId raveResourceId = ResourceId(kResourceTypeRave, resourceId, noun, verb, cond, seq);
+ Resource *raveResource = _resMan->findResource(raveResourceId, true);
+ outName = raveResourceId.toPatchNameBase36() + ".rave";
+ outFile->open(outName);
+ raveResource->writeToStream(outFile);
+ outFile->finalize();
+ outFile->close();
+ _resMan->unlockResource(raveResource);
+
+ delete outFile;
+#endif
// Set the portrait palette
_palette->set(&_portraitPalette, false, true);
@@ -151,6 +241,90 @@ void Portrait::doit(Common::Point position, uint16 resourceId, uint16 noun, uint
_audio->stopAudio();
_audio->startAudio(resourceId, audioNumber);
+#ifndef DEBUG_PORTRAIT_USE_SYNC_RESOURCES
+ if (!raveResource) {
+ warning("kPortrait: no rave resource %d %X", resourceId, audioNumber);
+ return;
+ }
+
+ // Do animation depending on rave resource till audio is done playing
+ int16 raveTicks;
+ uint16 raveID;
+ byte *raveLipSyncData;
+ byte raveLipSyncTicks;
+ byte raveLipSyncBitmapNr;
+ int timerPosition = 0;
+ int timerPositionWithin = 0;
+ int curPosition;
+ SciEvent curEvent;
+ bool userAbort = false;
+
+ while ((raveOffset < raveResource->size) && (!userAbort)) {
+ // rave string starts with tick count, followed by lipSyncID, tick count and so on
+ raveTicks = raveGetTicks(raveResource, &raveOffset);
+ if (raveTicks < 0)
+ break;
+
+ // get lipSyncID
+ raveID = raveGetID(raveResource, &raveOffset);
+ if (raveID) {
+ raveLipSyncData = raveGetLipSyncData(raveID);
+ } else {
+ raveLipSyncData = NULL;
+ }
+
+ timerPosition += raveTicks;
+
+ // Wait till syncTime passed, then show specific animation bitmap
+ if (timerPosition > 0) {
+ do {
+ g_sci->getEngineState()->wait(1);
+ curEvent = _event->getSciEvent(SCI_EVENT_ANY);
+ if (curEvent.type == SCI_EVENT_MOUSE_PRESS ||
+ (curEvent.type == SCI_EVENT_KEYBOARD && curEvent.data == SCI_KEY_ESC) ||
+ g_sci->getEngineState()->abortScriptProcessing == kAbortQuitGame)
+ userAbort = true;
+ curPosition = _audio->getAudioPosition();
+ } while ((curPosition != -1) && (curPosition < timerPosition) && (!userAbort));
+ }
+
+ if (raveLipSyncData) {
+ // lip sync data is
+ // Tick:Byte, Bitmap-Nr:BYTE
+ // Tick = 0xFF is the terminator for the data
+ timerPositionWithin = timerPosition;
+ raveLipSyncTicks = *raveLipSyncData++;
+ while ( (raveLipSyncData < _lipSyncDataOffsetTableEnd) && (raveLipSyncTicks != 0xFF) ) {
+ timerPositionWithin += raveLipSyncTicks;
+
+ do {
+ g_sci->getEngineState()->wait(1);
+ curEvent = _event->getSciEvent(SCI_EVENT_ANY);
+ if (curEvent.type == SCI_EVENT_MOUSE_PRESS ||
+ (curEvent.type == SCI_EVENT_KEYBOARD && curEvent.data == SCI_KEY_ESC) ||
+ g_sci->getEngineState()->abortScriptProcessing == kAbortQuitGame)
+ userAbort = true;
+ curPosition = _audio->getAudioPosition();
+ } while ((curPosition != -1) && (curPosition < timerPositionWithin) && (!userAbort));
+
+ raveLipSyncBitmapNr = *raveLipSyncData++;
+
+ // bitmap nr within sync data is base 1, we need base 0
+ raveLipSyncBitmapNr--;
+
+ if (raveLipSyncBitmapNr < _bitmapCount) {
+ drawBitmap(0);
+ drawBitmap(raveLipSyncBitmapNr);
+ bitsShow();
+ } else {
+ warning("kPortrait: rave lip sync data tried to draw non-existent bitmap %d", raveLipSyncBitmapNr);
+ }
+
+ raveLipSyncTicks = *raveLipSyncData++;
+ }
+ }
+ }
+#else
if (!syncResource) {
// Getting the book in the book shop calls kPortrait where no sync exists
// TODO: find out what to do then
@@ -197,15 +371,90 @@ void Portrait::doit(Common::Point position, uint16 resourceId, uint16 noun, uint
}
}
}
-
+#endif
+
+ // Reset the portrait bitmap to "closed mouth" state (rave.dll seems to do the same)
+ drawBitmap(0);
+ bitsShow();
if (userAbort) {
- // Reset the portrait bitmap to "closed mouth" state, when skipping dialogs
- drawBitmap(0);
- bitsShow();
_audio->stopAudio();
}
+#ifndef DEBUG_PORTRAIT_USE_SYNC_RESOURCES
+ _resMan->unlockResource(raveResource);
+#else
_resMan->unlockResource(syncResource);
+#endif
+}
+
+// returns ASCII ticks from lip sync string as uint16
+int16 Portrait::raveGetTicks(Resource *resource, uint *offset) {
+ uint curOffset = *offset;
+ byte *curData = resource->data + curOffset;
+ byte curByte;
+ uint16 curValue = 0;
+
+ if (curOffset >= resource->size)
+ return -1;
+
+ while (curOffset < resource->size) {
+ curByte = *curData++; curOffset++;
+ if ( curByte == ' ' )
+ break;
+ if ( (curByte >= '0') && (curByte <= '9') ) {
+ curValue = curValue * 10 + ( curByte - '0' );
+ } else {
+ // no number -> assume there is an ID at current offset
+ return 0;
+ }
+ }
+ *offset = curOffset;
+ return curValue;
+}
+
+// returns ASCII ID from lip sync string as uint16
+uint16 Portrait::raveGetID(Resource *resource, uint *offset) {
+ uint curOffset = *offset;
+ byte *curData = resource->data + curOffset;
+ byte curByte = 0;
+ uint16 curValue = 0;
+
+ while (curOffset < resource->size) {
+ curByte = *curData++; curOffset++;
+ if ( curByte == ' ' )
+ break;
+ if (!curValue) {
+ curValue = curByte << 8;
+ } else {
+ curValue |= curByte;
+ }
+ }
+
+ *offset = curOffset;
+ return curValue;
+}
+
+// Searches for a specific lip sync ID and returns pointer to lip sync data or NULL in case ID was not found
+byte *Portrait::raveGetLipSyncData(uint16 raveID) {
+ uint lipSyncIDNr = 0;
+ byte *lipSyncIDPtr = _lipSyncIDTable;
+ byte lipSyncIDByte1, lipSyncIDByte2;
+ uint16 lipSyncID;
+
+ lipSyncIDPtr++; // skip over first byte
+ while (lipSyncIDNr < _lipSyncIDCount) {
+ lipSyncIDByte1 = *lipSyncIDPtr++;
+ lipSyncIDByte2 = *lipSyncIDPtr++;
+ lipSyncID = ( lipSyncIDByte1 << 8 ) | lipSyncIDByte2;
+
+ if ( lipSyncID == raveID ) {
+ return _lipSyncData + _lipSyncDataOffsetTable[lipSyncIDNr];
+ }
+
+ lipSyncIDNr++;
+ lipSyncIDPtr += 2; // ID is every 4 bytes
+ }
+ return NULL;
}
void Portrait::drawBitmap(uint16 bitmapNr) {
diff --git a/engines/sci/graphics/portrait.h b/engines/sci/graphics/portrait.h
index 75baa9a56b..877b253bcf 100644
--- a/engines/sci/graphics/portrait.h
+++ b/engines/sci/graphics/portrait.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -52,6 +52,10 @@ private:
void drawBitmap(uint16 bitmapNr);
void bitsShow();
+ int16 raveGetTicks(Resource *resource, uint *offset);
+ uint16 raveGetID(Resource *resource, uint *offset);
+ byte *raveGetLipSyncData(uint16 raveID);
+
ResourceManager *_resMan;
EventManager *_event;
GfxPalette *_palette;
@@ -68,6 +72,13 @@ private:
Common::String _resourceName;
byte *_fileData;
+
+ uint32 _lipSyncIDCount;
+ byte *_lipSyncIDTable;
+
+ byte *_lipSyncData;
+ uint16 *_lipSyncDataOffsetTable;
+ byte *_lipSyncDataOffsetTableEnd;
Common::Point _position;
};
diff --git a/engines/sci/graphics/ports.cpp b/engines/sci/graphics/ports.cpp
index 6d9dc03195..56c63a7b12 100644
--- a/engines/sci/graphics/ports.cpp
+++ b/engines/sci/graphics/ports.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -300,11 +300,6 @@ Window *GfxPorts::addWindow(const Common::Rect &dims, const Common::Rect *restor
Window *pwnd = new Window(id);
Common::Rect r;
- if (!pwnd) {
- error("Can't open window");
- return 0;
- }
-
_windowsById[id] = pwnd;
// KQ1sci, KQ4, iceman, QfG2 always add windows to the back of the list.
@@ -753,7 +748,7 @@ void GfxPorts::printWindowList(Console *con) {
for (PortList::const_iterator it = _windowList.begin(); it != _windowList.end(); ++it) {
if ((*it)->isWindow()) {
Window *wnd = ((Window *)*it);
- con->DebugPrintf("%d: '%s' at %d, %d, (%d, %d, %d, %d), drawn: %d, style: %d\n",
+ con->debugPrintf("%d: '%s' at %d, %d, (%d, %d, %d, %d), drawn: %d, style: %d\n",
wnd->id, wnd->title.c_str(), wnd->left, wnd->top,
wnd->rect.left, wnd->rect.top, wnd->rect.right, wnd->rect.bottom,
wnd->bDrawn, wnd->wndStyle);
diff --git a/engines/sci/graphics/ports.h b/engines/sci/graphics/ports.h
index 1818eaddb3..51aca09f54 100644
--- a/engines/sci/graphics/ports.h
+++ b/engines/sci/graphics/ports.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/screen.cpp b/engines/sci/graphics/screen.cpp
index 0df163dd7b..c5c94d7991 100644
--- a/engines/sci/graphics/screen.cpp
+++ b/engines/sci/graphics/screen.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -50,6 +50,11 @@ GfxScreen::GfxScreen(ResourceManager *resMan) : _resMan(resMan) {
_upscaledHires = GFX_SCREEN_UPSCALED_640x480;
#endif
}
+
+ if (g_sci->getPlatform() == Common::kPlatformMacintosh) {
+ if (getSciVersion() <= SCI_VERSION_01)
+ _upscaledHires = GFX_SCREEN_UPSCALED_480x300;
+ }
#ifdef ENABLE_SCI32
// GK1 Mac uses a 640x480 resolution too
@@ -84,28 +89,48 @@ GfxScreen::GfxScreen(ResourceManager *resMan) : _resMan(resMan) {
_pixels = _pitch * _height;
switch (_upscaledHires) {
+ case GFX_SCREEN_UPSCALED_480x300:
+ // Space Quest 3, Hoyle 1+2 on MAC use this one
+ // TODO: Sierra's upscaling worked differently. We need to figure out the exact algo
+ _displayWidth = 480;
+ _displayHeight = 300;
+ for (int i = 0; i <= _height; i++)
+ _upscaledHeightMapping[i] = (i * 3) >> 1;
+ for (int i = 0; i <= _width; i++)
+ _upscaledWidthMapping[i] = (i * 3) >> 1;
+ break;
case GFX_SCREEN_UPSCALED_640x400:
+ // Police Quest 2 and Quest For Glory on PC9801 (Japanese)
_displayWidth = 640;
_displayHeight = 400;
for (int i = 0; i <= _height; i++)
- _upscaledMapping[i] = i * 2;
+ _upscaledHeightMapping[i] = i * 2;
+ for (int i = 0; i <= _width; i++)
+ _upscaledWidthMapping[i] = i * 2;
break;
case GFX_SCREEN_UPSCALED_640x440:
+ // used by King's Quest 6 on Windows
_displayWidth = 640;
_displayHeight = 440;
for (int i = 0; i <= _height; i++)
- _upscaledMapping[i] = (i * 11) / 5;
+ _upscaledHeightMapping[i] = (i * 11) / 5;
+ for (int i = 0; i <= _width; i++)
+ _upscaledWidthMapping[i] = i * 2;
break;
case GFX_SCREEN_UPSCALED_640x480:
+ // Gabriel Knight 1 (VESA, Mac)
_displayWidth = 640;
_displayHeight = 480;
for (int i = 0; i <= _height; i++)
- _upscaledMapping[i] = (i * 12) / 5;
+ _upscaledHeightMapping[i] = (i * 12) / 5;
+ for (int i = 0; i <= _width; i++)
+ _upscaledWidthMapping[i] = i * 2;
break;
default:
_displayWidth = _pitch;
_displayHeight = _height;
- memset(&_upscaledMapping, 0, sizeof(_upscaledMapping) );
+ memset(&_upscaledHeightMapping, 0, sizeof(_upscaledHeightMapping) );
+ memset(&_upscaledWidthMapping, 0, sizeof(_upscaledWidthMapping) );
break;
}
@@ -185,8 +210,9 @@ void GfxScreen::copyRectToScreen(const Common::Rect &rect) {
if (!_upscaledHires) {
g_system->copyRectToScreen(_activeScreen + rect.top * _displayWidth + rect.left, _displayWidth, rect.left, rect.top, rect.width(), rect.height());
} else {
- int rectHeight = _upscaledMapping[rect.bottom] - _upscaledMapping[rect.top];
- g_system->copyRectToScreen(_activeScreen + _upscaledMapping[rect.top] * _displayWidth + rect.left * 2, _displayWidth, rect.left * 2, _upscaledMapping[rect.top], rect.width() * 2, rectHeight);
+ int rectHeight = _upscaledHeightMapping[rect.bottom] - _upscaledHeightMapping[rect.top];
+ int rectWidth = _upscaledWidthMapping[rect.right] - _upscaledWidthMapping[rect.left];
+ g_system->copyRectToScreen(_activeScreen + _upscaledHeightMapping[rect.top] * _displayWidth + _upscaledWidthMapping[rect.left], _displayWidth, _upscaledWidthMapping[rect.left], _upscaledHeightMapping[rect.top], rectWidth, rectHeight);
}
}
@@ -204,8 +230,10 @@ void GfxScreen::copyRectToScreen(const Common::Rect &rect, int16 x, int16 y) {
if (!_upscaledHires) {
g_system->copyRectToScreen(_activeScreen + rect.top * _displayWidth + rect.left, _displayWidth, x, y, rect.width(), rect.height());
} else {
- int rectHeight = _upscaledMapping[rect.bottom] - _upscaledMapping[rect.top];
- g_system->copyRectToScreen(_activeScreen + _upscaledMapping[rect.top] * _displayWidth + rect.left * 2, _displayWidth, x * 2, _upscaledMapping[y], rect.width() * 2, rectHeight);
+ int rectHeight = _upscaledHeightMapping[rect.bottom] - _upscaledHeightMapping[rect.top];
+ int rectWidth = _upscaledWidthMapping[rect.right] - _upscaledWidthMapping[rect.left];
+
+ g_system->copyRectToScreen(_activeScreen + _upscaledHeightMapping[rect.top] * _displayWidth + _upscaledWidthMapping[rect.left], _displayWidth, _upscaledWidthMapping[x], _upscaledHeightMapping[y], rectWidth, rectHeight);
}
}
@@ -228,14 +256,7 @@ void GfxScreen::putPixel(int x, int y, byte drawMask, byte color, byte priority,
if (!_upscaledHires) {
_displayScreen[offset] = color;
} else {
- int displayOffset = _upscaledMapping[y] * _displayWidth + x * 2;
- int heightOffsetBreak = (_upscaledMapping[y + 1] - _upscaledMapping[y]) * _displayWidth;
- int heightOffset = 0;
- do {
- _displayScreen[displayOffset + heightOffset] = color;
- _displayScreen[displayOffset + heightOffset + 1] = color;
- heightOffset += _displayWidth;
- } while (heightOffset != heightOffsetBreak);
+ putScaledPixelOnDisplay(x, y, color);
}
}
if (drawMask & GFX_SCREEN_MASK_PRIORITY)
@@ -250,22 +271,21 @@ void GfxScreen::putPixel(int x, int y, byte drawMask, byte color, byte priority,
* Sierra SCI didn't do this
*/
void GfxScreen::putFontPixel(int startingY, int x, int y, byte color) {
+ int actualY = startingY + y;
if (_fontIsUpscaled) {
// Do not scale ourselves, but put it on the display directly
- putPixelOnDisplay(x, y + startingY, color);
+ putPixelOnDisplay(x, actualY, color);
} else {
- int offset = (startingY + y) * _pitch + x;
+ int offset = actualY * _pitch + x;
_visualScreen[offset] = color;
- if (!_upscaledHires) {
+ switch (_upscaledHires) {
+ case GFX_SCREEN_UPSCALED_DISABLED:
_displayScreen[offset] = color;
- } else {
- int displayOffset = (_upscaledMapping[startingY] + y * 2) * _displayWidth + x * 2;
- _displayScreen[displayOffset] = color;
- _displayScreen[displayOffset + 1] = color;
- displayOffset += _displayWidth;
- _displayScreen[displayOffset] = color;
- _displayScreen[displayOffset + 1] = color;
+ break;
+ default:
+ putScaledPixelOnDisplay(x, actualY, color);
+ break;
}
}
}
@@ -280,6 +300,21 @@ void GfxScreen::putPixelOnDisplay(int x, int y, byte color) {
_displayScreen[offset] = color;
}
+void GfxScreen::putScaledPixelOnDisplay(int x, int y, byte color) {
+ int displayOffset = _upscaledHeightMapping[y] * _displayWidth + _upscaledWidthMapping[x];
+ int heightOffsetBreak = (_upscaledHeightMapping[y + 1] - _upscaledHeightMapping[y]) * _displayWidth;
+ int heightOffset = 0;
+ int widthOffsetBreak = _upscaledWidthMapping[x + 1] - _upscaledWidthMapping[x];
+ do {
+ int widthOffset = 0;
+ do {
+ _displayScreen[displayOffset + heightOffset + widthOffset] = color;
+ widthOffset++;
+ } while (widthOffset != widthOffsetBreak);
+ heightOffset += _displayWidth;
+ } while (heightOffset != heightOffsetBreak);
+}
+
/**
* Sierra's Bresenham line drawing.
* WARNING: Do not replace this with Graphics::drawLine(), as this causes issues
@@ -409,8 +444,9 @@ int GfxScreen::bitsGetDataSize(Common::Rect rect, byte mask) {
if (!_upscaledHires) {
byteCount += pixels; // _displayScreen
} else {
- int rectHeight = _upscaledMapping[rect.bottom] - _upscaledMapping[rect.top];
- byteCount += rectHeight * rect.width() * 2; // _displayScreen (upscaled hires)
+ int rectHeight = _upscaledHeightMapping[rect.bottom] - _upscaledHeightMapping[rect.top];
+ int rectWidth = _upscaledWidthMapping[rect.right] - _upscaledWidthMapping[rect.left];
+ byteCount += rectHeight * rect.width() * rectWidth; // _displayScreen (upscaled hires)
}
}
if (mask & GFX_SCREEN_MASK_PRIORITY) {
@@ -463,16 +499,17 @@ void GfxScreen::bitsSaveScreen(Common::Rect rect, byte *screen, uint16 screenWid
void GfxScreen::bitsSaveDisplayScreen(Common::Rect rect, byte *&memoryPtr) {
byte *screen = _displayScreen;
- int width = rect.width();
+ int width;
int y;
if (!_upscaledHires) {
+ width = rect.width();
screen += (rect.top * _displayWidth) + rect.left;
} else {
- screen += (_upscaledMapping[rect.top] * _displayWidth) + rect.left * 2;
- width *= 2;
- rect.top = _upscaledMapping[rect.top];
- rect.bottom = _upscaledMapping[rect.bottom];
+ screen += (_upscaledHeightMapping[rect.top] * _displayWidth) + _upscaledWidthMapping[rect.left];
+ width = _upscaledWidthMapping[rect.right] - _upscaledWidthMapping[rect.left];
+ rect.top = _upscaledHeightMapping[rect.top];
+ rect.bottom = _upscaledHeightMapping[rect.bottom];
}
for (y = rect.top; y < rect.bottom; y++) {
@@ -528,16 +565,17 @@ void GfxScreen::bitsRestoreScreen(Common::Rect rect, byte *&memoryPtr, byte *scr
void GfxScreen::bitsRestoreDisplayScreen(Common::Rect rect, byte *&memoryPtr) {
byte *screen = _displayScreen;
- int width = rect.width();
+ int width;
int y;
if (!_upscaledHires) {
screen += (rect.top * _displayWidth) + rect.left;
+ width = rect.width();
} else {
- screen += (_upscaledMapping[rect.top] * _displayWidth) + rect.left * 2;
- width *= 2;
- rect.top = _upscaledMapping[rect.top];
- rect.bottom = _upscaledMapping[rect.bottom];
+ screen += (_upscaledHeightMapping[rect.top] * _displayWidth) + _upscaledWidthMapping[rect.left];
+ width = _upscaledWidthMapping[rect.right] - _upscaledWidthMapping[rect.left];
+ rect.top = _upscaledHeightMapping[rect.top];
+ rect.bottom = _upscaledHeightMapping[rect.bottom];
}
for (y = rect.top; y < rect.bottom; y++) {
@@ -550,7 +588,7 @@ void GfxScreen::setVerticalShakePos(uint16 shakePos) {
if (!_upscaledHires)
g_system->setShakePos(shakePos);
else
- g_system->setShakePos(shakePos * 2);
+ g_system->setShakePos(_upscaledHeightMapping[shakePos]);
}
void GfxScreen::kernelShakeScreen(uint16 shakeCount, uint16 directions) {
@@ -583,20 +621,18 @@ void GfxScreen::dither(bool addToFlag) {
if (color & 0xF0) {
color ^= color << 4;
color = ((x^y) & 1) ? color >> 4 : color & 0x0F;
- *displayPtr = color;
- if (_upscaledHires) {
- *(displayPtr + 1) = color;
- *(displayPtr + _displayWidth) = color;
- *(displayPtr + _displayWidth + 1) = color;
+ switch (_upscaledHires) {
+ case GFX_SCREEN_UPSCALED_DISABLED:
+ *displayPtr = color;
+ break;
+ default:
+ putScaledPixelOnDisplay(x, y, color);
+ break;
}
*visualPtr = color;
}
visualPtr++; displayPtr++;
- if (_upscaledHires)
- displayPtr++;
}
- if (_upscaledHires)
- displayPtr += _displayWidth;
}
} else {
if (!addToFlag)
@@ -616,21 +652,19 @@ void GfxScreen::dither(bool addToFlag) {
} else {
ditheredColor = color << 4;
}
- *displayPtr = ditheredColor;
- if (_upscaledHires) {
- *(displayPtr + 1) = ditheredColor;
- *(displayPtr + _displayWidth) = ditheredColor;
- *(displayPtr + _displayWidth + 1) = ditheredColor;
+ switch (_upscaledHires) {
+ case GFX_SCREEN_UPSCALED_DISABLED:
+ *displayPtr = ditheredColor;
+ break;
+ default:
+ putScaledPixelOnDisplay(x, y, ditheredColor);
+ break;
}
color = ((x^y) & 1) ? color >> 4 : color & 0x0F;
*visualPtr = color;
}
visualPtr++; displayPtr++;
- if (_upscaledHires)
- displayPtr++;
}
- if (_upscaledHires)
- displayPtr += _displayWidth;
}
}
}
@@ -722,8 +756,8 @@ static const UpScaledAdjust s_upscaledAdjustTable[] = {
};
void GfxScreen::adjustToUpscaledCoordinates(int16 &y, int16 &x, Sci32ViewNativeResolution viewNativeRes) {
- x *= 2;
- y = _upscaledMapping[y];
+ x = _upscaledWidthMapping[x];
+ y = _upscaledHeightMapping[y];
for (int i = 0; i < ARRAYSIZE(s_upscaledAdjustTable); i++) {
if (s_upscaledAdjustTable[i].gameHiresMode == _upscaledHires &&
@@ -744,6 +778,10 @@ void GfxScreen::adjustBackUpscaledCoordinates(int16 &y, int16 &x, Sci32ViewNativ
}
switch (_upscaledHires) {
+ case GFX_SCREEN_UPSCALED_480x300:
+ x = (x << 1) / 3;
+ y = (y << 1) / 3;
+ break;
case GFX_SCREEN_UPSCALED_640x400:
x /= 2;
y /= 2;
diff --git a/engines/sci/graphics/screen.h b/engines/sci/graphics/screen.h
index 01fb899edb..e266a4ed16 100644
--- a/engines/sci/graphics/screen.h
+++ b/engines/sci/graphics/screen.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -32,12 +32,14 @@
namespace Sci {
#define SCI_SCREEN_UPSCALEDMAXHEIGHT 200
+#define SCI_SCREEN_UPSCALEDMAXWIDTH 320
enum GfxScreenUpscaledMode {
GFX_SCREEN_UPSCALED_DISABLED = 0,
- GFX_SCREEN_UPSCALED_640x400 = 1,
- GFX_SCREEN_UPSCALED_640x440 = 2,
- GFX_SCREEN_UPSCALED_640x480 = 3
+ GFX_SCREEN_UPSCALED_480x300 = 1,
+ GFX_SCREEN_UPSCALED_640x400 = 2,
+ GFX_SCREEN_UPSCALED_640x440 = 3,
+ GFX_SCREEN_UPSCALED_640x480 = 4
};
enum GfxScreenMasks {
@@ -83,6 +85,7 @@ public:
void putPixel(int x, int y, byte drawMask, byte color, byte prio, byte control);
void putFontPixel(int startingY, int x, int y, byte color);
void putPixelOnDisplay(int x, int y, byte color);
+ void putScaledPixelOnDisplay(int x, int y, byte color);
void drawLine(Common::Point startPoint, Common::Point endPoint, byte color, byte prio, byte control);
void drawLine(int16 left, int16 top, int16 right, int16 bottom, byte color, byte prio, byte control) {
drawLine(Common::Point(left, top), Common::Point(right, bottom), color, prio, control);
@@ -184,10 +187,11 @@ private:
GfxScreenUpscaledMode _upscaledHires;
/**
- * This here holds a translation for vertical coordinates between native
+ * This here holds a translation for vertical+horizontal coordinates between native
* (visual) and actual (display) screen.
*/
- int _upscaledMapping[SCI_SCREEN_UPSCALEDMAXHEIGHT + 1];
+ int _upscaledHeightMapping[SCI_SCREEN_UPSCALEDMAXHEIGHT + 1];
+ int _upscaledWidthMapping[SCI_SCREEN_UPSCALEDMAXWIDTH + 1];
/**
* This defines whether or not the font we're drawing is already scaled
diff --git a/engines/sci/graphics/text16.cpp b/engines/sci/graphics/text16.cpp
index 56e9ea8b69..245d6996cb 100644
--- a/engines/sci/graphics/text16.cpp
+++ b/engines/sci/graphics/text16.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/text16.h b/engines/sci/graphics/text16.h
index 321c7fc25e..ab0cb13a64 100644
--- a/engines/sci/graphics/text16.h
+++ b/engines/sci/graphics/text16.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/text32.cpp b/engines/sci/graphics/text32.cpp
index f14ae2ef0b..56ce73e8fa 100644
--- a/engines/sci/graphics/text32.cpp
+++ b/engines/sci/graphics/text32.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/text32.h b/engines/sci/graphics/text32.h
index ce78003fdf..7ba7df50e4 100644
--- a/engines/sci/graphics/text32.h
+++ b/engines/sci/graphics/text32.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/transitions.cpp b/engines/sci/graphics/transitions.cpp
index b385c2c1db..5e7dbc6c15 100644
--- a/engines/sci/graphics/transitions.cpp
+++ b/engines/sci/graphics/transitions.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/transitions.h b/engines/sci/graphics/transitions.h
index 246f681690..ae9ca4b48a 100644
--- a/engines/sci/graphics/transitions.h
+++ b/engines/sci/graphics/transitions.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/graphics/view.cpp b/engines/sci/graphics/view.cpp
index 36aaae9232..f3f352e5b8 100644
--- a/engines/sci/graphics/view.cpp
+++ b/engines/sci/graphics/view.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -55,6 +55,56 @@ static const byte EGAmappingStraight[SCI_VIEW_EGAMAPPING_SIZE] = {
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
};
+static const byte ViewInject_LauraBow2_Dual[] = {
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x37,0x37,0x37,0x37,0x00,0x00,0x37,0x37,0x00,0x00,0x37,0x37,0x00,0x00,0x00,0x37,0x37,0x37,0x00,0x00,0x37,0x37,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x08,0x08,0x08,0x37,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x08,0x08,0x37,0x00,0x37,0x08,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x33,0x32,0x37,0x08,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x32,0x32,0x33,0x08,0x32,0x37,0x08,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x33,0x37,0x37,0x08,0x32,0x37,0x08,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x08,0x08,0x08,0x08,0x32,0x37,0x08,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x32,0x32,0x33,0x08,0x32,0x37,0x08,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x33,0x37,0x37,0x08,0x32,0x37,0x08,0x33,0x37,0x37,0x08,0x32,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x33,0x37,0x37,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x37,0x08,0x08,0x08,0x08,0x32,0x00,0x00,0x37,0x08,0x08,0x08,0x32,0x00,0x37,0x08,0x32,0x00,0x37,0x08,0x32,0x37,0x08,0x08,0x08,0x08,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x32,0x32,0x32,0x32,0x00,0x00,0x00,0x00,0x32,0x32,0x32,0x00,0x00,0x00,0x32,0x32,0x00,0x00,0x32,0x32,0x00,0x32,0x32,0x32,0x32,0x32,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
+ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00
+};
+
+static const byte ViewInject_KingsQuest6_Dual1[] = {
+ 0x17,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x13,
+ 0x17,0x17,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x13,0x11,
+ 0x16,0x17,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x17,0x16,0x16,0x16,0x16,0x13,0x13,0x17,0x16,0x13,0x13,0x17,0x16,0x13,0x13,0x13,0x17,0x16,0x16,0x13,0x13,0x17,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x10,0x10,0x10,0x16,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x10,0x10,0x16,0x13,0x16,0x10,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x11,0x11,0x16,0x10,0x11,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x11,0x11,0x13,0x10,0x11,0x16,0x10,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x13,0x16,0x16,0x10,0x11,0x16,0x10,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x10,0x10,0x10,0x10,0x11,0x16,0x10,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x11,0x11,0x13,0x10,0x11,0x16,0x10,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x13,0x16,0x16,0x10,0x11,0x16,0x10,0x13,0x16,0x16,0x10,0x11,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x10,0x13,0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x16,0x10,0x10,0x10,0x10,0x11,0x11,0x13,0x16,0x10,0x10,0x10,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x13,0x10,0x10,0x10,0x10,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x13,0x13,0x13,0x11,0x11,0x11,0x13,0x13,0x13,0x11,0x11,0x13,0x13,0x11,0x11,0x13,0x11,0x11,0x11,0x11,0x11,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x11,
+ 0x16,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,
+ 0x13,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x11
+};
+
+static const byte ViewInject_KingsQuest6_Dual2[] = {
+ 0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,
+ 0x10,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x10,
+ 0x10,0x13,0x16,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x16,0x13,0x13,0x13,0x13,0x11,0x11,0x16,0x13,0x11,0x11,0x16,0x13,0x11,0x11,0x11,0x16,0x13,0x13,0x11,0x11,0x16,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x16,0x16,0x16,0x13,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x16,0x16,0x13,0x11,0x13,0x16,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x10,0x10,0x13,0x16,0x10,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x10,0x10,0x11,0x16,0x10,0x13,0x16,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x11,0x13,0x13,0x16,0x10,0x13,0x16,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x16,0x16,0x16,0x16,0x10,0x13,0x16,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x10,0x10,0x11,0x16,0x10,0x13,0x16,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x11,0x13,0x13,0x16,0x10,0x13,0x16,0x11,0x13,0x13,0x16,0x10,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x13,0x16,0x11,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x13,0x16,0x16,0x16,0x16,0x10,0x10,0x11,0x13,0x16,0x16,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x13,0x16,0x10,0x11,0x16,0x16,0x16,0x16,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x10,0x10,0x10,0x11,0x11,0x11,0x10,0x10,0x11,0x11,0x10,0x10,0x11,0x10,0x10,0x10,0x10,0x10,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x13,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x10,0x10,
+ 0x10,0x11,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,
+ 0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10
+};
+
void GfxView::initData(GuiResourceId resourceId) {
_resource = _resMan->findResource(ResourceId(kResourceTypeView, resourceId), true);
if (!_resource) {
@@ -316,6 +366,68 @@ void GfxView::initData(GuiResourceId resourceId) {
default:
error("ViewType was not detected, can't continue");
}
+
+ // Inject our own views
+ // Currently only used for Dual mode (speech + text) for games, that do not have a "dual" icon already
+ // Which is Laura Bow 2 + King's Quest 6
+ switch (g_sci->getGameId()) {
+ case GID_LAURABOW2:
+ // View 995, Loop 13, Cel 0 = "TEXT"
+ // View 995, Loop 13, Cel 1 = "SPEECH"
+ // View 995, Loop 13, Cel 2 = "DUAL" (<- our injected view)
+ if ((g_sci->isCD()) && (resourceId == 995)) {
+ // security checks
+ if (_loopCount >= 14) {
+ if ((_loop[13].celCount == 2) && (_loop[13].cel[0].width == 46) && (_loop[13].cel[0].height == 11)) {
+ // copy current cels over
+ CelInfo *newCels = new CelInfo[3];
+ memcpy(newCels, _loop[13].cel, sizeof(CelInfo) * 2);
+ delete[] _loop[13].cel;
+ _loop[13].celCount++;
+ _loop[13].cel = newCels;
+ // Duplicate cel 0 to cel 2
+ memcpy(&_loop[13].cel[2], &_loop[13].cel[0], sizeof(CelInfo));
+ // copy over our data (which is uncompressed bitmap data)
+ _loop[13].cel[2].rawBitmap = new byte[sizeof(ViewInject_LauraBow2_Dual)];
+ memcpy(_loop[13].cel[2].rawBitmap, ViewInject_LauraBow2_Dual, sizeof(ViewInject_LauraBow2_Dual));
+ }
+ }
+ }
+ break;
+ case GID_KQ6:
+ // View 947, Loop 8, Cel 0 = "SPEECH" (not pressed)
+ // View 947, Loop 8, Cel 1 = "SPEECH" (pressed)
+ // View 947, Loop 9, Cel 0 = "TEXT" (not pressed)
+ // View 947, Loop 9, Cel 1 = "TEXT" (pressed)
+ // View 947, Loop 12, Cel 0 = "DUAL" (not pressed) (<- our injected view)
+ // View 947, Loop 12, Cel 1 = "DUAL" (pressed) (<- our injected view)
+ if ((g_sci->isCD()) && (resourceId == 947)) {
+ // security checks
+ if (_loopCount == 12) {
+ if ((_loop[8].celCount == 2) && (_loop[8].cel[0].width == 50) && (_loop[8].cel[0].height == 15)) {
+ // add another loop
+ LoopInfo *newLoops = new LoopInfo[_loopCount + 1];
+ memcpy(newLoops, _loop, sizeof(LoopInfo) * _loopCount);
+ delete[] _loop;
+ _loop = newLoops;
+ _loopCount++;
+ // copy loop 8 to loop 12
+ memcpy(&_loop[12], &_loop[8], sizeof(LoopInfo));
+ _loop[12].cel = new CelInfo[2];
+ // duplicate all cels of loop 8 and into loop 12
+ memcpy(_loop[12].cel, _loop[8].cel, sizeof(CelInfo) * _loop[8].celCount);
+ // copy over our data (which is uncompressed bitmap data)
+ _loop[12].cel[0].rawBitmap = new byte[sizeof(ViewInject_KingsQuest6_Dual1)];
+ memcpy(_loop[12].cel[0].rawBitmap, ViewInject_KingsQuest6_Dual1, sizeof(ViewInject_KingsQuest6_Dual1));
+ _loop[12].cel[1].rawBitmap = new byte[sizeof(ViewInject_KingsQuest6_Dual2)];
+ memcpy(_loop[12].cel[1].rawBitmap, ViewInject_KingsQuest6_Dual2, sizeof(ViewInject_KingsQuest6_Dual2));
+ }
+ }
+ }
+ break;
+ default:
+ break;
+ }
}
GuiResourceId GfxView::getResourceId() const {
diff --git a/engines/sci/graphics/view.h b/engines/sci/graphics/view.h
index d3473f1024..d8803db208 100644
--- a/engines/sci/graphics/view.h
+++ b/engines/sci/graphics/view.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/parser/grammar.cpp b/engines/sci/parser/grammar.cpp
index 26e3ec9238..05764ba0a8 100644
--- a/engines/sci/parser/grammar.cpp
+++ b/engines/sci/parser/grammar.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -397,7 +397,7 @@ ParseRuleList *Vocabulary::buildGNF(bool verbose) {
ntrules_nr = _vocab_rule_list_length(ntlist);
if (verbose)
- con->DebugPrintf("Starting with %d rules\n", ntrules_nr);
+ con->debugPrintf("Starting with %d rules\n", ntrules_nr);
new_tlist = tlist;
tlist = NULL;
@@ -425,17 +425,17 @@ ParseRuleList *Vocabulary::buildGNF(bool verbose) {
termrules = _vocab_rule_list_length(new_new_tlist);
if (verbose)
- con->DebugPrintf("After iteration #%d: %d new term rules\n", ++iterations, termrules);
+ con->debugPrintf("After iteration #%d: %d new term rules\n", ++iterations, termrules);
} while (termrules && (iterations < 30));
freeRuleList(ntlist);
if (verbose) {
- con->DebugPrintf("\nGNF rules:\n");
+ con->debugPrintf("\nGNF rules:\n");
tlist->print();
- con->DebugPrintf("%d allocd rules\n", _allocd_rules);
- con->DebugPrintf("Freeing rule list...\n");
+ con->debugPrintf("%d allocd rules\n", _allocd_rules);
+ con->debugPrintf("Freeing rule list...\n");
freeRuleList(tlist);
return NULL;
}
@@ -548,7 +548,7 @@ int Vocabulary::parseGNF(const ResultWordListList &words, bool verbose) {
ParseRuleList *seeker, *subseeker;
if (verbose)
- con->DebugPrintf("Adding word %d...\n", word);
+ con->debugPrintf("Adding word %d...\n", word);
seeker = work;
while (seeker) {
@@ -562,7 +562,7 @@ int Vocabulary::parseGNF(const ResultWordListList &words, bool verbose) {
if (reduced_rules == NULL) {
freeRuleList(work);
if (verbose)
- con->DebugPrintf("No results.\n");
+ con->debugPrintf("No results.\n");
return 1;
}
@@ -592,10 +592,10 @@ int Vocabulary::parseGNF(const ResultWordListList &words, bool verbose) {
work = new_work;
if (verbose)
- con->DebugPrintf("Now at %d candidates\n", _vocab_rule_list_length(work));
+ con->debugPrintf("Now at %d candidates\n", _vocab_rule_list_length(work));
if (work == NULL) {
if (verbose)
- con->DebugPrintf("No results.\n");
+ con->debugPrintf("No results.\n");
return 1;
}
}
@@ -603,9 +603,9 @@ int Vocabulary::parseGNF(const ResultWordListList &words, bool verbose) {
results = work;
if (verbose) {
- con->DebugPrintf("All results (excluding the surrounding '(141 %03x' and ')'):\n", _parserBranches[0].id);
+ con->debugPrintf("All results (excluding the surrounding '(141 %03x' and ')'):\n", _parserBranches[0].id);
results->print();
- con->DebugPrintf("\n");
+ con->debugPrintf("\n");
}
// now use the first result
diff --git a/engines/sci/parser/said.cpp b/engines/sci/parser/said.cpp
index eff4a29f49..693bbec744 100644
--- a/engines/sci/parser/said.cpp
+++ b/engines/sci/parser/said.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/parser/vocabulary.cpp b/engines/sci/parser/vocabulary.cpp
index f5b79d6c5e..b4a223dcff 100644
--- a/engines/sci/parser/vocabulary.cpp
+++ b/engines/sci/parser/vocabulary.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -577,7 +577,7 @@ void Vocabulary::printSuffixes() const {
strncpy(alt_buf, suf->alt_suffix, suf->alt_suffix_length);
alt_buf[suf->alt_suffix_length] = 0;
- con->DebugPrintf("%4d: (%03x) -%12s => -%12s (%03x)\n", i, suf->class_mask, word_buf, alt_buf, suf->result_class);
+ con->debugPrintf("%4d: (%03x) -%12s => -%12s (%03x)\n", i, suf->class_mask, word_buf, alt_buf, suf->result_class);
++i;
}
}
@@ -588,14 +588,14 @@ void Vocabulary::printParserWords() const {
int n = 0;
for (WordMap::iterator i = _parserWords.begin(); i != _parserWords.end(); ++i) {
for (ResultWordList::iterator j = i->_value.begin(); j != i->_value.end(); ++j) {
- con->DebugPrintf("%4d: %03x [%03x] %20s |", n, j->_class, j->_group, i->_key.c_str());
+ con->debugPrintf("%4d: %03x [%03x] %20s |", n, j->_class, j->_group, i->_key.c_str());
if (n % 3 == 0)
- con->DebugPrintf("\n");
+ con->debugPrintf("\n");
n++;
}
}
- con->DebugPrintf("\n");
+ con->debugPrintf("\n");
}
void _vocab_recursive_ptree_dump(ParseTreeNode *tree, int blanks) {
@@ -665,15 +665,15 @@ void Vocabulary::printParserNodes(int num) {
Console *con = g_sci->getSciDebugger();
for (int i = 0; i < num; i++) {
- con->DebugPrintf(" Node %03x: ", i);
+ con->debugPrintf(" Node %03x: ", i);
if (_parserNodes[i].type == kParseTreeLeafNode)
- con->DebugPrintf("Leaf: %04x\n", _parserNodes[i].value);
+ con->debugPrintf("Leaf: %04x\n", _parserNodes[i].value);
else {
// FIXME: Do we really want to print the *addresses*
// of the left & right child?
// Note that one or both may be zero pointers, so we can't just
// print their values.
- con->DebugPrintf("Branch: ->%p, ->%p\n",
+ con->debugPrintf("Branch: ->%p, ->%p\n",
(const void *)_parserNodes[i].left,
(const void *)_parserNodes[i].right);
}
@@ -694,11 +694,11 @@ int Vocabulary::parseNodes(int *i, int *pos, int type, int nr, int argc, const c
return *pos;
}
if (type == kParseEndOfInput) {
- con->DebugPrintf("Unbalanced parentheses\n");
+ con->debugPrintf("Unbalanced parentheses\n");
return -1;
}
if (type == kParseClosingParenthesis) {
- con->DebugPrintf("Syntax error at token %d\n", *i);
+ con->debugPrintf("Syntax error at token %d\n", *i);
return -1;
}
@@ -724,19 +724,18 @@ int Vocabulary::parseNodes(int *i, int *pos, int type, int nr, int argc, const c
newPos = parseNodes(i, pos, nextToken, nextValue, argc, argv);
+ if (newPos == -1)
+ return -1;
+
if (j == 0)
_parserNodes[oldPos].left = &_parserNodes[newPos];
else
_parserNodes[oldPos].right = &_parserNodes[newPos];
-
-
- if (newPos == -1)
- return -1;
}
const char *token = argv[(*i)++];
if (strcmp(token, ")"))
- con->DebugPrintf("Expected ')' at token %d\n", *i);
+ con->debugPrintf("Expected ')' at token %d\n", *i);
return oldPos;
}
diff --git a/engines/sci/parser/vocabulary.h b/engines/sci/parser/vocabulary.h
index e4a7e41b3c..09499946cb 100644
--- a/engines/sci/parser/vocabulary.h
+++ b/engines/sci/parser/vocabulary.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/resource.cpp b/engines/sci/resource.cpp
index d14c965ebb..17195c14b8 100644
--- a/engines/sci/resource.cpp
+++ b/engines/sci/resource.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -112,11 +112,12 @@ static const char *const s_resourceTypeNames[] = {
"audio", "sync", "message", "map", "heap",
"audio36", "sync36", "xlate", "robot", "vmd",
"chunk", "animation", "etc", "duck", "clut",
- "tga", "zzz", "macibin", "macibis", "macpict"
+ "tga", "zzz", "macibin", "macibis", "macpict",
+ "rave"
};
// Resource type suffixes. Note that the
-// suffic of SCI3 scripts has been changed from
+// suffix of SCI3 scripts has been changed from
// scr to csc
static const char *const s_resourceTypeSuffixes[] = {
"v56", "p56", "scr", "tex", "snd",
@@ -125,7 +126,7 @@ static const char *const s_resourceTypeSuffixes[] = {
"msg", "map", "hep", "", "",
"trn", "rbt", "vmd", "chk", "",
"etc", "duk", "clu", "tga", "zzz",
- "", "", ""
+ "", "", "", ""
};
const char *getResourceTypeName(ResourceType restype) {
@@ -141,7 +142,7 @@ static const ResourceType s_resTypeMapSci0[] = {
kResourceTypeCursor, kResourceTypePatch, kResourceTypeBitmap, kResourceTypePalette, // 0x08-0x0B
kResourceTypeCdAudio, kResourceTypeAudio, kResourceTypeSync, kResourceTypeMessage, // 0x0C-0x0F
kResourceTypeMap, kResourceTypeHeap, kResourceTypeAudio36, kResourceTypeSync36, // 0x10-0x13
- kResourceTypeTranslation // 0x14
+ kResourceTypeTranslation, kResourceTypeRave // 0x14
};
// TODO: 12 should be "Wave", but SCI seems to just store it in Audio resources
@@ -207,7 +208,7 @@ void Resource::unalloc() {
}
void Resource::writeToStream(Common::WriteStream *stream) const {
- stream->writeByte(getType() | 0x80); // 0x80 is required by old sierra sci, otherwise it wont accept the patch file
+ stream->writeByte(getType() | 0x80); // 0x80 is required by old Sierra SCI, otherwise it wont accept the patch file
stream->writeByte(_headerSize);
if (_headerSize > 0)
stream->write(_header, _headerSize);
@@ -383,42 +384,13 @@ void PatchResourceSource::loadResource(ResourceManager *resMan, Resource *res) {
static Common::Array<uint32> resTypeToMacTags(ResourceType type);
-static Common::String intToBase36(uint32 number, int minChar) {
- // Convert from an integer to a base36 string
- Common::String string;
-
- while (minChar--) {
- int character = number % 36;
- string = ((character < 10) ? (character + '0') : (character + 'A' - 10)) + string;
- number /= 36;
- }
-
- return string;
-}
-
-static Common::String constructPatchNameBase36(ResourceId resId) {
- // Convert from a resource ID to a base36 patch name
- Common::String output;
-
- output += (resId.getType() == kResourceTypeAudio36) ? '@' : '#'; // Identifier
- output += intToBase36(resId.getNumber(), 3); // Map
- output += intToBase36(resId.getTuple() >> 24, 2); // Noun
- output += intToBase36((resId.getTuple() >> 16) & 0xff, 2); // Verb
- output += '.'; // Separator
- output += intToBase36((resId.getTuple() >> 8) & 0xff, 2); // Cond
- output += intToBase36(resId.getTuple() & 0xff, 1); // Seq
-
- assert(output.size() == 12); // We should always get 12 characters in the end
- return output;
-}
-
void MacResourceForkResourceSource::loadResource(ResourceManager *resMan, Resource *res) {
ResourceType type = res->getType();
Common::SeekableReadStream *stream = 0;
if (type == kResourceTypeAudio36 || type == kResourceTypeSync36) {
// Handle audio36/sync36, convert back to audio/sync
- stream = _macResMan->getResource(constructPatchNameBase36(res->_id));
+ stream = _macResMan->getResource(res->_id.toPatchNameBase36());
} else {
// Plain resource handling
Common::Array<uint32> tagArray = resTypeToMacTags(type);
@@ -2292,15 +2264,6 @@ void ResourceManager::detectSciVersion() {
s_sciVersion = SCI_VERSION_1_1;
return;
}
- // FIXME: this is really difficult, lsl1 spanish has map/vol sci1late
- // and the only current detection difference is movecounttype which
- // is increment here, but ignore for all the regular sci1late games
- // the problem is, we dont have access to that detection till later
- // so maybe (part of?) that detection should get moved in here
- if (g_sci && (g_sci->getGameId() == GID_LSL1) && (g_sci->getLanguage() == Common::ES_ESP)) {
- s_sciVersion = SCI_VERSION_1_MIDDLE;
- return;
- }
s_sciVersion = SCI_VERSION_1_LATE;
return;
case kResVersionSci11:
diff --git a/engines/sci/resource.h b/engines/sci/resource.h
index 4baf39c67f..e90f52a3ce 100644
--- a/engines/sci/resource.h
+++ b/engines/sci/resource.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -112,6 +112,8 @@ enum ResourceType {
kResourceTypeMacIconBarPictS, // IBIS resources (icon bar, selected)
kResourceTypeMacPict, // PICT resources (inventory)
+ kResourceTypeRave, // KQ6 hires RAVE (special sync) resources
+
kResourceTypeInvalid
};
@@ -143,6 +145,19 @@ class ResourceId {
uint16 _number;
uint32 _tuple; // Only used for audio36 and sync36
+ static Common::String intToBase36(uint32 number, int minChar) {
+ // Convert from an integer to a base36 string
+ Common::String string;
+
+ while (minChar--) {
+ int character = number % 36;
+ string = ((character < 10) ? (character + '0') : (character + 'A' - 10)) + string;
+ number /= 36;
+ }
+
+ return string;
+ }
+
public:
ResourceId() : _type(kResourceTypeInvalid), _number(0), _tuple(0) { }
@@ -169,6 +184,22 @@ public:
return retStr;
}
+ // Convert from a resource ID to a base36 patch name
+ Common::String toPatchNameBase36() {
+ Common::String output;
+
+ output += (getType() == kResourceTypeAudio36) ? '@' : '#'; // Identifier
+ output += intToBase36(getNumber(), 3); // Map
+ output += intToBase36(getTuple() >> 24, 2); // Noun
+ output += intToBase36((getTuple() >> 16) & 0xff, 2); // Verb
+ output += '.'; // Separator
+ output += intToBase36((getTuple() >> 8) & 0xff, 2); // Cond
+ output += intToBase36(getTuple() & 0xff, 1); // Seq
+
+ assert(output.size() == 12); // We should always get 12 characters in the end
+ return output;
+ }
+
inline ResourceType getType() const { return _type; }
inline uint16 getNumber() const { return _number; }
inline uint32 getTuple() const { return _tuple; }
@@ -498,7 +529,7 @@ protected:
void readWaveAudioPatches();
void processWavePatch(ResourceId resourceId, Common::String name);
- /**
+ /**
* Applies to all versions before 0.000.395 (i.e. KQ4 old, XMAS 1988 and LSL2).
* Old SCI versions used two word header for script blocks (first word equal
* to 0x82, meaning of the second one unknown). New SCI versions used one
@@ -523,6 +554,7 @@ class SoundResource {
public:
struct Channel {
byte number;
+ byte flags;
byte poly;
uint16 prio;
uint16 size;
diff --git a/engines/sci/resource_audio.cpp b/engines/sci/resource_audio.cpp
index 744f05f2b9..4c7cd9b84a 100644
--- a/engines/sci/resource_audio.cpp
+++ b/engines/sci/resource_audio.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -101,32 +101,34 @@ bool Resource::loadFromAudioVolumeSCI11(Common::SeekableReadStream *file) {
}
file->seek(-4, SEEK_CUR);
- ResourceType type = _resMan->convertResType(file->readByte());
- if (((getType() == kResourceTypeAudio || getType() == kResourceTypeAudio36) && (type != kResourceTypeAudio))
- || ((getType() == kResourceTypeSync || getType() == kResourceTypeSync36) && (type != kResourceTypeSync))) {
- warning("Resource type mismatch loading %s", _id.toString().c_str());
- unalloc();
- return false;
- }
-
- _headerSize = file->readByte();
-
- if (type == kResourceTypeAudio) {
- if (_headerSize != 7 && _headerSize != 11 && _headerSize != 12) {
- warning("Unsupported audio header");
+ // Rave-resources (King's Quest 6) don't have any header at all
+ if (getType() != kResourceTypeRave) {
+ ResourceType type = _resMan->convertResType(file->readByte());
+ if (((getType() == kResourceTypeAudio || getType() == kResourceTypeAudio36) && (type != kResourceTypeAudio))
+ || ((getType() == kResourceTypeSync || getType() == kResourceTypeSync36) && (type != kResourceTypeSync))) {
+ warning("Resource type mismatch loading %s", _id.toString().c_str());
unalloc();
return false;
}
+
+ _headerSize = file->readByte();
+
+ if (type == kResourceTypeAudio) {
+ if (_headerSize != 7 && _headerSize != 11 && _headerSize != 12) {
+ warning("Unsupported audio header");
+ unalloc();
+ return false;
+ }
- if (_headerSize != 7) { // Size is defined already from the map
- // Load sample size
- file->seek(7, SEEK_CUR);
- size = file->readUint32LE();
- // Adjust offset to point at the header data again
- file->seek(-11, SEEK_CUR);
+ if (_headerSize != 7) { // Size is defined already from the map
+ // Load sample size
+ file->seek(7, SEEK_CUR);
+ size = file->readUint32LE();
+ // Adjust offset to point at the header data again
+ file->seek(-11, SEEK_CUR);
+ }
}
}
-
return loadPatch(file);
}
@@ -395,15 +397,22 @@ int ResourceManager::readAudioMapSCI11(ResourceSource *map) {
syncSize = READ_LE_UINT16(ptr);
ptr += 2;
+ // FIXME: The sync36 resource seems to be two bytes too big in KQ6CD
+ // (bytes taken from the RAVE resource right after it)
if (syncSize > 0)
addResource(ResourceId(kResourceTypeSync36, map->_volumeNumber, n & 0xffffff3f), src, offset, syncSize);
}
if (n & 0x40) {
// This seems to define the size of raw lipsync data (at least
- // in kq6), may also just be general appended data.
- syncSize += READ_LE_UINT16(ptr);
+ // in KQ6 CD Windows).
+ int kq6HiresSyncSize = READ_LE_UINT16(ptr);
ptr += 2;
+
+ if (kq6HiresSyncSize > 0) {
+ addResource(ResourceId(kResourceTypeRave, map->_volumeNumber, n & 0xffffff3f), src, offset + syncSize, kq6HiresSyncSize);
+ syncSize += kq6HiresSyncSize;
+ }
}
addResource(ResourceId(kResourceTypeAudio36, map->_volumeNumber, n & 0xffffff3f), src, offset + syncSize);
@@ -590,6 +599,7 @@ SoundResource::SoundResource(uint32 resourceNr, ResourceManager *resMan, SciVers
_tracks->channels = new Channel[_tracks->channelCount];
memset(_tracks->channels, 0, sizeof(Channel) * _tracks->channelCount);
channel = &_tracks->channels[0];
+ channel->flags |= 2; // don't remap (SCI0 doesn't have remapping)
if (_soundVersion == SCI_VERSION_0_EARLY) {
channel->data = resource->data + 0x11;
channel->size = resource->size - 0x11;
@@ -667,33 +677,52 @@ SoundResource::SoundResource(uint32 resourceNr, ResourceManager *resMan, SciVers
channelNr = 0;
while (channelCount--) {
channel = &_tracks[trackNr].channels[channelNr];
- channel->prio = READ_LE_UINT16(data);
uint dataOffset = READ_LE_UINT16(data + 2);
- if (dataOffset < resource->size) {
- channel->data = resource->data + dataOffset;
- channel->size = READ_LE_UINT16(data + 4);
- channel->curPos = 0;
- // FIXME: number contains (low nibble) channel and (high nibble) flags
- // 0x20 is set on rhythm channels to prevent remapping
- channel->number = *channel->data;
- channel->poly = *(channel->data + 1);
- channel->time = channel->prev = 0;
- channel->data += 2; // skip over header
- channel->size -= 2; // remove header size
- if (channel->number == 0xFE) { // Digital channel
- _tracks[trackNr].digitalChannelNr = channelNr;
- _tracks[trackNr].digitalSampleRate = READ_LE_UINT16(channel->data);
- _tracks[trackNr].digitalSampleSize = READ_LE_UINT16(channel->data + 2);
- _tracks[trackNr].digitalSampleStart = READ_LE_UINT16(channel->data + 4);
- _tracks[trackNr].digitalSampleEnd = READ_LE_UINT16(channel->data + 6);
- channel->data += 8; // Skip over header
- channel->size -= 8;
- }
- _tracks[trackNr].channelCount++;
- channelNr++;
- } else {
+
+ if (dataOffset >= resource->size) {
warning("Invalid offset inside sound resource %d: track %d, channel %d", resourceNr, trackNr, channelNr);
+ data += 6;
+ continue;
+ }
+
+ channel->data = resource->data + dataOffset;
+ channel->size = READ_LE_UINT16(data + 4);
+ channel->curPos = 0;
+ channel->number = *channel->data;
+
+ channel->poly = *(channel->data + 1) & 0x0F;
+ channel->prio = *(channel->data + 1) >> 4;
+ channel->time = channel->prev = 0;
+ channel->data += 2; // skip over header
+ channel->size -= 2; // remove header size
+ if (channel->number == 0xFE) { // Digital channel
+ _tracks[trackNr].digitalChannelNr = channelNr;
+ _tracks[trackNr].digitalSampleRate = READ_LE_UINT16(channel->data);
+ _tracks[trackNr].digitalSampleSize = READ_LE_UINT16(channel->data + 2);
+ _tracks[trackNr].digitalSampleStart = READ_LE_UINT16(channel->data + 4);
+ _tracks[trackNr].digitalSampleEnd = READ_LE_UINT16(channel->data + 6);
+ channel->data += 8; // Skip over header
+ channel->size -= 8;
+ channel->flags = 0;
+ } else {
+ channel->flags = channel->number >> 4;
+ channel->number = channel->number & 0x0F;
+
+ // 0x20 is set on rhythm channels to prevent remapping
+ // CHECKME: Which SCI versions need that set manually?
+ channel->flags = (*channel->data) >> 4;
+ if (channel->number == 9)
+ channel->flags |= 2;
+ // Note: flag 1: channel start offset is 0 instead of 10
+ // (currently: everything 0)
+ // also: don't map the channel to device
+ // flag 2: don't remap
+ // flag 4: start muted
+ // QfG2 lacks flags 2 and 4, and uses (flags >= 1) as
+ // the condition for starting offset 0, without the "don't map"
}
+ _tracks[trackNr].channelCount++;
+ channelNr++;
data += 6;
}
} else {
@@ -856,6 +885,7 @@ void AudioVolumeResourceSource::loadResource(ResourceManager *resMan, Resource *
switch (res->getType()) {
case kResourceTypeSync:
case kResourceTypeSync36:
+ case kResourceTypeRave:
// we should already have a (valid) size
break;
default:
diff --git a/engines/sci/resource_intern.h b/engines/sci/resource_intern.h
index c256c9d156..461d684005 100644
--- a/engines/sci/resource_intern.h
+++ b/engines/sci/resource_intern.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp
index c1aadc3622..fc723f18cf 100644
--- a/engines/sci/sci.cpp
+++ b/engines/sci/sci.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -38,6 +38,7 @@
#include "sci/engine/state.h"
#include "sci/engine/kernel.h"
#include "sci/engine/script.h" // for script_adjust_opcode_formats
+#include "sci/engine/script_patches.h"
#include "sci/engine/selector.h" // for SELECTOR
#include "sci/sound/audio.h"
@@ -112,6 +113,7 @@ SciEngine::SciEngine(OSystem *syst, const ADGameDescription *desc, SciGameId gam
DebugMan.addDebugChannel(kDebugLevelDclInflate, "DCL", "DCL inflate debugging");
DebugMan.addDebugChannel(kDebugLevelVM, "VM", "VM debugging");
DebugMan.addDebugChannel(kDebugLevelScripts, "Scripts", "Notifies when scripts are unloaded");
+ DebugMan.addDebugChannel(kDebugLevelScriptPatcher, "ScriptPatcher", "Notifies when scripts are patched");
DebugMan.addDebugChannel(kDebugLevelGC, "GC", "Garbage Collector debugging");
DebugMan.addDebugChannel(kDebugLevelResMan, "ResMan", "Resource manager debugging");
DebugMan.addDebugChannel(kDebugLevelOnStartup, "OnStartup", "Enter debugger at start of game");
@@ -135,7 +137,7 @@ SciEngine::SciEngine(OSystem *syst, const ADGameDescription *desc, SciGameId gam
SearchMan.addSubDirectoryMatching(gameDataDir, "duk"); // Duck movie files in Phantasmagoria 2
SearchMan.addSubDirectoryMatching(gameDataDir, "Robot Folder"); // Mac robot files
SearchMan.addSubDirectoryMatching(gameDataDir, "Sound Folder"); // Mac audio files
- SearchMan.addSubDirectoryMatching(gameDataDir, "Voices Folder"); // Mac audio36 files
+ SearchMan.addSubDirectoryMatching(gameDataDir, "Voices Folder", 0, 2, true); // Mac audio36 files (recursive for Torin)
SearchMan.addSubDirectoryMatching(gameDataDir, "Voices"); // Mac audio36 files
SearchMan.addSubDirectoryMatching(gameDataDir, "VMD Folder"); // Mac VMD files
@@ -183,6 +185,7 @@ SciEngine::~SciEngine() {
delete[] _opcode_formats;
+ delete _scriptPatcher;
delete _resMan; // should be deleted last
g_sci = 0;
}
@@ -216,14 +219,16 @@ Common::Error SciEngine::run() {
// Add the after market GM patches for the specified game, if they exist
_resMan->addNewGMPatch(_gameId);
_gameObjectAddress = _resMan->findGameObject();
-
- SegManager *segMan = new SegManager(_resMan);
+
+ _scriptPatcher = new ScriptPatcher();
+ SegManager *segMan = new SegManager(_resMan, _scriptPatcher);
// Initialize the game screen
_gfxScreen = new GfxScreen(_resMan);
_gfxScreen->enableUndithering(ConfMan.getBool("disable_dithering"));
_kernel = new Kernel(_resMan, segMan);
+ _kernel->init();
_features = new GameFeatures(segMan, _kernel);
// Only SCI0, SCI01 and SCI1 EGA games used a parser
@@ -281,6 +286,11 @@ Common::Error SciEngine::run() {
// We set this, so that the game automatically quit right after init
_gamestate->variables[VAR_GLOBAL][4] = TRUE_REG;
+ // Jones only initializes its menus when restarting/restoring, thus set
+ // the gameIsRestarting flag here before initializing. Fixes bug #6536.
+ if (g_sci->getGameId() == GID_JONES)
+ _gamestate->gameIsRestarting = GAMEISRESTARTING_RESTORE;
+
_gamestate->_executionStackPosChanged = false;
run_vm(_gamestate);
@@ -501,6 +511,7 @@ void SciEngine::patchGameSaveRestore() {
case GID_HOYLE1: // gets confused, although the game doesnt support saving/restoring at all
case GID_HOYLE2: // gets confused, see hoyle1
case GID_JONES: // gets confused, when we patch us in, the game is only able to save to 1 slot, so hooking is not required
+ case GID_MOTHERGOOSE: // mother goose EGA saves/restores directly and has no save/restore dialogs
case GID_MOTHERGOOSE256: // mother goose saves/restores directly and has no save/restore dialogs
case GID_PHANTASMAGORIA: // has custom save/load code
case GID_SHIVERS: // has custom save/load code
@@ -571,7 +582,7 @@ bool SciEngine::initGame() {
// Script 0 should always be at segment 1
if (script0Segment != 1) {
- debug(2, "Failed to instantiate script.000");
+ debug(2, "Failed to instantiate script 0");
return false;
}
@@ -881,8 +892,18 @@ void SciEngine::syncSoundSettings() {
}
}
+// used by Script Patcher. Used to find out, if Laura Bow 2/King's Quest 6 need patching for Speech+Subtitles - or not
+bool SciEngine::speechAndSubtitlesEnabled() {
+ bool subtitlesOn = ConfMan.getBool("subtitles");
+ bool speechOn = !ConfMan.getBool("speech_mute");
+
+ if (isCD() && subtitlesOn && speechOn)
+ return true;
+ return false;
+}
+
void SciEngine::syncIngameAudioOptions() {
- // Now, sync the in-game speech/subtitles settings for SCI1.1 CD games
+ // Sync the in-game speech/subtitles settings for SCI1.1 CD games
if (isCD() && getSciVersion() == SCI_VERSION_1_1) {
bool subtitlesOn = ConfMan.getBool("subtitles");
bool speechOn = !ConfMan.getBool("speech_mute");
@@ -893,16 +914,16 @@ void SciEngine::syncIngameAudioOptions() {
_gamestate->variables[VAR_GLOBAL][90] = make_reg(0, 2); // speech
} else if (subtitlesOn && speechOn) {
// Is it a game that supports simultaneous speech and subtitles?
- if (getGameId() == GID_SQ4
- || getGameId() == GID_FREDDYPHARKAS
- || getGameId() == GID_ECOQUEST
- || getGameId() == GID_LSL6
- // TODO: The following need script patches for simultaneous speech and subtitles
- //|| getGameId() == GID_KQ6
- //|| getGameId() == GID_LAURABOW2
- ) {
+ switch (_gameId) {
+ case GID_SQ4:
+ case GID_FREDDYPHARKAS:
+ case GID_ECOQUEST:
+ case GID_LSL6:
+ case GID_LAURABOW2:
+ case GID_KQ6:
_gamestate->variables[VAR_GLOBAL][90] = make_reg(0, 3); // speech + subtitles
- } else {
+ break;
+ default:
// Game does not support speech and subtitles, set it to speech
_gamestate->variables[VAR_GLOBAL][90] = make_reg(0, 2); // speech
}
@@ -910,6 +931,34 @@ void SciEngine::syncIngameAudioOptions() {
}
}
+void SciEngine::updateScummVMAudioOptions() {
+ // Update ScummVM's speech/subtitles settings for SCI1.1 CD games,
+ // depending on the in-game settings
+ if (isCD() && getSciVersion() == SCI_VERSION_1_1) {
+ uint16 ingameSetting = _gamestate->variables[VAR_GLOBAL][90].getOffset();
+
+ switch (ingameSetting) {
+ case 1:
+ // subtitles
+ ConfMan.setBool("subtitles", true);
+ ConfMan.setBool("speech_mute", true);
+ break;
+ case 2:
+ // speech
+ ConfMan.setBool("subtitles", false);
+ ConfMan.setBool("speech_mute", false);
+ break;
+ case 3:
+ // speech + subtitles
+ ConfMan.setBool("subtitles", true);
+ ConfMan.setBool("speech_mute", false);
+ break;
+ default:
+ break;
+ }
+ }
+}
+
void SciEngine::loadMacExecutable() {
if (getPlatform() != Common::kPlatformMacintosh || getSciVersion() < SCI_VERSION_1_EARLY || getSciVersion() > SCI_VERSION_1_1)
return;
diff --git a/engines/sci/sci.h b/engines/sci/sci.h
index 0a75e115fd..48bc4819d2 100644
--- a/engines/sci/sci.h
+++ b/engines/sci/sci.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -55,6 +55,7 @@ class AudioPlayer;
class SoundCommandParser;
class EventManager;
class SegManager;
+class ScriptPatcher;
class GfxAnimate;
class GfxCache;
@@ -82,28 +83,29 @@ class GfxFrameout;
// our engine debug levels
enum kDebugLevels {
- kDebugLevelError = 1 << 0,
- kDebugLevelNodes = 1 << 1,
- kDebugLevelGraphics = 1 << 2,
- kDebugLevelStrings = 1 << 3,
- kDebugLevelMemory = 1 << 4,
- kDebugLevelFuncCheck = 1 << 5,
- kDebugLevelBresen = 1 << 6,
- kDebugLevelSound = 1 << 7,
- kDebugLevelBaseSetter = 1 << 8,
- kDebugLevelParser = 1 << 9,
- kDebugLevelSaid = 1 << 10,
- kDebugLevelFile = 1 << 11,
- kDebugLevelTime = 1 << 12,
- kDebugLevelRoom = 1 << 13,
- kDebugLevelAvoidPath = 1 << 14,
- kDebugLevelDclInflate = 1 << 15,
- kDebugLevelVM = 1 << 16,
- kDebugLevelScripts = 1 << 17,
- kDebugLevelGC = 1 << 18,
- kDebugLevelResMan = 1 << 19,
- kDebugLevelOnStartup = 1 << 20,
- kDebugLevelDebugMode = 1 << 21
+ kDebugLevelError = 1 << 0,
+ kDebugLevelNodes = 1 << 1,
+ kDebugLevelGraphics = 1 << 2,
+ kDebugLevelStrings = 1 << 3,
+ kDebugLevelMemory = 1 << 4,
+ kDebugLevelFuncCheck = 1 << 5,
+ kDebugLevelBresen = 1 << 6,
+ kDebugLevelSound = 1 << 7,
+ kDebugLevelBaseSetter = 1 << 8,
+ kDebugLevelParser = 1 << 9,
+ kDebugLevelSaid = 1 << 10,
+ kDebugLevelFile = 1 << 11,
+ kDebugLevelTime = 1 << 12,
+ kDebugLevelRoom = 1 << 13,
+ kDebugLevelAvoidPath = 1 << 14,
+ kDebugLevelDclInflate = 1 << 15,
+ kDebugLevelVM = 1 << 16,
+ kDebugLevelScripts = 1 << 17,
+ kDebugLevelGC = 1 << 18,
+ kDebugLevelResMan = 1 << 19,
+ kDebugLevelOnStartup = 1 << 20,
+ kDebugLevelDebugMode = 1 << 21,
+ kDebugLevelScriptPatcher = 1 << 22
};
enum SciGameId {
@@ -244,13 +246,15 @@ public:
* and we add this functionality in ScummVM:
* - Space Quest 4 CD
* - Freddy Pharkas CD
+ * - Laura Bow 2 CD
* SCI1.1 games which don't support simultaneous speech and subtitles,
* and we haven't added any extra functionality in ScummVM because extra
* script patches are needed:
- * - Laura Bow 2 CD
* - King's Quest 6 CD
*/
+ bool speechAndSubtitlesEnabled();
void syncIngameAudioOptions();
+ void updateScummVMAudioOptions();
const SciGameId &getGameId() const { return _gameId; }
const char *getGameIdStr() const;
@@ -266,6 +270,7 @@ public:
bool hasMacIconBar() const;
inline ResourceManager *getResMan() const { return _resMan; }
+ inline ScriptPatcher *getScriptPatcher() const { return _scriptPatcher; }
inline Kernel *getKernel() const { return _kernel; }
inline EngineState *getEngineState() const { return _gamestate; }
inline Vocabulary *getVocabulary() const { return _vocabulary; }
@@ -397,6 +402,7 @@ private:
const ADGameDescription *_gameDescription;
const SciGameId _gameId;
ResourceManager *_resMan; /**< The resource manager */
+ ScriptPatcher *_scriptPatcher; /**< The script patcher */
EngineState *_gamestate;
Kernel *_kernel;
Vocabulary *_vocabulary;
diff --git a/engines/sci/sound/audio.cpp b/engines/sci/sound/audio.cpp
index 8f405b0fa5..8e35d6b055 100644
--- a/engines/sci/sound/audio.cpp
+++ b/engines/sci/sound/audio.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -61,6 +61,62 @@ void AudioPlayer::stopAllAudio() {
audioCdStop();
}
+/**
+ * Handles the sciAudio calls in fanmade games.
+ * sciAudio is an external .NET library for playing MP3 files in fanmade games.
+ * It runs in the background, and obtains sound commands from the
+ * currently running game via text files (called "conductor files").
+ * For further info, check: http://sciprogramming.com/community/index.php?topic=634.0
+ */
+void AudioPlayer::handleFanmadeSciAudio(reg_t sciAudioObject, SegManager *segMan) {
+ // TODO: This is a bare bones implementation. Only the play/playx and stop commands
+ // are handled for now - the other commands haven't been observed in any fanmade game
+ // yet. All the volume related and fading functionality is currently missing.
+
+ Kernel *kernel = g_sci->getKernel();
+
+ reg_t commandReg = readSelector(segMan, sciAudioObject, kernel->findSelector("command"));
+ Common::String command = segMan->getString(commandReg);
+
+ if (command == "play" || command == "playx") {
+#ifdef USE_MAD
+ reg_t fileNameReg = readSelector(segMan, sciAudioObject, kernel->findSelector("fileName"));
+ Common::String fileName = segMan->getString(fileNameReg);
+
+ int16 loopCount = (int16)readSelectorValue(segMan, sciAudioObject, kernel->findSelector("loopCount"));
+ // When loopCount is -1, we treat it as infinite looping, else no looping is done.
+ // This is observed by game scripts, which can set loopCount to all sorts of random values.
+ // Adjust loopCount for ScummVM's LoopingAudioStream semantics
+ loopCount = (loopCount == -1) ? 0 : 1;
+
+ // Determine sound type
+ Audio::Mixer::SoundType soundType = Audio::Mixer::kSFXSoundType;
+ if (fileName.hasPrefix("music"))
+ soundType = Audio::Mixer::kMusicSoundType;
+ else if (fileName.hasPrefix("speech"))
+ soundType = Audio::Mixer::kSpeechSoundType;
+
+ Common::File *sciAudio = new Common::File();
+ // Replace backwards slashes
+ for (uint i = 0; i < fileName.size(); i++) {
+ if (fileName[i] == '\\')
+ fileName.setChar('/', i);
+ }
+ sciAudio->open("sciAudio/" + fileName);
+
+ Audio::SeekableAudioStream *audioStream = Audio::makeMP3Stream(sciAudio, DisposeAfterUse::YES);
+
+ // We only support one audio handle
+ _mixer->playStream(soundType, &_audioHandle,
+ Audio::makeLoopingAudioStream((Audio::RewindableAudioStream *)audioStream, loopCount));
+#endif
+ } else if (command == "stop") {
+ _mixer->stopHandle(_audioHandle);
+ } else {
+ warning("Unhandled sciAudio command: %s", command.c_str());
+ }
+}
+
int AudioPlayer::startAudio(uint16 module, uint32 number) {
int sampleLen;
Audio::AudioStream *audioStream = getAudioStream(number, module, &sampleLen);
diff --git a/engines/sci/sound/audio.h b/engines/sci/sound/audio.h
index e0ba234b12..9e65d6e0c8 100644
--- a/engines/sci/sound/audio.h
+++ b/engines/sci/sound/audio.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -75,6 +75,8 @@ public:
void pauseAudio();
void resumeAudio();
+ void handleFanmadeSciAudio(reg_t sciAudioObject, SegManager *segMan);
+
void setSoundSync(ResourceId id, reg_t syncObjAddr, SegManager *segMan);
void doSoundSync(reg_t syncObjAddr, SegManager *segMan);
void stopSoundSync();
diff --git a/engines/sci/sound/drivers/adlib.cpp b/engines/sci/sound/drivers/adlib.cpp
index 3229fd7071..fcfda2f532 100644
--- a/engines/sci/sound/drivers/adlib.cpp
+++ b/engines/sci/sound/drivers/adlib.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/amigamac.cpp b/engines/sci/sound/drivers/amigamac.cpp
index 131a85f371..5ce49086ca 100644
--- a/engines/sci/sound/drivers/amigamac.cpp
+++ b/engines/sci/sound/drivers/amigamac.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/cms.cpp b/engines/sci/sound/drivers/cms.cpp
index fd60863177..a222090fc8 100644
--- a/engines/sci/sound/drivers/cms.cpp
+++ b/engines/sci/sound/drivers/cms.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/fb01.cpp b/engines/sci/sound/drivers/fb01.cpp
index b16473e62e..db9f7558e2 100644
--- a/engines/sci/sound/drivers/fb01.cpp
+++ b/engines/sci/sound/drivers/fb01.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/fmtowns.cpp b/engines/sci/sound/drivers/fmtowns.cpp
index 21cb2f1e43..f6dbac2a67 100644
--- a/engines/sci/sound/drivers/fmtowns.cpp
+++ b/engines/sci/sound/drivers/fmtowns.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/gm_names.h b/engines/sci/sound/drivers/gm_names.h
index fbfa413a4a..791f79777c 100644
--- a/engines/sci/sound/drivers/gm_names.h
+++ b/engines/sci/sound/drivers/gm_names.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/map-mt32-to-gm.h b/engines/sci/sound/drivers/map-mt32-to-gm.h
index 12a36aa51c..5c90c47777 100644
--- a/engines/sci/sound/drivers/map-mt32-to-gm.h
+++ b/engines/sci/sound/drivers/map-mt32-to-gm.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/midi.cpp b/engines/sci/sound/drivers/midi.cpp
index a31d5f9a81..31c9d90de8 100644
--- a/engines/sci/sound/drivers/midi.cpp
+++ b/engines/sci/sound/drivers/midi.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/mididriver.h b/engines/sci/sound/drivers/mididriver.h
index 8938eef62f..fee0154096 100644
--- a/engines/sci/sound/drivers/mididriver.h
+++ b/engines/sci/sound/drivers/mididriver.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/drivers/pcjr.cpp b/engines/sci/sound/drivers/pcjr.cpp
index 1d823b643d..2399c506d4 100644
--- a/engines/sci/sound/drivers/pcjr.cpp
+++ b/engines/sci/sound/drivers/pcjr.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/sound/midiparser_sci.cpp b/engines/sci/sound/midiparser_sci.cpp
index 186fc18a5c..c0b4f3122e 100644
--- a/engines/sci/sound/midiparser_sci.cpp
+++ b/engines/sci/sound/midiparser_sci.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -58,6 +58,10 @@ MidiParser_SCI::MidiParser_SCI(SciVersion soundVersion, SciMusic *music) :
_resetOnPause = false;
_pSnd = 0;
+
+ _mainThreadCalled = false;
+
+ resetStateTracking();
}
MidiParser_SCI::~MidiParser_SCI() {
@@ -68,10 +72,12 @@ MidiParser_SCI::~MidiParser_SCI() {
}
void MidiParser_SCI::mainThreadBegin() {
+ assert(!_mainThreadCalled);
_mainThreadCalled = true;
}
void MidiParser_SCI::mainThreadEnd() {
+ assert(_mainThreadCalled);
_mainThreadCalled = false;
}
@@ -83,12 +89,21 @@ bool MidiParser_SCI::loadMusic(SoundResource::Track *track, MusicEntry *psnd, in
for (int i = 0; i < 16; i++) {
_channelUsed[i] = false;
- _channelRemap[i] = -1;
_channelMuted[i] = false;
_channelVolume[i] = 127;
+
+ if (_soundVersion <= SCI_VERSION_0_LATE)
+ _channelRemap[i] = i;
+ else
+ _channelRemap[i] = -1;
}
- _channelRemap[9] = 9; // never map channel 9, because that's used for percussion
- _channelRemap[15] = 15; // never map channel 15, because thats used by sierra internally
+
+ // FIXME: SSCI does not always start playing a track at the first byte.
+ // By default it skips 10 (or 13?) bytes containing prio/voices, patch,
+ // volume, pan commands in fixed locations, and possibly a signal
+ // in channel 15. We should initialize state tracking to those values
+ // so that they automatically get set up properly when the channels get
+ // mapped. See also the related FIXME in MidiParser_SCI::processEvent.
if (channelFilterMask) {
// SCI0 only has 1 data stream, but we need to filter out channels depending on music hardware selection
@@ -314,31 +329,26 @@ byte *MidiParser_SCI::midiFilterChannels(int channelMask) {
return _mixedData;
}
-// This will get called right before actual playing and will try to own the used channels
-void MidiParser_SCI::tryToOwnChannels() {
- // We don't have SciMusic in case debug command show_instruments is used
- if (!_music)
- return;
- for (int curChannel = 0; curChannel < 15; curChannel++) {
- if (_channelUsed[curChannel]) {
- if (_channelRemap[curChannel] == -1) {
- _channelRemap[curChannel] = _music->tryToOwnChannel(_pSnd, curChannel);
- }
- }
- }
-}
+void MidiParser_SCI::resetStateTracking() {
+ for (int i = 0; i < 16; ++i) {
+ ChannelState &s = _channelState[i];
+ s._modWheel = 0;
+ s._pan = 64;
+ s._patch = 0; // TODO: Initialize properly (from data in LoadMusic?)
+ s._note = -1;
+ s._sustain = false;
+ s._pitchWheel = 0x2000;
+ s._voices = 0;
-void MidiParser_SCI::lostChannels() {
- for (int curChannel = 0; curChannel < 15; curChannel++)
- if ((_channelUsed[curChannel]) && (curChannel != 9))
- _channelRemap[curChannel] = -1;
+ _channelVolume[i] = 127;
+ }
}
void MidiParser_SCI::sendInitCommands() {
- // reset our "global" volume and channel volumes
+ resetStateTracking();
+
+ // reset our "global" volume
_volume = 127;
- for (int i = 0; i < 16; i++)
- _channelVolume[i] = 127;
// Set initial voice count
if (_pSnd) {
@@ -390,53 +400,119 @@ void MidiParser_SCI::sendFromScriptToDriver(uint32 midi) {
// this happens for cmdSendMidi at least in sq1vga right at the start, it's a script issue
return;
}
- if (_channelRemap[midiChannel] == -1) {
- // trying to send to an unmapped channel
- // this happens for cmdSendMidi at least in sq1vga right at the start, scripts are pausing the sound
- // and then sending manually. it's a script issue
- return;
- }
sendToDriver(midi);
}
void MidiParser_SCI::sendToDriver(uint32 midi) {
- byte midiChannel = midi & 0xf;
-
- if ((midi & 0xFFF0) == 0x4EB0) {
- // this is channel mute only for sci1
- // it's velocity control for sci0
- if (_soundVersion >= SCI_VERSION_1_EARLY) {
- _channelMuted[midiChannel] = midi & 0xFF0000 ? true : false;
- return; // don't send this to driver at all
- }
- }
+ // State tracking
+ trackState(midi);
- // Is channel muted? if so, don't send command
- if (_channelMuted[midiChannel])
+ if ((midi & 0xFFF0) == 0x4EB0 && _soundVersion >= SCI_VERSION_1_EARLY) {
+ // Mute. Handled in trackState().
+ // CHECKME: Should we send this on to the driver?
return;
+ }
if ((midi & 0xFFF0) == 0x07B0) {
// someone trying to set channel volume?
int channelVolume = (midi >> 16) & 0xFF;
- // Remember, if we need to set it ourselves
- _channelVolume[midiChannel] = channelVolume;
// Adjust volume accordingly to current local volume
channelVolume = channelVolume * _volume / 127;
- midi = (midi & 0xFFF0) | ((channelVolume & 0xFF) << 16);
+ midi = (midi & 0xFFFF) | ((channelVolume & 0xFF) << 16);
}
+
// Channel remapping
+ byte midiChannel = midi & 0xf;
int16 realChannel = _channelRemap[midiChannel];
if (realChannel == -1)
return;
midi = (midi & 0xFFFFFFF0) | realChannel;
+ sendToDriver_raw(midi);
+}
+
+void MidiParser_SCI::sendToDriver_raw(uint32 midi) {
if (_mainThreadCalled)
_music->putMidiCommandInQueue(midi);
else
_driver->send(midi);
}
+void MidiParser_SCI::trackState(uint32 b) {
+ // We keep track of most of the state of a midi channel, so we can
+ // at any time reset the device to the current state, even if the
+ // channel has been temporarily disabled due to remapping.
+
+ byte command = b & 0xf0;
+ byte channel = b & 0xf;
+ byte op1 = (b >> 8) & 0x7f;
+ byte op2 = (b >> 16) & 0x7f;
+
+ ChannelState &s = _channelState[channel];
+
+ switch (command) {
+ case 0x90:
+ if (op2 != 0) {
+ // note on
+ s._note = op1;
+ break;
+ }
+ // else, fall-through
+ case 0x80:
+ // note off
+ if (s._note == op1)
+ s._note = -1;
+ break;
+ case 0xB0:
+ // control change
+ switch (op1) {
+ case 0x01: // mod wheel
+ s._modWheel = op2;
+ break;
+ case 0x07: // channel volume
+ _channelVolume[channel] = op2;
+ break;
+ case 0x0A: // pan
+ s._pan = op2;
+ break;
+ case 0x40: // sustain
+ s._sustain = (op2 != 0);
+ break;
+ case 0x4B: // voices
+ s._voices = op2;
+ _pSnd->_chan[channel]._voices = op2; // Also sync our MusicEntry
+ break;
+ case 0x4E: // mute
+ // This is channel mute only for sci1.
+ // (It's velocity control for sci0, but we don't need state in sci0)
+ if (_soundVersion >= SCI_VERSION_1_EARLY) {
+ // FIXME: mute is a level, not a bool, in some SCI versions
+ bool m = op2;
+ if (_pSnd->_chan[channel]._mute != m) {
+ _pSnd->_chan[channel]._mute = m;
+ // TODO: If muting/unmuting a channel, remap channels.
+ warning("Mute change without immediate remapping (mainThread = %d)", _mainThreadCalled);
+ }
+ }
+ break;
+ default:
+ break;
+ }
+ break;
+ case 0xC0:
+ // program change
+ s._patch = op1;
+ break;
+ case 0xE0:
+ // pitchwheel
+ s._pitchWheel = (op2 << 7) | op1;
+ break;
+ default:
+ break;
+ }
+}
+
void MidiParser_SCI::parseNextEvent(EventInfo &info) {
info.start = _position._playPos;
info.delta = 0;
@@ -477,8 +553,10 @@ void MidiParser_SCI::parseNextEvent(EventInfo &info) {
case 0xE:
info.basic.param1 = *(_position._playPos++);
info.basic.param2 = *(_position._playPos++);
- if (info.command() == 0x9 && info.basic.param2 == 0)
+ if (info.command() == 0x9 && info.basic.param2 == 0) {
+ // NoteOn with param2==0 is a NoteOff
info.event = info.channel() | 0x80;
+ }
info.length = 0;
break;
@@ -523,11 +601,10 @@ void MidiParser_SCI::parseNextEvent(EventInfo &info) {
}// switch (info.command())
}
-void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
+bool MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
if (!fireEvents) {
// We don't do any processing that should be done while skipping events
- MidiParser::processEvent(info, fireEvents);
- return;
+ return MidiParser::processEvent(info, fireEvents);
}
switch (info.command()) {
@@ -579,7 +656,7 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
}
// Done with this event.
- return;
+ return true;
}
// Break to let parent handle the rest.
@@ -606,7 +683,7 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
switch (info.basic.param1) {
case kSetReverb:
// Already handled above
- return;
+ return true;
case kMidiHold:
// Check if the hold ID marker is the same as the hold ID
// marker set for that song by cmdSetSoundHold.
@@ -614,9 +691,9 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
if (info.basic.param2 == _pSnd->hold) {
jumpToTick(_loopTick, false, false);
// Done with this event.
- return;
+ return true;
}
- return;
+ return true;
case kUpdateCue:
if (!_jumpingToTick) {
int inc;
@@ -637,17 +714,17 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
debugC(4, kDebugLevelSound, "datainc %04x", inc);
}
- return;
+ return true;
case kResetOnPause:
_resetOnPause = info.basic.param2;
- return;
+ return true;
// Unhandled SCI commands
case 0x46: // LSL3 - binoculars
case 0x61: // Iceman (AdLib?)
case 0x73: // Hoyle
case 0xD1: // KQ4, when riding the unicorn
// Obscure SCI commands - ignored
- return;
+ return true;
// Standard MIDI commands
case 0x01: // mod wheel
case 0x04: // foot controller
@@ -662,10 +739,10 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
case 0x4B: // voice mapping
// TODO: is any support for this needed at the MIDI parser level?
warning("Unhanded SCI MIDI command 0x%x - voice mapping (parameter %d)", info.basic.param1, info.basic.param2);
- return;
+ return true;
default:
warning("Unhandled SCI MIDI command 0x%x (parameter %d)", info.basic.param1, info.basic.param2);
- return;
+ return true;
}
}
@@ -684,7 +761,7 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
jumpToTick(_loopTick);
// Done with this event.
- return;
+ return true;
} else {
_pSnd->status = kSoundStopped;
@@ -704,7 +781,7 @@ void MidiParser_SCI::processEvent(const EventInfo &info, bool fireEvents) {
// Let parent handle the rest
- MidiParser::processEvent(info, fireEvents);
+ return MidiParser::processEvent(info, fireEvents);
}
byte MidiParser_SCI::getSongReverb() {
@@ -809,4 +886,44 @@ void MidiParser_SCI::setVolume(byte volume) {
}
}
+void MidiParser_SCI::remapChannel(int channel, int devChannel) {
+ if (_channelRemap[channel] == devChannel)
+ return;
+
+ _channelRemap[channel] = devChannel;
+
+ if (devChannel == -1)
+ return;
+
+// debug(" restoring state: channel %d on devChannel %d", channel, devChannel);
+
+ // restore state
+ ChannelState &s = _channelState[channel];
+
+ int channelVolume = _channelVolume[channel];
+ channelVolume = (channelVolume * _volume / 127) & 0xFF;
+ byte pitch1 = s._pitchWheel & 0x7F;
+ byte pitch2 = (s._pitchWheel >> 7) & 0x7F;
+
+ sendToDriver_raw(0x0040B0 | devChannel); // sustain off
+ sendToDriver_raw(0x004BB0 | devChannel | (s._voices << 16));
+ sendToDriver_raw(0x0000C0 | devChannel | (s._patch << 8));
+ sendToDriver_raw(0x0007B0 | devChannel | (channelVolume << 16));
+ sendToDriver_raw(0x000AB0 | devChannel | (s._pan << 16));
+ sendToDriver_raw(0x0001B0 | devChannel | (s._modWheel << 16));
+ sendToDriver_raw(0x0040B0 | devChannel | (s._sustain ? 0x7F0000 : 0));
+ sendToDriver_raw(0x0000E0 | devChannel | (pitch1 << 8) | (pitch2 << 16));
+
+ // CHECKME: Some SSCI version send a control change 0x4E with s._note as
+ // parameter.
+ // We need to investigate how (and if) drivers should act on this.
+ // Related: controller 0x4E is used for 'mute' in the midiparser.
+ // This could be a bug in SSCI that went unnoticed because few (or no?)
+ // drivers implement controller 0x4E
+
+ // NB: The line below is _not_ valid since s._note can be 0xFF.
+ // SSCI handles this out of band in the driver interface.
+ // sendToDriver_raw(0x004EB0 | devChannel | (s._note << 16);
+}
+
} // End of namespace Sci
diff --git a/engines/sci/sound/midiparser_sci.h b/engines/sci/sound/midiparser_sci.h
index 5784dca1ab..15c01977bd 100644
--- a/engines/sci/sound/midiparser_sci.h
+++ b/engines/sci/sound/midiparser_sci.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -79,20 +79,23 @@ public:
const byte *getMixedData() const { return _mixedData; }
byte getSongReverb();
- void tryToOwnChannels();
- void lostChannels();
void sendFromScriptToDriver(uint32 midi);
void sendToDriver(uint32 midi);
void sendToDriver(byte status, byte firstOp, byte secondOp) {
sendToDriver(status | ((uint32)firstOp << 8) | ((uint32)secondOp << 16));
}
+ void remapChannel(int channel, int devChannel);
+
protected:
void parseNextEvent(EventInfo &info);
- void processEvent(const EventInfo &info, bool fireEvents = true);
+ bool processEvent(const EventInfo &info, bool fireEvents = true);
byte *midiMixChannels();
byte *midiFilterChannels(int channelMask);
byte midiGetNextChannel(long ticker);
+ void resetStateTracking();
+ void trackState(uint32 midi);
+ void sendToDriver_raw(uint32 midi);
SciMusic *_music;
@@ -113,6 +116,19 @@ protected:
int16 _channelRemap[16];
bool _channelMuted[16];
byte _channelVolume[16];
+
+ struct ChannelState {
+ int8 _modWheel;
+ int8 _pan;
+ int8 _patch;
+ int8 _note;
+ bool _sustain;
+ int16 _pitchWheel;
+ int8 _voices;
+ };
+
+ ChannelState _channelState[16];
+
};
} // End of namespace Sci
diff --git a/engines/sci/sound/music.cpp b/engines/sci/sound/music.cpp
index 8c6d0d6431..362cca699d 100644
--- a/engines/sci/sound/music.cpp
+++ b/engines/sci/sound/music.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -33,7 +33,7 @@
#include "sci/sound/midiparser_sci.h"
#include "sci/sound/music.h"
-//#define DISABLE_REMAPPING
+//#define DEBUG_REMAP
namespace Sci {
@@ -47,6 +47,8 @@ SciMusic::SciMusic(SciVersion soundVersion, bool useDigitalSFX)
for (int i = 0; i < 16; i++) {
_usedChannel[i] = 0;
_channelRemap[i] = -1;
+ _channelMap[i]._song = 0;
+ _channelMap[i]._channel = -1;
}
_queuedCommands.reserve(1000);
@@ -140,6 +142,8 @@ void SciMusic::init() {
_driverLastChannel = _pMidiDrv->getLastChannel();
if (getSciVersion() <= SCI_VERSION_0_LATE)
_globalReverb = _pMidiDrv->getReverb(); // Init global reverb for SCI0
+
+ _currentlyPlayingSample = NULL;
}
void SciMusic::miditimerCallback(void *p) {
@@ -291,6 +295,15 @@ void SciMusic::sortPlayList() {
}
void SciMusic::soundInitSnd(MusicEntry *pSnd) {
+ // Remove all currently mapped channels of this MusicEntry first,
+ // since they will no longer be valid.
+ for (int i = 0; i < 16; ++i) {
+ if (_channelMap[i]._song == pSnd) {
+ _channelMap[i]._song = 0;
+ _channelMap[i]._channel = -1;
+ }
+ }
+
int channelFilterMask = 0;
SoundResource::Track *track = pSnd->soundRes->getTrackByType(_pMidiDrv->getPlayId());
@@ -337,6 +350,27 @@ void SciMusic::soundInitSnd(MusicEntry *pSnd) {
// Find out what channels to filter for SCI0
channelFilterMask = pSnd->soundRes->getChannelFilterMask(_pMidiDrv->getPlayId(), _pMidiDrv->hasRhythmChannel());
+ for (int i = 0; i < 16; ++i)
+ pSnd->_usedChannels[i] = 0xFF;
+ for (int i = 0; i < track->channelCount; ++i) {
+ SoundResource::Channel &chan = track->channels[i];
+
+ pSnd->_usedChannels[i] = chan.number;
+ pSnd->_chan[chan.number]._dontRemap = (chan.flags & 2);
+ pSnd->_chan[chan.number]._prio = chan.prio;
+ pSnd->_chan[chan.number]._voices = chan.poly;
+
+ // CHECKME: Some SCI versions use chan.flags & 1 for this:
+ pSnd->_chan[chan.number]._dontMap = false;
+
+ // FIXME: Most MIDI tracks use the first 10 bytes for
+ // fixed MIDI commands. SSCI skips those the first iteration,
+ // but _does_ update channel state (including volume) with
+ // them. Specifically, prio/voices, patch, volume, pan.
+ // This should probably be implemented in
+ // MidiParser_SCI::loadMusic.
+ }
+
pSnd->pMidiParser->mainThreadBegin();
// loadMusic() below calls jumpToTick.
// Disable sound looping and hold before jumpToTick is called,
@@ -358,64 +392,6 @@ void SciMusic::soundInitSnd(MusicEntry *pSnd) {
}
}
-// This one checks, if requested channel is available -> in that case give
-// caller that channel. Otherwise look for an unused one
-int16 SciMusic::tryToOwnChannel(MusicEntry *caller, int16 bestChannel) {
-#ifdef DISABLE_REMAPPING
- return bestChannel;
-#endif
-
- // Don't even try this for SCI0
- if (_soundVersion <= SCI_VERSION_0_LATE)
- return bestChannel;
- if (!_usedChannel[bestChannel]) {
- // currently unused, so give it to caller directly
- _usedChannel[bestChannel] = caller;
- _channelRemap[bestChannel] = bestChannel;
- return bestChannel;
- }
- // otherwise look for unused channel
- for (int channelNr = _driverFirstChannel; channelNr < 15; channelNr++) {
- if (channelNr == 9) // never map to channel 9 (percussion)
- continue;
- if (!_usedChannel[channelNr]) {
- _usedChannel[channelNr] = caller;
- _channelRemap[bestChannel] = channelNr;
- return channelNr;
- }
- }
- // nothing found, don't map channel at all
- // sierra did this as well, although i'm not sure if we act exactly the same way
- // maybe they removed channels from previous playing music
- return -1;
-}
-
-void SciMusic::freeChannels(MusicEntry *caller) {
- // Remove used channels
- for (int i = 0; i < 15; i++) {
- if (_usedChannel[i] == caller) {
- if (_channelRemap[i] != -1) {
- // athrxx: The original handles this differently. It seems to be checking for (and effecting) necessary
- // remaps / resets etc. more or less all the time. There are several more tables to keep track of everything.
- // I don't know whether all of that is needed and to which SCI versions it applies, though.
- // At least it is necessary to release the allocated channels inside the driver. Otherwise these channels
- // won't be available any more (e.g. after half of the KQ5 FM-Towns intro there will be no more music
- // since the driver can't pick up any more channels). The channels also have to be reset to
- // default values, since the original does the same (although in a different manny) and the music will be wrong
- // otherwise (at least KQ5 FM-Towns).
-
- sendMidiCommand(0x4000e0 | _channelRemap[i]); // Reset pitch wheel
- sendMidiCommand(0x0040b0 | _channelRemap[i]); // Release pedal
- sendMidiCommand(0x004bb0 | _channelRemap[i]); // Release assigned driver channels
- }
- _usedChannel[i] = 0;
- _channelRemap[i] = -1;
- }
- }
- // Also tell midiparser, that he lost ownership
- caller->pMidiParser->lostChannels();
-}
-
void SciMusic::soundPlay(MusicEntry *pSnd) {
_mutex.lock();
@@ -458,6 +434,17 @@ void SciMusic::soundPlay(MusicEntry *pSnd) {
if (pSnd->pStreamAud) {
if (!_pMixer->isSoundHandleActive(pSnd->hCurrentAud)) {
+ if ((_currentlyPlayingSample) && (_pMixer->isSoundHandleActive(_currentlyPlayingSample->hCurrentAud))) {
+ // Another sample is already playing, we have to stop that one
+ // SSCI is only able to play 1 sample at a time
+ // In Space Quest 5 room 250 the player is able to open the air-hatch and kill himself.
+ // In that situation the scripts are playing 2 samples at the same time and the first sample
+ // is not supposed to play.
+ // TODO: SSCI actually calls kDoAudio(play) internally, which stops other samples from being played
+ // but such a change isn't trivial, because we also handle Sound resources in here, that contain samples
+ _pMixer->stopHandle(_currentlyPlayingSample->hCurrentAud);
+ warning("kDoSound: sample already playing, old resource %d, new resource %d", _currentlyPlayingSample->resourceId, pSnd->resourceId);
+ }
// Sierra SCI ignores volume set when playing samples via kDoSound
// At least freddy pharkas/CD has a script bug that sets volume to 0
// when playing the "score" sample
@@ -475,34 +462,14 @@ void SciMusic::soundPlay(MusicEntry *pSnd) {
pSnd->pStreamAud, -1, _pMixer->kMaxChannelVolume, 0,
DisposeAfterUse::NO);
}
+ // Remember the sample, that is now playing
+ _currentlyPlayingSample = pSnd;
}
} else {
if (pSnd->pMidiParser) {
Common::StackLock lock(_mutex);
pSnd->pMidiParser->mainThreadBegin();
- if (pSnd->status != kSoundPaused) {
- // Stop any in progress music fading, as that will reset the
- // volume of the sound channels that the faded song occupies..
- // Fixes bug #3266480 and partially fixes bug #3041738.
- // CHECKME: Is this the right thing to do? Are these
- // overlapping channels not a deeper underlying problem?
- for (uint i = 0; i < playListCount; i++) {
- // Is another MIDI song being faded down? If yes, stop it
- // immediately instead
- if (_playList[i]->fadeStep < 0 && _playList[i]->pMidiParser) {
- _playList[i]->status = kSoundStopped;
- if (_soundVersion <= SCI_VERSION_0_LATE)
- _playList[i]->isQueued = false;
- _playList[i]->pMidiParser->stop();
- freeChannels(_playList[i]);
- _playList[i]->fadeStep = 0;
- _playList[i]->fadeCompleted = true;
- }
- }
- }
-
- pSnd->pMidiParser->tryToOwnChannels();
if (pSnd->status != kSoundPaused)
pSnd->pMidiParser->sendInitCommands();
pSnd->pMidiParser->setVolume(pSnd->volume);
@@ -532,6 +499,10 @@ void SciMusic::soundPlay(MusicEntry *pSnd) {
}
pSnd->status = kSoundPlaying;
+
+ _mutex.lock();
+ remapChannels();
+ _mutex.unlock();
}
void SciMusic::soundStop(MusicEntry *pSnd) {
@@ -539,8 +510,11 @@ void SciMusic::soundStop(MusicEntry *pSnd) {
pSnd->status = kSoundStopped;
if (_soundVersion <= SCI_VERSION_0_LATE)
pSnd->isQueued = false;
- if (pSnd->pStreamAud)
+ if (pSnd->pStreamAud) {
+ if (_currentlyPlayingSample == pSnd)
+ _currentlyPlayingSample = NULL;
_pMixer->stopHandle(pSnd->hCurrentAud);
+ }
if (pSnd->pMidiParser) {
Common::StackLock lock(_mutex);
@@ -549,8 +523,8 @@ void SciMusic::soundStop(MusicEntry *pSnd) {
// allNotesOff() again
if (previousStatus == kSoundPlaying)
pSnd->pMidiParser->stop();
- freeChannels(pSnd);
pSnd->pMidiParser->mainThreadEnd();
+ remapChannels();
}
pSnd->fadeStep = 0; // end fading, if fading was in progress
@@ -586,8 +560,10 @@ void SciMusic::soundSetPriority(MusicEntry *pSnd, byte prio) {
void SciMusic::soundKill(MusicEntry *pSnd) {
pSnd->status = kSoundStopped;
+ _mutex.lock();
+ remapChannels();
+
if (pSnd->pMidiParser) {
- Common::StackLock lock(_mutex);
pSnd->pMidiParser->mainThreadBegin();
pSnd->pMidiParser->unloadMusic();
pSnd->pMidiParser->mainThreadEnd();
@@ -595,7 +571,13 @@ void SciMusic::soundKill(MusicEntry *pSnd) {
pSnd->pMidiParser = NULL;
}
+ _mutex.unlock();
+
if (pSnd->pStreamAud) {
+ if (_currentlyPlayingSample == pSnd) {
+ // Forget about this sound, in case it was currently playing
+ _currentlyPlayingSample = NULL;
+ }
_pMixer->stopHandle(pSnd->hCurrentAud);
delete pSnd->pStreamAud;
pSnd->pStreamAud = NULL;
@@ -603,7 +585,7 @@ void SciMusic::soundKill(MusicEntry *pSnd) {
pSnd->pLoopStream = 0;
}
- Common::StackLock lock(_mutex);
+ _mutex.lock();
uint sz = _playList.size(), i;
// Remove sound from playlist
for (i = 0; i < sz; i++) {
@@ -614,6 +596,7 @@ void SciMusic::soundKill(MusicEntry *pSnd) {
break;
}
}
+ _mutex.unlock();
}
void SciMusic::soundPause(MusicEntry *pSnd) {
@@ -639,8 +622,8 @@ void SciMusic::soundPause(MusicEntry *pSnd) {
Common::StackLock lock(_mutex);
pSnd->pMidiParser->mainThreadBegin();
pSnd->pMidiParser->pause();
- freeChannels(pSnd);
pSnd->pMidiParser->mainThreadEnd();
+ remapChannels();
}
}
}
@@ -705,7 +688,7 @@ void SciMusic::printPlayList(Console *con) {
for (uint32 i = 0; i < _playList.size(); i++) {
MusicEntry *song = _playList[i];
- con->DebugPrintf("%d: %04x:%04x (%s), resource id: %d, status: %s, %s type\n",
+ con->debugPrintf("%d: %04x:%04x (%s), resource id: %d, status: %s, %s type\n",
i, PRINT_REG(song->soundObj),
g_sci->getEngineState()->_segMan->getObjectName(song->soundObj),
song->resourceId, musicStatus[song->status],
@@ -722,26 +705,26 @@ void SciMusic::printSongInfo(reg_t obj, Console *con) {
for (MusicList::iterator i = _playList.begin(); i != end; ++i) {
MusicEntry *song = *i;
if (song->soundObj == obj) {
- con->DebugPrintf("Resource id: %d, status: %s\n", song->resourceId, musicStatus[song->status]);
- con->DebugPrintf("dataInc: %d, hold: %d, loop: %d\n", song->dataInc, song->hold, song->loop);
- con->DebugPrintf("signal: %d, priority: %d\n", song->signal, song->priority);
- con->DebugPrintf("ticker: %d, volume: %d\n", song->ticker, song->volume);
+ con->debugPrintf("Resource id: %d, status: %s\n", song->resourceId, musicStatus[song->status]);
+ con->debugPrintf("dataInc: %d, hold: %d, loop: %d\n", song->dataInc, song->hold, song->loop);
+ con->debugPrintf("signal: %d, priority: %d\n", song->signal, song->priority);
+ con->debugPrintf("ticker: %d, volume: %d\n", song->ticker, song->volume);
if (song->pMidiParser) {
- con->DebugPrintf("Type: MIDI\n");
+ con->debugPrintf("Type: MIDI\n");
if (song->soundRes) {
SoundResource::Track *track = song->soundRes->getTrackByType(_pMidiDrv->getPlayId());
- con->DebugPrintf("Channels: %d\n", track->channelCount);
+ con->debugPrintf("Channels: %d\n", track->channelCount);
}
} else if (song->pStreamAud || song->pLoopStream) {
- con->DebugPrintf("Type: digital audio (%s), sound active: %s\n",
+ con->debugPrintf("Type: digital audio (%s), sound active: %s\n",
song->pStreamAud ? "non looping" : "looping",
_pMixer->isSoundHandleActive(song->hCurrentAud) ? "yes" : "no");
if (song->soundRes) {
- con->DebugPrintf("Sound resource information:\n");
+ con->debugPrintf("Sound resource information:\n");
SoundResource::Track *track = song->soundRes->getTrackByType(_pMidiDrv->getPlayId());
if (track && track->digitalChannelNr != -1) {
- con->DebugPrintf("Sample size: %d, sample rate: %d, channels: %d, digital channel number: %d\n",
+ con->debugPrintf("Sample size: %d, sample rate: %d, channels: %d, digital channel number: %d\n",
track->digitalSampleSize, track->digitalSampleRate, track->channelCount, track->digitalChannelNr);
}
}
@@ -751,7 +734,7 @@ void SciMusic::printSongInfo(reg_t obj, Console *con) {
}
}
- con->DebugPrintf("Song object not found in playlist");
+ con->debugPrintf("Song object not found in playlist");
}
MusicEntry::MusicEntry() {
@@ -789,6 +772,14 @@ MusicEntry::MusicEntry() {
pStreamAud = 0;
pLoopStream = 0;
pMidiParser = 0;
+
+ for (int i = 0; i < 16; ++i) {
+ _usedChannels[i] = 0xFF;
+ _chan[i]._prio = 127;
+ _chan[i]._voices = 0;
+ _chan[i]._dontRemap = false;
+ _chan[i]._mute = false;
+ }
}
MusicEntry::~MusicEntry() {
@@ -857,4 +848,453 @@ void MusicEntry::setSignal(int newSignal) {
}
}
+
+void ChannelRemapping::swap(int i, int j) {
+ DeviceChannelUsage t1;
+ int t2;
+ bool t3;
+
+ t1 = _map[i]; _map[i] = _map[j]; _map[j] = t1;
+ t2 = _prio[i]; _prio[i] = _prio[j]; _prio[j] = t2;
+ t2 = _voices[i]; _voices[i] = _voices[j]; _voices[j] = t2;
+ t3 = _dontRemap[i]; _dontRemap[i] = _dontRemap[j]; _dontRemap[j] = t3;
+}
+
+void ChannelRemapping::evict(int i) {
+ _freeVoices += _voices[i];
+
+ _map[i]._song = 0;
+ _map[i]._channel = -1;
+ _prio[i] = 0;
+ _voices[i] = 0;
+ _dontRemap[i] = false;
+}
+
+void ChannelRemapping::clear() {
+ for (int i = 0; i < 16; ++i) {
+ _map[i]._song = 0;
+ _map[i]._channel = -1;
+ _prio[i] = 0;
+ _voices[i] = 0;
+ _dontRemap[i] = false;
+ }
+}
+
+ChannelRemapping& ChannelRemapping::operator=(ChannelRemapping& other) {
+ for (int i = 0; i < 16; ++i) {
+ _map[i] = other._map[i];
+ _prio[i] = other._prio[i];
+ _voices[i] = other._voices[i];
+ _dontRemap[i] = other._dontRemap[i];
+ }
+ _freeVoices = other._freeVoices;
+
+ return *this;
+}
+
+int ChannelRemapping::lowestPrio() const {
+ int max = 0;
+ int channel = -1;
+ for (int i = 0; i < 16; ++i) {
+ if (_prio[i] > max) {
+ max = _prio[i];
+ channel = i;
+ }
+ }
+ return channel;
+}
+
+
+void SciMusic::remapChannels() {
+ if (_soundVersion <= SCI_VERSION_0_LATE)
+ return;
+
+ // NB: This function should only be called from the main thread,
+ // with _mutex locked
+
+
+ ChannelRemapping *map = determineChannelMap();
+
+ DeviceChannelUsage currentMap[16];
+
+#ifdef DEBUG_REMAP
+ debug("Remap results:");
+#endif
+
+ // Save current map, and then start from an empty map
+ for (int i = 0; i < 16; ++i) {
+ currentMap[i] = _channelMap[i];
+ _channelMap[i]._song = 0;
+ _channelMap[i]._channel = -1;
+ }
+
+ // Inform MidiParsers of any unmapped channels
+ const MusicList::iterator end = _playList.end();
+ int songIndex = -1;
+ for (MusicList::iterator i = _playList.begin(); i != end; ++i) {
+ MusicEntry *song = *i;
+ songIndex++;
+
+ if (!song || !song->pMidiParser)
+ continue;
+
+ bool channelMapped[16];
+#ifdef DEBUG_REMAP
+ bool channelUsed[16];
+#endif
+ for (int j = 0; j < 16; ++j) {
+ channelMapped[j] = false;
+#ifdef DEBUG_REMAP
+ channelUsed[j] = false;
+#endif
+ }
+
+ for (int j = 0; j < 16; ++j) {
+ if (map->_map[j]._song == song) {
+ int channel = map->_map[j]._channel;
+ assert(channel >= 0 && channel <= 0x0F);
+ channelMapped[channel] = true;
+ }
+#ifdef DEBUG_REMAP
+ if (song->_usedChannels[j] <= 0x0F)
+ channelUsed[song->_usedChannels[j]] = true;
+#endif
+ }
+
+ for (int j = 0; j < 16; ++j) {
+ if (!channelMapped[j]) {
+ song->pMidiParser->mainThreadBegin();
+ song->pMidiParser->remapChannel(j, -1);
+ song->pMidiParser->mainThreadEnd();
+#ifdef DEBUG_REMAP
+ if (channelUsed[j])
+ debug(" Unmapping song %d, channel %d", songIndex, j);
+#endif
+ }
+ }
+ }
+
+ // Now reshuffle the channels on the device.
+
+ // First, set up any dontRemap channels
+ for (int i = 0; i < 16; ++i) {
+
+ if (!map->_map[i]._song || !map->_map[i]._song->pMidiParser || !map->_dontRemap[i])
+ continue;
+
+ songIndex = -1;
+ for (MusicList::iterator iter = _playList.begin(); iter != end; ++iter) {
+ songIndex++;
+ if (map->_map[i]._song == *iter)
+ break;
+ }
+
+ _channelMap[i] = map->_map[i];
+ map->_map[i]._song = 0; // mark as done
+
+ // If this channel was not yet mapped to the device, reset it
+ if (currentMap[i] != _channelMap[i]) {
+#ifdef DEBUG_REMAP
+ debug(" Mapping (dontRemap) song %d, channel %d to device channel %d", songIndex, _channelMap[i]._channel, i);
+#endif
+ _channelMap[i]._song->pMidiParser->mainThreadBegin();
+ _channelMap[i]._song->pMidiParser->remapChannel(_channelMap[i]._channel, i);
+ _channelMap[i]._song->pMidiParser->mainThreadEnd();
+ }
+
+ }
+
+ // Next, we look for channels which were already playing.
+ // We keep those on the same device channel as before.
+ for (int i = 0; i < 16; ++i) {
+
+ if (!map->_map[i]._song)
+ continue;
+
+ songIndex = -1;
+ for (MusicList::iterator iter = _playList.begin(); iter != end; ++iter) {
+ songIndex++;
+ if (map->_map[i]._song == *iter)
+ break;
+ }
+
+
+ for (int j = 0; j < 16; ++j) {
+ if (map->_map[i] == currentMap[j]) {
+ // found it
+ _channelMap[j] = map->_map[i];
+ map->_map[i]._song = 0; // mark as done
+#ifdef DEBUG_REMAP
+ debug(" Keeping song %d, channel %d on device channel %d", songIndex, _channelMap[j]._channel, j);
+#endif
+ break;
+ }
+ }
+ }
+
+ // Then, remap the rest.
+ for (int i = 0; i < 16; ++i) {
+
+ if (!map->_map[i]._song || !map->_map[i]._song->pMidiParser)
+ continue;
+
+ songIndex = -1;
+ for (MusicList::iterator iter = _playList.begin(); iter != end; ++iter) {
+ songIndex++;
+ if (map->_map[i]._song == *iter)
+ break;
+ }
+
+ for (int j = _driverLastChannel; j >= _driverFirstChannel; --j) {
+ if (_channelMap[j]._song == 0) {
+ _channelMap[j] = map->_map[i];
+ map->_map[i]._song = 0;
+#ifdef DEBUG_REMAP
+ debug(" Mapping song %d, channel %d to device channel %d", songIndex, _channelMap[j]._channel, j);
+#endif
+ _channelMap[j]._song->pMidiParser->mainThreadBegin();
+ _channelMap[j]._song->pMidiParser->remapChannel(_channelMap[j]._channel, j);
+ _channelMap[j]._song->pMidiParser->mainThreadEnd();
+ break;
+ }
+ }
+
+ }
+
+ // And finally, stop any empty channels
+ for (int i = _driverFirstChannel; i <= _driverLastChannel; ++i) {
+ if (!_channelMap[i]._song)
+ resetDeviceChannel(i);
+ }
+
+ delete map;
+}
+
+
+ChannelRemapping *SciMusic::determineChannelMap() {
+#ifdef DEBUG_REMAP
+ debug("Remap: avail chans: %d-%d", _driverFirstChannel, _driverLastChannel);
+#endif
+
+ ChannelRemapping *map = new ChannelRemapping;
+ ChannelRemapping backupMap;
+ map->clear();
+ map->_freeVoices = _pMidiDrv->getPolyphony();
+
+ if (_playList.empty())
+ return map;
+
+ // TODO: set reverb, either from first song, or from global???
+
+ MusicList::iterator songIter;
+ int songIndex = -1;
+ for (songIter = _playList.begin(); songIter != _playList.end(); ++songIter) {
+ songIndex++;
+ MusicEntry *song = *songIter;
+ if (song->status != kSoundPlaying)
+ continue;
+
+ // If song is digital, skip.
+ // CHECKME: Is this condition correct?
+ if (!song->pMidiParser) {
+#ifdef DEBUG_REMAP
+ debug(" Song %d (%p), digital?", songIndex, (void*)song);
+#endif
+ continue;
+ }
+
+
+#ifdef DEBUG_REMAP
+ debug(" Song %d (%p), prio %d", songIndex, (void*)song, song->priority);
+#endif
+
+ // Store backup. If we fail to map this song, we will revert to this.
+ backupMap = *map;
+
+ bool songMapped = true;
+
+ for (int i = 0; i < 16; ++i) {
+ int c = song->_usedChannels[i];
+ if (c == 0xFF || c == 0xFE || c == 0x0F)
+ continue;
+ const MusicEntryChannel &channel = song->_chan[c];
+ if (channel._dontMap)
+ continue;
+ if (channel._mute)
+ continue;
+
+#ifdef DEBUG_REMAP
+ debug(" Channel %d: prio %d, %d voice%s%s", c, channel._prio, channel._voices, channel._voices == 1 ? "" : "s", channel._dontRemap ? ", dontRemap" : "" );
+#endif
+
+ DeviceChannelUsage dc = { song, c };
+
+ // our target
+ int devChannel = -1;
+
+ if (channel._dontRemap && map->_map[c]._song == 0) {
+ // unremappable channel, with channel still free
+ devChannel = c;
+ }
+
+ // try to find a free channel
+ if (devChannel == -1) {
+ for (int j = 0; j < 16; ++j) {
+ if (map->_map[j] == dc) {
+ // already mapped?! (Can this happen?)
+ devChannel = j;
+ break;
+ }
+ if (map->_map[j]._song)
+ continue;
+
+ if (j >= _driverFirstChannel && j <= _driverLastChannel)
+ devChannel = j;
+ }
+ }
+
+ int prio = channel._prio;
+ if (prio > 0) {
+ // prio > 0 means non-essential
+ prio = (16 - prio) + 16*songIndex;
+ }
+
+ if (devChannel == -1 && prio > 0) {
+ // no empty channel, but this isn't an essential channel,
+ // so we just skip it.
+#ifdef DEBUG_REMAP
+ debug(" skipping non-essential");
+#endif
+ continue;
+ }
+
+ // try to empty a previous channel if this is an essential channel
+ if (devChannel == -1) {
+ devChannel = map->lowestPrio();
+ if (devChannel != -1)
+ map->evict(devChannel);
+ }
+
+ if (devChannel == -1) {
+ // failed to map this song.
+#ifdef DEBUG_REMAP
+ debug(" no free (or lower priority) channel found");
+#endif
+ songMapped = false;
+ break;
+ }
+
+ if (map->_map[devChannel] == dc) {
+ // already mapped?! (Can this happen?)
+ continue;
+ }
+
+ int neededVoices = channel._voices;
+ // do we have enough free voices?
+ if (map->_freeVoices < neededVoices) {
+ // We only care for essential channels
+ if (prio > 0) {
+#ifdef DEBUG_REMAP
+ debug(" not enough voices; need %d, have %d. Skipping this channel.", neededVoices, map->_freeVoices);
+#endif
+ continue;
+ }
+ do {
+ int j = map->lowestPrio();
+ if (j == -1) {
+#ifdef DEBUG_REMAP
+ debug(" not enough voices; need %d, have %d", neededVoices, map->_freeVoices);
+#endif
+ // failed to free enough voices.
+ songMapped = false;
+ break;
+ }
+#ifdef DEBUG_REMAP
+ debug(" creating room for voices; evict %d", j);
+#endif
+ map->evict(j);
+ } while (map->_freeVoices < neededVoices);
+
+ if (!songMapped) {
+ // failed to map this song.
+ break;
+ }
+ }
+
+ // We have a channel and enough free voices now.
+#ifdef DEBUG_REMAP
+ debug(" trying to map to %d", devChannel);
+#endif
+
+ map->_map[devChannel] = dc;
+ map->_voices[devChannel] = neededVoices;
+ map->_prio[devChannel] = prio;
+ map->_dontRemap[devChannel] = channel._dontRemap;
+ map->_freeVoices -= neededVoices;
+
+ if (!channel._dontRemap || devChannel == c) {
+ // If this channel fits here, we're done.
+#ifdef DEBUG_REMAP
+ debug(" OK");
+#endif
+ continue;
+ }
+
+ // If this channel can't be remapped, we need to move it or fail.
+
+ if (!map->_dontRemap[c]) {
+ // Target channel can be remapped, so just swap
+ map->swap(devChannel, c);
+ continue;
+ }
+#ifdef DEBUG_REMAP
+ debug(" but %d is already dontRemap", c);
+#endif
+
+ if (prio > 0) {
+ // Channel collision, but this channel is non-essential,
+ // so drop it.
+ // TODO: Maybe we should have checked this before making room?
+ map->evict(devChannel);
+ continue;
+ }
+
+ if (map->_prio[c] > 0) {
+ // Channel collision, but the other channel is non-essential,
+ // so we take its place.
+ map->evict(c);
+ map->swap(devChannel, c);
+ continue;
+ }
+
+ // Otherwise, we have two essential channels claiming the same
+ // device channel.
+ songMapped = false;
+ break;
+ }
+
+ if (!songMapped) {
+ // We failed to map this song, so unmap all its channels.
+#ifdef DEBUG_REMAP
+ debug(" Failed song");
+#endif
+ *map = backupMap;
+ }
+ }
+
+ return map;
+}
+
+void SciMusic::resetDeviceChannel(int devChannel) {
+ // NB: This function should only be called from the main thread
+
+ assert(devChannel >= 0 && devChannel <= 0x0F);
+
+ putMidiCommandInQueue(0x0040B0 | devChannel); // sustain off
+ putMidiCommandInQueue(0x007BB0 | devChannel); // notes off
+ putMidiCommandInQueue(0x004BB0 | devChannel); // release voices
+}
+
+
+
} // End of namespace Sci
diff --git a/engines/sci/sound/music.h b/engines/sci/sound/music.h
index 40236c8445..6149bb799e 100644
--- a/engines/sci/sound/music.h
+++ b/engines/sci/sound/music.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -52,6 +52,17 @@ class SegManager;
typedef Common::Array<uint16> SignalQueue;
+
+struct MusicEntryChannel {
+ // Channel info
+ int8 _prio; // 0 = essential; lower is higher priority
+ int8 _voices;
+ bool _dontRemap;
+ bool _dontMap;
+ bool _mute;
+};
+
+
class MusicEntry : public Common::Serializable {
public:
// Do not get these directly for the sound objects!
@@ -90,6 +101,8 @@ public:
Audio::Mixer::SoundType soundType;
+ int _usedChannels[16];
+ MusicEntryChannel _chan[16];
MidiParser_SCI *pMidiParser;
// this is used for storing signals, when the current signal is not yet
@@ -114,6 +127,27 @@ public:
virtual void saveLoadWithSerializer(Common::Serializer &ser);
};
+struct DeviceChannelUsage {
+ MusicEntry *_song;
+ int _channel;
+ bool operator==(const DeviceChannelUsage& other) const { return _song == other._song && _channel == other._channel; }
+ bool operator!=(const DeviceChannelUsage& other) const { return !(*this == other); }
+};
+
+struct ChannelRemapping {
+ DeviceChannelUsage _map[16];
+ int _prio[16];
+ int _voices[16];
+ bool _dontRemap[16];
+ int _freeVoices;
+
+ void clear();
+ void swap(int i, int j);
+ void evict(int i);
+ ChannelRemapping& operator=(ChannelRemapping& other);
+ int lowestPrio() const;
+};
+
typedef Common::Array<MusicEntry *> MusicList;
typedef Common::Array<uint32> MidiCommandQueue;
@@ -198,9 +232,6 @@ public:
// where a deadlock can occur
Common::Mutex _mutex;
- int16 tryToOwnChannel(MusicEntry *caller, int16 bestChannel);
- void freeChannels(MusicEntry *caller);
-
protected:
void sortPlayList();
@@ -213,6 +244,11 @@ protected:
// If true and a sound has a digital track, the sound from the AdLib track is played
bool _useDigitalSFX;
+ // remapping:
+ void remapChannels();
+ ChannelRemapping *determineChannelMap();
+ void resetDeviceChannel(int devChannel);
+
private:
MusicList _playList;
bool _soundOn;
@@ -221,11 +257,15 @@ private:
int8 _channelRemap[16];
int8 _globalReverb;
+ DeviceChannelUsage _channelMap[16];
+
MidiCommandQueue _queuedCommands;
MusicType _musicType;
int _driverFirstChannel;
int _driverLastChannel;
+
+ MusicEntry *_currentlyPlayingSample;
};
} // End of namespace Sci
diff --git a/engines/sci/sound/soundcmd.cpp b/engines/sci/sound/soundcmd.cpp
index e36c5705ab..73e0a23a6a 100644
--- a/engines/sci/sound/soundcmd.cpp
+++ b/engines/sci/sound/soundcmd.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -61,7 +61,7 @@ reg_t SoundCommandParser::kDoSoundInit(int argc, reg_t *argv, reg_t acc) {
}
int SoundCommandParser::getSoundResourceId(reg_t obj) {
- int resourceId = obj.getSegment() ? readSelectorValue(_segMan, obj, SELECTOR(number)) : -1;
+ int resourceId = obj.getSegment() ? (int)readSelectorValue(_segMan, obj, SELECTOR(number)) : -1;
// Modify the resourceId for the Windows versions that have an alternate MIDI soundtrack, like SSCI did.
if (g_sci && g_sci->_features->useAltWinGMSound()) {
// Check if the alternate MIDI song actually exists...
@@ -508,9 +508,19 @@ void SoundCommandParser::processUpdateCues(reg_t obj) {
// fireworks).
// It is also needed in other games, e.g. LSL6 when talking to the
// receptionist (bug #3192166).
- // CHECKME: At least kq5cd/win and kq6 set signal to 0xFE here, but
- // kq5cd/dos does not set signal at all. Needs more investigation.
- writeSelectorValue(_segMan, obj, SELECTOR(signal), SIGNAL_OFFSET);
+ // TODO: More thorougly check the different SCI version:
+ // * SCI1late sets signal to 0xFE here. (With signal 0xFF
+ // duplicate music plays in LauraBow2CD - bug #6462)
+ // SCI1middle LSL1 1.000.510 does not have the 0xFE;
+ // SCI1late CastleDrBrain demo 1.000.005 does have the 0xFE.
+ // * Other SCI1 games seem to rely on processStopSound to set the signal
+ // * Need to check SCI0 behaviour.
+ uint16 sig;
+ if (getSciVersion() >= SCI_VERSION_1_LATE)
+ sig = 0xFFFE;
+ else
+ sig = SIGNAL_OFFSET;
+ writeSelectorValue(_segMan, obj, SELECTOR(signal), sig);
if (_soundVersion <= SCI_VERSION_0_LATE) {
processStopSound(obj, false);
} else {
diff --git a/engines/sci/sound/soundcmd.h b/engines/sci/sound/soundcmd.h
index d76f969c7d..4effda68e4 100644
--- a/engines/sci/sound/soundcmd.h
+++ b/engines/sci/sound/soundcmd.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/util.cpp b/engines/sci/util.cpp
index 4f09bb7a55..3a9ed9ca69 100644
--- a/engines/sci/util.cpp
+++ b/engines/sci/util.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/util.h b/engines/sci/util.h
index 0da5063a69..378030939c 100644
--- a/engines/sci/util.h
+++ b/engines/sci/util.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/video/robot_decoder.cpp b/engines/sci/video/robot_decoder.cpp
index a567ece2ea..a2795d21f9 100644
--- a/engines/sci/video/robot_decoder.cpp
+++ b/engines/sci/video/robot_decoder.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -116,6 +116,10 @@ bool RobotDecoder::load(GuiResourceId id) {
if (g_sci->getGameId() == GID_RAMA && id == 1003)
return false;
+ // Robots for the options in the RAMA menu
+ if (g_sci->getGameId() == GID_RAMA && (id >= 1004 && id <= 1009))
+ return false;
+
// TODO: The robot video in the Lighthouse demo gets stuck
if (g_sci->getGameId() == GID_LIGHTHOUSE && id == 16)
return false;
diff --git a/engines/sci/video/robot_decoder.h b/engines/sci/video/robot_decoder.h
index 437954f7fb..4faea5008a 100644
--- a/engines/sci/video/robot_decoder.h
+++ b/engines/sci/video/robot_decoder.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/video/seq_decoder.cpp b/engines/sci/video/seq_decoder.cpp
index 54603ec1f1..f523a42ca5 100644
--- a/engines/sci/video/seq_decoder.cpp
+++ b/engines/sci/video/seq_decoder.cpp
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
diff --git a/engines/sci/video/seq_decoder.h b/engines/sci/video/seq_decoder.h
index 890f349feb..e141f8dee0 100644
--- a/engines/sci/video/seq_decoder.h
+++ b/engines/sci/video/seq_decoder.h
@@ -8,12 +8,12 @@
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
-
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
-
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.