diff options
author | Filippos Karapetis | 2010-05-30 21:49:07 +0000 |
---|---|---|
committer | Filippos Karapetis | 2010-05-30 21:49:07 +0000 |
commit | a0ee93ece52213cd989a50902281d917fe392ea4 (patch) | |
tree | c3f56972fc286a2fd399ad61dd0fd1d648b9a775 /engines/sci/engine/savegame.cpp | |
parent | e13abd77e92a4c363731f4a6775aa26865bb4ad6 (diff) | |
download | scummvm-rg350-a0ee93ece52213cd989a50902281d917fe392ea4.tar.gz scummvm-rg350-a0ee93ece52213cd989a50902281d917fe392ea4.tar.bz2 scummvm-rg350-a0ee93ece52213cd989a50902281d917fe392ea4.zip |
SCI: Script exports and synonyms are now initialized when a script is loaded. Removed a sanity check inside script_instantiate_sci0 for a bug which no longer exists
svn-id: r49336
Diffstat (limited to 'engines/sci/engine/savegame.cpp')
-rw-r--r-- | engines/sci/engine/savegame.cpp | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/engines/sci/engine/savegame.cpp b/engines/sci/engine/savegame.cpp index 2d21ce6cbb..ae233f8c09 100644 --- a/engines/sci/engine/savegame.cpp +++ b/engines/sci/engine/savegame.cpp @@ -541,8 +541,8 @@ void Script::saveLoadWithSerializer(Common::Serializer &s) { } } - s.syncAsSint32LE(_numExports); - s.syncAsSint32LE(_numSynonyms); + s.skip(4, VER(9), VER(19)); // OBSOLETE: Used to be _numExports + s.skip(4, VER(9), VER(19)); // OBSOLETE: Used to be _numSynonyms s.syncAsSint32LE(_lockers); // Sync _objects. This is a hashmap, and we use the following on disk format: @@ -763,18 +763,6 @@ void SegManager::reconstructScripts(EngineState *s) { // FIXME: Unify this code with script_instantiate_* ? scr->load(g_sci->getResMan()); scr->_localsBlock = (scr->_localsSegment == 0) ? NULL : (LocalVariables *)(_heap[scr->_localsSegment]); - if (getSciVersion() >= SCI_VERSION_1_1) { - scr->_exportTable = 0; - scr->_synonyms = 0; - if (READ_LE_UINT16(scr->_buf + 6) > 0) { - scr->setExportTableOffset(6); - } - } else { - scr->_exportTable = (const uint16 *)scr->findBlock(SCI_OBJ_EXPORTS); - scr->_synonyms = scr->findBlock(SCI_OBJ_SYNONYMS); - scr->_exportTable += 3; - } - scr->_codeBlocks.clear(); ObjMap::iterator it; const ObjMap::iterator end = scr->_objects.end(); |