diff options
Diffstat (limited to 'engines/sci/engine')
-rw-r--r-- | engines/sci/engine/features.cpp | 10 | ||||
-rw-r--r-- | engines/sci/engine/kscripts.cpp | 4 |
2 files changed, 7 insertions, 7 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; diff --git a/engines/sci/engine/kscripts.cpp b/engines/sci/engine/kscripts.cpp index 98c35fcb49..af4b8ff081 100644 --- a/engines/sci/engine/kscripts.cpp +++ b/engines/sci/engine/kscripts.cpp @@ -160,7 +160,7 @@ reg_t kClone(EngineState *s, int argc, reg_t *argv) { debugC(kDebugLevelMemory, "Attempting to clone from %04x:%04x", PRINT_REG(parentAddr)); - uint16 infoSelector = parentObj->getInfoSelector().getOffset(); + uint16 infoSelector = parentObj->getInfoSelector().toUint16(); cloneObj = s->_segMan->allocateClone(&cloneAddr); if (!cloneObj) { @@ -211,7 +211,7 @@ reg_t kDisposeClone(EngineState *s, int argc, reg_t *argv) { // At least kq4early relies on this behavior. The scripts clone "Sound", then set bit 1 manually // and call kDisposeClone later. In that case we may not free it, otherwise we will run into issues // later, because kIsObject would then return false and Sound object wouldn't get checked. - uint16 infoSelector = object->getInfoSelector().getOffset(); + uint16 infoSelector = object->getInfoSelector().toUint16(); if ((infoSelector & 3) == kInfoFlagClone) object->markAsFreed(); |