aboutsummaryrefslogtreecommitdiff
path: root/engines/toltecs/toltecs.cpp
diff options
context:
space:
mode:
authorBenjamin Haisch2010-10-18 11:00:17 +0000
committerWillem Jan Palenstijn2011-11-20 22:43:10 +0100
commit9c3a4bc055243af586f7ab091ba802e5274943b5 (patch)
tree76e0cae6b043bea78929d385be55d0b7d597eec1 /engines/toltecs/toltecs.cpp
parent8f3b287db139383c45a04e729b85474a9129578c (diff)
downloadscummvm-rg350-9c3a4bc055243af586f7ab091ba802e5274943b5.tar.gz
scummvm-rg350-9c3a4bc055243af586f7ab091ba802e5274943b5.tar.bz2
scummvm-rg350-9c3a4bc055243af586f7ab091ba802e5274943b5.zip
TOLTECS: - Implement kSupportsLoadingDuringStartup
Diffstat (limited to 'engines/toltecs/toltecs.cpp')
-rw-r--r--engines/toltecs/toltecs.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/engines/toltecs/toltecs.cpp b/engines/toltecs/toltecs.cpp
index 62bf250062..0c8d5658b3 100644
--- a/engines/toltecs/toltecs.cpp
+++ b/engines/toltecs/toltecs.cpp
@@ -174,7 +174,14 @@ Common::Error ToltecsEngine::run() {
#if 1
_script->loadScript(0, 0);
- _script->runScript(0);
+ _script->setMainScript(0);
+ if (ConfMan.hasKey("save_slot")) {
+ int saveSlot = ConfMan.getInt("save_slot");
+ if (saveSlot >= 0 && saveSlot <= 99) {
+ loadGameState(saveSlot);
+ }
+ }
+ _script->runScript();
#endif
delete _arc;