aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine/features.cpp
diff options
context:
space:
mode:
authorColin Snover2017-05-20 19:21:24 -0500
committerColin Snover2017-05-20 21:14:18 -0500
commit66efb750a0ccaa3c2ff8b77f60544a345328da8b (patch)
tree8393fd2462a1f13a8ed8f10e40866554ef20fe56 /engines/sci/engine/features.cpp
parent14a521a21177361184fee38242065a64c5fcdf05 (diff)
downloadscummvm-rg350-66efb750a0ccaa3c2ff8b77f60544a345328da8b.tar.gz
scummvm-rg350-66efb750a0ccaa3c2ff8b77f60544a345328da8b.tar.bz2
scummvm-rg350-66efb750a0ccaa3c2ff8b77f60544a345328da8b.zip
SCI: Add more support for >16-bit SCI3 offsets
Basically just grepped for getOffset calls being assigned to uint16s and expanded those to uint32 when they looked trivial. While some of these changes seem superfluous, at least for the US/English SCI3 games where potentially impacted game scripts are not large enough to have a problem with 16-bit offsets (e.g. when feature detecting the sound type), at least some of these changes are necessary for correct operation of the find_callk debugger command in SCI3 games. There should not be a reason why any of these variables need to be kept as uint16, in any case.
Diffstat (limited to 'engines/sci/engine/features.cpp')
-rw-r--r--engines/sci/engine/features.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/sci/engine/features.cpp b/engines/sci/engine/features.cpp
index 1e8cc6dfb9..9251ac69e1 100644
--- a/engines/sci/engine/features.cpp
+++ b/engines/sci/engine/features.cpp
@@ -77,7 +77,7 @@ bool GameFeatures::autoDetectSoundType() {
if (!addr.getSegment())
return false;
- uint16 offset = addr.getOffset();
+ uint32 offset = addr.getOffset();
Script *script = _segMan->getScript(addr.getSegment());
uint16 intParam = 0xFFFF;
bool foundTarget = false;
@@ -224,7 +224,7 @@ bool GameFeatures::autoDetectLofsType(Common::String gameSuperClassName, int met
if (!addr.getSegment())
return false;
- uint16 offset = addr.getOffset();
+ uint32 offset = addr.getOffset();
Script *script = _segMan->getScript(addr.getSegment());
while (true) {
@@ -323,7 +323,7 @@ bool GameFeatures::autoDetectGfxFunctionsType(int methodNum) {
if (!addr.getSegment())
return false;
- uint16 offset = addr.getOffset();
+ uint32 offset = addr.getOffset();
Script *script = _segMan->getScript(addr.getSegment());
while (true) {
@@ -485,7 +485,7 @@ bool GameFeatures::autoDetectSci21KernelType() {
if (!addr.getSegment())
return false;
- uint16 offset = addr.getOffset();
+ uint32 offset = addr.getOffset();
Script *script = _segMan->getScript(addr.getSegment());
while (true) {
@@ -620,7 +620,7 @@ bool GameFeatures::autoDetectMoveCountType() {
if (!addr.getSegment())
return false;
- uint16 offset = addr.getOffset();
+ uint32 offset = addr.getOffset();
Script *script = _segMan->getScript(addr.getSegment());
bool foundTarget = false;