diff options
author | Johannes Schickel | 2008-04-05 03:03:10 +0000 |
---|---|---|
committer | Johannes Schickel | 2008-04-05 03:03:10 +0000 |
commit | b99d5603cf871ab5b5b9800d44f21469d603ddd7 (patch) | |
tree | 7db1475de569d8cea5c9f7e831efa636baac9853 /engines/kyra | |
parent | 066a55ef33f258c1ecc3eb4518d13dc3419819c1 (diff) | |
download | scummvm-rg350-b99d5603cf871ab5b5b9800d44f21469d603ddd7.tar.gz scummvm-rg350-b99d5603cf871ab5b5b9800d44f21469d603ddd7.tar.bz2 scummvm-rg350-b99d5603cf871ab5b5b9800d44f21469d603ddd7.zip |
- Changed quicksaves to use slots 990-998.
- Made slots 990-999 not writeable for savegames via menu.
- Temporary save in HoF now uses slot 999.
svn-id: r31400
Diffstat (limited to 'engines/kyra')
-rw-r--r-- | engines/kyra/gui.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/gui_v2.cpp | 10 | ||||
-rw-r--r-- | engines/kyra/kyra_v1.cpp | 4 | ||||
-rw-r--r-- | engines/kyra/kyra_v2.cpp | 4 |
4 files changed, 8 insertions, 12 deletions
diff --git a/engines/kyra/gui.cpp b/engines/kyra/gui.cpp index c46c3cc241..056f75a570 100644 --- a/engines/kyra/gui.cpp +++ b/engines/kyra/gui.cpp @@ -322,7 +322,7 @@ void GUI::updateSaveList() { int GUI::getNextSavegameSlot() { Common::InSaveFile *in; - for (int i = 1; i < 1000; i++) { + for (int i = 1; i < 990; i++) { if ((in = _vm->_saveFileMan->openForLoading(_vm->getSavegameFilename(i)))) delete in; else diff --git a/engines/kyra/gui_v2.cpp b/engines/kyra/gui_v2.cpp index 2276b68952..abfba42283 100644 --- a/engines/kyra/gui_v2.cpp +++ b/engines/kyra/gui_v2.cpp @@ -1312,10 +1312,8 @@ int GUI_v2::optionsButton(Button *button) { if (!_loadedSave && _reloadTemporarySave) { _vm->_unkSceneScreenFlag1 = true; - Common::String save = _vm->getSavegameFilename(0); - save += ".TMP"; - _vm->loadGame(save.c_str()); - _vm->_saveFileMan->removeSavefile(save.c_str()); + _vm->loadGame(_vm->getSavegameFilename(999)); + _vm->_saveFileMan->removeSavefile(_vm->getSavegameFilename(999)); _vm->_unkSceneScreenFlag1 = false; } @@ -1512,9 +1510,7 @@ int GUI_v2::gameOptions(Button *caller) { if (_vm->_lang != lang) { _reloadTemporarySave = true; - Common::String save = _vm->getSavegameFilename(0); - save += ".TMP"; - _vm->saveGame(save.c_str(), "Temporary Kyrandia 2 Savegame"); + _vm->saveGame(_vm->getSavegameFilename(999), "Temporary Kyrandia 2 Savegame"); _vm->loadCCodeBuffer("C_CODE.XXX"); if (_vm->_flags.isTalkie) _vm->loadOptionsBuffer("OPTIONS.XXX"); diff --git a/engines/kyra/kyra_v1.cpp b/engines/kyra/kyra_v1.cpp index 83cdf47258..74c68d0d42 100644 --- a/engines/kyra/kyra_v1.cpp +++ b/engines/kyra/kyra_v1.cpp @@ -489,13 +489,13 @@ void KyraEngine_v1::delay(uint32 amount, bool update, bool isMainLoop) { case Common::EVENT_KEYDOWN: if (event.kbd.keycode >= '1' && event.kbd.keycode <= '9' && (event.kbd.flags == Common::KBD_CTRL || event.kbd.flags == Common::KBD_ALT) && isMainLoop) { - const char *saveLoadSlot = getSavegameFilename(event.kbd.keycode - '0'); + const char *saveLoadSlot = getSavegameFilename(9 - (event.kbd.keycode - '0') + 990); if (event.kbd.flags == Common::KBD_CTRL) loadGame(saveLoadSlot); else { char savegameName[14]; - sprintf(savegameName, "Quicksave %d", event.kbd.keycode - '0'); + sprintf(savegameName, "Quicksave %d", event.kbd.keycode - '0'); saveGame(saveLoadSlot, savegameName); } } else if (event.kbd.flags == Common::KBD_CTRL) { diff --git a/engines/kyra/kyra_v2.cpp b/engines/kyra/kyra_v2.cpp index 8742bdeb3d..5e4ac8909f 100644 --- a/engines/kyra/kyra_v2.cpp +++ b/engines/kyra/kyra_v2.cpp @@ -798,7 +798,7 @@ int KyraEngine_v2::checkInput(Button *buttonList, bool mainLoop) { case Common::EVENT_KEYDOWN: if (event.kbd.keycode >= '1' && event.kbd.keycode <= '9' && (event.kbd.flags == Common::KBD_CTRL || event.kbd.flags == Common::KBD_ALT) && mainLoop) { - const char *saveLoadSlot = getSavegameFilename(event.kbd.keycode - '0'); + const char *saveLoadSlot = getSavegameFilename(9 - (event.kbd.keycode - '0') + 990); if (event.kbd.flags == Common::KBD_CTRL) { loadGame(saveLoadSlot); @@ -806,7 +806,7 @@ int KyraEngine_v2::checkInput(Button *buttonList, bool mainLoop) { breakLoop = true; } else { char savegameName[14]; - sprintf(savegameName, "Quicksave %d", event.kbd.keycode - '0'); + sprintf(savegameName, "Quicksave %d", event.kbd.keycode - '0'); saveGame(saveLoadSlot, savegameName); } } else if (event.kbd.flags == Common::KBD_CTRL) { |