diff options
author | Johannes Schickel | 2009-05-29 14:58:08 +0000 |
---|---|---|
committer | Johannes Schickel | 2009-05-29 14:58:08 +0000 |
commit | d9228d69a76d38d502a6e65bb5875c42d2f0a947 (patch) | |
tree | 248c3b0b5874bdb31003008140ba31efa932d947 /engines | |
parent | f4b15bb87f08b4c08326a2eb301998ef9906e367 (diff) | |
download | scummvm-rg350-d9228d69a76d38d502a6e65bb5875c42d2f0a947.tar.gz scummvm-rg350-d9228d69a76d38d502a6e65bb5875c42d2f0a947.tar.bz2 scummvm-rg350-d9228d69a76d38d502a6e65bb5875c42d2f0a947.zip |
Some slight documentation.
svn-id: r41006
Diffstat (limited to 'engines')
-rw-r--r-- | engines/kyra/detection.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/engines/kyra/detection.cpp b/engines/kyra/detection.cpp index 364c856b67..41ad3467c6 100644 --- a/engines/kyra/detection.cpp +++ b/engines/kyra/detection.cpp @@ -1204,7 +1204,8 @@ SaveStateList KyraMetaEngine::listSaves(const char *target) const { Common::InSaveFile *in = saveFileMan->openForLoading(*file); if (in) { if (Kyra::KyraEngine_v1::readSaveHeader(in, false, header) == Kyra::KyraEngine_v1::kRSHENoError) { - // Workaround for old savegames using 'German' as description for kyra3 start savegame (slot 0) + // WORKAROUND: Old savegames are using 'German' as description for kyra3 restart game save (slot 0), + // since that looks odd we replace it by "New Game". if (slotNum == 0 && header.gameID == Kyra::GI_KYRA3) header.description = "New Game"; @@ -1221,7 +1222,9 @@ SaveStateList KyraMetaEngine::listSaves(const char *target) const { int KyraMetaEngine::getMaximumSaveSlot() const { return 999; } void KyraMetaEngine::removeSaveState(const char *target, int slot) const { - // In Kyra games slot 0 can't be deleted, it's for restarting the game(s) + // In Kyra games slot 0 can't be deleted, it's for restarting the game(s). + // An exception makes Lands of Lore here, it does not have any way to restart the + // game except via its main menu. if (slot == 0 && !ConfMan.getDomain(target)->get("gameid").equalsIgnoreCase("lol")) return; @@ -1244,7 +1247,13 @@ SaveStateDescriptor KyraMetaEngine::querySaveMetaInfos(const char *target, int s SaveStateDescriptor desc(slot, header.description); bool lolGame = ConfMan.getDomain(target)->get("gameid").equalsIgnoreCase("lol"); + + // Slot 0 is used for the 'restart game' save in all three Kyrandia games, thus + // we prevent it from being deleted. desc.setDeletableFlag(slot != 0 || lolGame); + + // We don't allow quick saves (slot 990 till 998) to be overwritten. + // The same goes for the 'Autosave', which is slot 999. desc.setWriteProtectedFlag((slot == 0 && !lolGame) || slot >= 990); desc.setThumbnail(header.thumbnail); |