aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine/savegame.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sci/engine/savegame.cpp')
-rw-r--r--engines/sci/engine/savegame.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/engines/sci/engine/savegame.cpp b/engines/sci/engine/savegame.cpp
index d7fe009c9a..17bdebc76d 100644
--- a/engines/sci/engine/savegame.cpp
+++ b/engines/sci/engine/savegame.cpp
@@ -48,6 +48,7 @@
#include "sci/sound/music.h"
#ifdef ENABLE_SCI32
+#include "sci/engine/guest_additions.h"
#include "sci/graphics/cursor32.h"
#include "sci/graphics/frameout.h"
#include "sci/graphics/palette32.h"
@@ -256,7 +257,6 @@ void SegManager::saveLoadWithSerializer(Common::Serializer &s) {
ObjMap objects = scr->getObjectMap();
for (ObjMap::iterator it = objects.begin(); it != objects.end(); ++it)
it->_value.syncBaseObject(SciSpan<const byte>(scr->getBuf(it->_value.getPos().getOffset()), scr->getBufSize() - it->_value.getPos().getOffset()));
-
}
// Sync the script's string heap
@@ -297,6 +297,10 @@ void SegManager::saveLoadWithSerializer(Common::Serializer &s) {
}
}
}
+
+ if (s.isLoading() && pass == passes) {
+ g_sci->_guestAdditions->instantiateScriptHook(*scr);
+ }
}
}
}