From 1938d95c4e17bd50f96c75fa7ecb826b4e83f65b Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Sun, 25 Mar 2012 17:48:38 +0300 Subject: SCI: Rename the sci_originalsavedload option to originalsaveload This changes its naming to be like the rest of the game options --- engines/sci/sci.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index 4ae55cbcba..9b0ee6924b 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -191,7 +191,7 @@ extern void showScummVMDialog(const Common::String &message); Common::Error SciEngine::run() { // Assign default values to the config manager, in case settings are missing - ConfMan.registerDefault("sci_originalsaveload", "false"); + ConfMan.registerDefault("originalsaveload", "false"); ConfMan.registerDefault("native_fb01", "false"); ConfMan.registerDefault("windows_cursors", "false"); // Windows cursors for KQ6 Windows ConfMan.registerDefault("silver_cursors", "false"); // Silver cursors for SQ4 CD @@ -492,7 +492,7 @@ void SciEngine::patchGameSaveRestore() { break; } - if (ConfMan.getBool("sci_originalsaveload")) + if (ConfMan.getBool("originalsaveload")) return; uint16 kernelNamesSize = _kernel->getKernelNamesSize(); -- cgit v1.2.3 From 7f9c63239b2f360b6d96e8ff4dd007b80d990e46 Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Sat, 31 Mar 2012 05:54:30 +0300 Subject: SCI: Make sure that the disable_dithering key exists --- engines/sci/sci.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index 9b0ee6924b..c77b49400f 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -221,7 +221,8 @@ Common::Error SciEngine::run() { // Initialize the game screen _gfxScreen = new GfxScreen(_resMan); - _gfxScreen->enableUndithering(ConfMan.getBool("disable_dithering")); + bool enableUnDitheringFlag = ConfMan.hasKey("disable_dithering") && ConfMan.getBool("disable_dithering"); + _gfxScreen->enableUndithering(enableUnDitheringFlag); _kernel = new Kernel(_resMan, segMan); -- cgit v1.2.3 From 6a49d3eadd7555a4f5f539ceb73fdfe370fce9da Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Sat, 31 Mar 2012 13:55:03 +0300 Subject: ENGINES: Return all available custom GUI options if no target is specified This is used to set default settings for all custom game options when an engine starts --- engines/sci/sci.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index c77b49400f..9b0ee6924b 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -221,8 +221,7 @@ Common::Error SciEngine::run() { // Initialize the game screen _gfxScreen = new GfxScreen(_resMan); - bool enableUnDitheringFlag = ConfMan.hasKey("disable_dithering") && ConfMan.getBool("disable_dithering"); - _gfxScreen->enableUndithering(enableUnDitheringFlag); + _gfxScreen->enableUndithering(ConfMan.getBool("disable_dithering")); _kernel = new Kernel(_resMan, segMan); -- cgit v1.2.3 From a1554b9ddd719efc97cbf344fe84d20416810b0b Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Tue, 22 May 2012 10:47:04 +0300 Subject: SCI: Fix the detection of the NRS patch for QFG3 --- engines/sci/sci.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index 9b0ee6924b..960016764a 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -385,7 +385,7 @@ bool SciEngine::gameHasFanMadePatch() { { GID_PQ3, 994, 4686, 1291, 0x78 }, // English { GID_PQ3, 994, 4734, 1283, 0x78 }, // German { GID_QFG1VGA, 994, 4388, 0, 0x00 }, - { GID_QFG3, 994, 4714, 0, 0x00 }, + { GID_QFG3, 33, 260, 0, 0x00 }, // TODO: Disabled, as it fixes a whole lot of bugs which can't be tested till SCI2.1 support is finished //{ GID_QFG4, 710, 11477, 0, 0x00 }, { GID_SQ1, 994, 4740, 0, 0x00 }, -- cgit v1.2.3 From 2b50824133ced47f1d8fb6407a1e0212a7eeb41c Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Mon, 18 Jun 2012 05:21:59 +0300 Subject: SCI: Add setter/getter methods to reg_t's No functionality change has been made with this commit. This avoids setting and getting the reg_t members directly, and is the basis of any future work on large SCI3 scripts (larger than 64KB) --- engines/sci/sci.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index 960016764a..d43a9d06fc 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -453,8 +453,8 @@ static byte patchGameRestoreSaveSci21[] = { }; static void patchGameSaveRestoreCode(SegManager *segMan, reg_t methodAddress, byte id) { - Script *script = segMan->getScript(methodAddress.segment); - byte *patchPtr = const_cast(script->getBuf(methodAddress.offset)); + Script *script = segMan->getScript(methodAddress.getSegment()); + byte *patchPtr = const_cast(script->getBuf(methodAddress.getOffset())); if (getSciVersion() <= SCI_VERSION_1_1) memcpy(patchPtr, patchGameRestoreSave, sizeof(patchGameRestoreSave)); else // SCI2+ @@ -463,8 +463,8 @@ static void patchGameSaveRestoreCode(SegManager *segMan, reg_t methodAddress, by } static void patchGameSaveRestoreCodeSci21(SegManager *segMan, reg_t methodAddress, byte id, bool doRestore) { - Script *script = segMan->getScript(methodAddress.segment); - byte *patchPtr = const_cast(script->getBuf(methodAddress.offset)); + Script *script = segMan->getScript(methodAddress.getSegment()); + byte *patchPtr = const_cast(script->getBuf(methodAddress.getOffset())); memcpy(patchPtr, patchGameRestoreSaveSci21, sizeof(patchGameRestoreSaveSci21)); if (doRestore) patchPtr[2] = 0x78; // push1 @@ -740,7 +740,7 @@ GUI::Debugger *SciEngine::getDebugger() { if (_gamestate) { ExecStack *xs = &(_gamestate->_executionStack.back()); if (xs) { - xs->addr.pc.offset = _debugState.old_pc_offset; + xs->addr.pc.setOffset(_debugState.old_pc_offset); xs->sp = _debugState.old_sp; } } -- cgit v1.2.3 From d4231fda1cb2399e123054ddaaeca2b4c2749966 Mon Sep 17 00:00:00 2001 From: Matthew Hoops Date: Sun, 22 Jul 2012 23:17:36 -0400 Subject: SCI: Rewrite RobotDecoder to use the AdvancedVideoDecoder API --- engines/sci/sci.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index d43a9d06fc..42ae00b525 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -632,7 +632,7 @@ void SciEngine::initGraphics() { _gfxPaint = _gfxPaint32; _gfxText32 = new GfxText32(_gamestate->_segMan, _gfxCache, _gfxScreen); _gfxControls32 = new GfxControls32(_gamestate->_segMan, _gfxCache, _gfxScreen, _gfxText32); - _robotDecoder = new RobotDecoder(g_system->getMixer(), getPlatform() == Common::kPlatformMacintosh); + _robotDecoder = new RobotDecoder(getPlatform() == Common::kPlatformMacintosh); _gfxFrameout = new GfxFrameout(_gamestate->_segMan, _resMan, _gfxCoordAdjuster, _gfxCache, _gfxScreen, _gfxPalette, _gfxPaint32); } else { #endif -- cgit v1.2.3 From 3a852fb96acf7aaa0fa7a36c04be54b1902cc175 Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Mon, 8 Oct 2012 23:49:49 +0300 Subject: SCI: Also add LSL6 CD to syncIngameAudioOptions() --- engines/sci/sci.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'engines/sci/sci.cpp') diff --git a/engines/sci/sci.cpp b/engines/sci/sci.cpp index 42ae00b525..15b18ce8e6 100644 --- a/engines/sci/sci.cpp +++ b/engines/sci/sci.cpp @@ -876,6 +876,7 @@ void SciEngine::syncIngameAudioOptions() { 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 -- cgit v1.2.3