[Scummvm-git-logs] scummvm branch-2-7 -> c536dff6966b8afed3a2cdfbbd9a859ec95b6e2f
sluicebox
noreply at scummvm.org
Thu Jul 13 23:35:52 UTC 2023
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
c536dff696 SCI: Update speed test overflow fix for more versions
Commit: c536dff6966b8afed3a2cdfbbd9a859ec95b6e2f
https://github.com/scummvm/scummvm/commit/c536dff6966b8afed3a2cdfbbd9a859ec95b6e2f
Author: sluicebox (22204938+sluicebox at users.noreply.github.com)
Date: 2023-07-13T16:35:40-07:00
Commit Message:
SCI: Update speed test overflow fix for more versions
Changed paths:
engines/sci/engine/script_patches.cpp
diff --git a/engines/sci/engine/script_patches.cpp b/engines/sci/engine/script_patches.cpp
index 2585a1abfe6..b724170b8aa 100644
--- a/engines/sci/engine/script_patches.cpp
+++ b/engines/sci/engine/script_patches.cpp
@@ -639,18 +639,19 @@ static const uint16 sci11SpeedTestPatch[] = {
// The speed test originally used a signed comparison, causing the test to take
// nine minutes if kGetTime rolled over during it. This could happen when
-// restarting the game. This bug conflicts with our speed test patch in KQ4,
-// because after its very long introduction it runs the test again.
-// We fix this with an unsigned comparison, as Sierra did.
+// restarting the game. We fix this bug with an unsigned comparison, as Sierra
+// did, otherwise our patch will cause the test to hang when kGetTime is large.
static const uint16 sci0SpeedTestOverflowSignature[] = {
SIG_MAGICDWORD,
- 0x43, 0x46, 0x00, // callk GetTime
+ 0x8b, 0x00, // lsl 00
+ 0x76, // push0
+ 0x43, SIG_ADDTOOFFSET(+1), 0x00, // callk GetTime 00
0x22, // lt?
SIG_END
};
static const uint16 sci0SpeedTestOverflowPatch[] = {
- PATCH_ADDTOOFFSET(+3),
+ PATCH_ADDTOOFFSET(+6),
0x2a, // ult?
PATCH_END
};
More information about the Scummvm-git-logs
mailing list