[Scummvm-cvs-logs] scummvm master -> 40b224fc74337315dd485a7e8cdbf19bd37dc941

bluegr bluegr at gmail.com
Wed Oct 29 10:26:20 CET 2014


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
40b224fc74 SCUMM: Disallow saving while a room 'prequel' is shown in v0-v3 games


Commit: 40b224fc74337315dd485a7e8cdbf19bd37dc941
    https://github.com/scummvm/scummvm/commit/40b224fc74337315dd485a7e8cdbf19bd37dc941
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2014-10-29T11:23:59+02:00

Commit Message:
SCUMM: Disallow saving while a room 'prequel' is shown in v0-v3 games

These are cases where the screen is completely blank, showing text.
In such cases, no room is set, thus no room resources are available.
An example is the screen shown after the credits in the Zak FM-TOWNS
intro ("The next day..."). Thanks to segrax for finding this case.
This commit is based off pull request 522, but completely disallows
saving in such scenes, instead of adding explicit checks for them

Changed paths:
    engines/scumm/saveload.cpp



diff --git a/engines/scumm/saveload.cpp b/engines/scumm/saveload.cpp
index 7eadb04..0c0f6be 100644
--- a/engines/scumm/saveload.cpp
+++ b/engines/scumm/saveload.cpp
@@ -109,7 +109,12 @@ Common::Error ScummEngine::saveGameState(int slot, const Common::String &desc) {
 }
 
 bool ScummEngine::canSaveGameStateCurrently() {
-	// FIXME: For now always allow loading in V0-V3 games
+	// Disallow saving in v0-v3 games when a 'prequel' to a cutscene is shown.
+	// This is a blank screen with text, and while this is shown, saving should
+	// be disabled, as no room is set.
+	if (_game.version <= 3 && _currentScript == 0xFF && _roomResource == 0 && _currentRoom == 0)
+		return false;
+
 	// TODO: Should we disallow saving in some more places,
 	// e.g. when a SAN movie is playing? Not sure whether the
 	// original EXE allowed this.






More information about the Scummvm-git-logs mailing list