diff options
Diffstat (limited to 'engines/sci/engine/script.cpp')
-rw-r--r-- | engines/sci/engine/script.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/sci/engine/script.cpp b/engines/sci/engine/script.cpp index 2fe1aba975..88becc82cc 100644 --- a/engines/sci/engine/script.cpp +++ b/engines/sci/engine/script.cpp @@ -136,9 +136,6 @@ void Script::load(int script_nr, ResourceManager *resMan, ScriptPatcher *scriptP assert(_bufSize >= script->size); memcpy(_buf, script->data, script->size); - // Check scripts for matching signatures and patch those, if found - scriptPatcher->processScript(_nr, _buf, script->size); - if (getSciVersion() >= SCI_VERSION_1_1 && getSciVersion() <= SCI_VERSION_2_1) { Resource *heap = resMan->findResource(ResourceId(kResourceTypeHeap, _nr), 0); assert(heap != 0); @@ -149,6 +146,9 @@ void Script::load(int script_nr, ResourceManager *resMan, ScriptPatcher *scriptP memcpy(_heapStart, heap->data, heap->size); } + // Check scripts (+ possibly SCI 1.1 heap) for matching signatures and patch those, if found + scriptPatcher->processScript(_nr, _buf, _bufSize); + if (getSciVersion() <= SCI_VERSION_1_LATE) { _exportTable = (const uint16 *)findBlockSCI0(SCI_OBJ_EXPORTS); if (_exportTable) { |