aboutsummaryrefslogtreecommitdiff
path: root/engines/sci
diff options
context:
space:
mode:
authorsluicebox2019-08-19 18:37:44 -0700
committersluicebox2019-08-19 18:37:44 -0700
commitcc05dbccd907c9c80e0f5899cb640f2c8a2beb57 (patch)
treeedbc9f6c51aad2339b029b81c927ff3061c6004d /engines/sci
parentaab22041310e343f0c809b3e7f647cbc5550a625 (diff)
downloadscummvm-rg350-cc05dbccd907c9c80e0f5899cb640f2c8a2beb57.tar.gz
scummvm-rg350-cc05dbccd907c9c80e0f5899cb640f2c8a2beb57.tar.bz2
scummvm-rg350-cc05dbccd907c9c80e0f5899cb640f2c8a2beb57.zip
SCI: Fix PQ3 doctor's mouth animation speed
Fixes bug #10255
Diffstat (limited to 'engines/sci')
-rw-r--r--engines/sci/engine/script_patches.cpp28
1 files changed, 27 insertions, 1 deletions
diff --git a/engines/sci/engine/script_patches.cpp b/engines/sci/engine/script_patches.cpp
index 5d741300c4..cf391b86b4 100644
--- a/engines/sci/engine/script_patches.cpp
+++ b/engines/sci/engine/script_patches.cpp
@@ -7739,9 +7739,35 @@ static const uint16 pq3PatchGiveLocketPoints[] = {
PATCH_END
};
+// The doctor's mouth moves too fast in room 36. doctorMouth:cyleSpeed is set to
+// one, the maximum speed, unlike any other inset in the game. Most insets use
+// the default speed of six and almost all the rest use an even slower speed.
+// We set the doctor's mouth to the default speed.
+//
+// Applies to: All versions
+// Responsible method: insetDoctor:init
+// Fixes bug: #10255
+static const uint16 pq3SignatureDoctorMouthSpeed[] = {
+ 0x38, SIG_MAGICDWORD, // pushi cyleSpeed
+ SIG_SELECTOR16(cycleSpeed),
+ 0x78, // push1
+ 0x78, // push1
+ SIG_ADDTOOFFSET(+13),
+ 0x4a, 0x1c, // send 1c [ doctorMouth ... cycleSpeed: 1 ... ]
+ SIG_END,
+};
+
+static const uint16 pq3PatchDoctorMouthSpeed[] = {
+ 0x32, PATCH_UINT16(0x0002), // jmp 0002
+ PATCH_ADDTOOFFSET(+15),
+ 0x4a, 0x16, // send 16 [ don't set cycleSpeed, use default (6) ]
+ SIG_END,
+};
+
// script, description, signature patch
static const SciScriptPatcherEntry pq3Signatures[] = {
- { true, 36, "give locket missing points", 1, pq3SignatureGiveLocketPoints, pq3PatchGiveLocketPoints },
+ { true, 36, "give locket missing points", 1, pq3SignatureGiveLocketPoints, pq3PatchGiveLocketPoints },
+ { true, 36, "doctor mouth speed", 1, pq3SignatureDoctorMouthSpeed, pq3PatchDoctorMouthSpeed },
SCI_SIGNATUREENTRY_TERMINATOR
};