diff options
author | Filippos Karapetis | 2010-05-31 00:04:38 +0000 |
---|---|---|
committer | Filippos Karapetis | 2010-05-31 00:04:38 +0000 |
commit | 693618d89a56ccc943f9f0608abf8737d5002d32 (patch) | |
tree | 8cad7e791593feda974e3fc8d520148ae2c485cf /engines/sci/engine/savegame.cpp | |
parent | 50cd1d1da4a934cfcdcf7cb0b05bed6f7d9735c2 (diff) | |
download | scummvm-rg350-693618d89a56ccc943f9f0608abf8737d5002d32.tar.gz scummvm-rg350-693618d89a56ccc943f9f0608abf8737d5002d32.tar.bz2 scummvm-rg350-693618d89a56ccc943f9f0608abf8737d5002d32.zip |
Slight cleanup
svn-id: r49339
Diffstat (limited to 'engines/sci/engine/savegame.cpp')
-rw-r--r-- | engines/sci/engine/savegame.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/engines/sci/engine/savegame.cpp b/engines/sci/engine/savegame.cpp index ae233f8c09..07c40b332c 100644 --- a/engines/sci/engine/savegame.cpp +++ b/engines/sci/engine/savegame.cpp @@ -751,14 +751,12 @@ static void reconstruct_stack(EngineState *retval) { // TODO: Move thie function to a more appropriate place, such as vm.cpp or script.cpp void SegManager::reconstructScripts(EngineState *s) { uint i; - SegmentObj *mobj; for (i = 0; i < _heap.size(); i++) { - mobj = _heap[i]; - if (!mobj || mobj->getType() != SEG_TYPE_SCRIPT) + if (!_heap[i] || _heap[i]->getType() != SEG_TYPE_SCRIPT) continue; - Script *scr = (Script *)mobj; + Script *scr = (Script *)_heap[i]; // FIXME: Unify this code with script_instantiate_* ? scr->load(g_sci->getResMan()); @@ -773,11 +771,10 @@ void SegManager::reconstructScripts(EngineState *s) { } for (i = 0; i < _heap.size(); i++) { - mobj = _heap[i]; - if (!mobj || mobj->getType() != SEG_TYPE_SCRIPT) + if (!_heap[i] || _heap[i]->getType() != SEG_TYPE_SCRIPT) continue; - Script *scr = (Script *)mobj; + Script *scr = (Script *)_heap[i]; // FIXME: Unify this code with Script::scriptObjInit ? ObjMap::iterator it; |