[Scummvm-cvs-logs] SF.net SVN: scummvm:[41006] scummvm/trunk/engines/kyra/detection.cpp

lordhoto at users.sourceforge.net lordhoto at users.sourceforge.net
Fri May 29 16:58:08 CEST 2009


Revision: 41006
          http://scummvm.svn.sourceforge.net/scummvm/?rev=41006&view=rev
Author:   lordhoto
Date:     2009-05-29 14:58:08 +0000 (Fri, 29 May 2009)

Log Message:
-----------
Some slight documentation.

Modified Paths:
--------------
    scummvm/trunk/engines/kyra/detection.cpp

Modified: scummvm/trunk/engines/kyra/detection.cpp
===================================================================
--- scummvm/trunk/engines/kyra/detection.cpp	2009-05-29 14:56:53 UTC (rev 41005)
+++ scummvm/trunk/engines/kyra/detection.cpp	2009-05-29 14:58:08 UTC (rev 41006)
@@ -1204,7 +1204,8 @@
 			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 @@
 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 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);
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list