[Scummvm-git-logs] scummvm branch-2-8 -> 67dea268953098898d62ed4df41186c546506c30

AndywinXp noreply at scummvm.org
Sat Mar 9 08:08:39 UTC 2024


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:
67dea26895 SCUMM: Fix #15009


Commit: 67dea268953098898d62ed4df41186c546506c30
    https://github.com/scummvm/scummvm/commit/67dea268953098898d62ed4df41186c546506c30
Author: AndywinXp (andywinxp at gmail.com)
Date: 2024-03-09T09:08:33+01:00

Commit Message:
SCUMM: Fix #15009

Changed paths:
    engines/scumm/input.cpp


diff --git a/engines/scumm/input.cpp b/engines/scumm/input.cpp
index 64cb5fa088d..83a7fea1033 100644
--- a/engines/scumm/input.cpp
+++ b/engines/scumm/input.cpp
@@ -935,6 +935,24 @@ void ScummEngine::processKeyboard(Common::KeyState lastKeyHit) {
 	bool optionKeysEnabled = !isUsingOriginalGUI();
 	bool isSegaCD = _game.platform == Common::kPlatformSegaCD;
 	bool isNES = _game.platform == Common::kPlatformNES;
+	bool inSaveRoom = false;
+
+	// The following check is used by v3 games which have writable savegame names
+	// and also support some key combinations which in our case are mapped to SHIFT-<letter>
+	// The originals don't do this, because they use either CTRL or ALT as their key modifier,
+	// and those key modifiers serve other functions within the ScummVM backend.
+	if (_game.version == 3) {
+		int saveRoom = -1;
+		if (_game.id == GID_ZAK) {
+			saveRoom = 50;
+		} else if (_game.id == GID_INDY3) {
+			saveRoom = 14;
+		} else if (_game.id == GID_LOOM) {
+			saveRoom = 70;
+		}
+
+		inSaveRoom = _currentRoom == saveRoom;
+	}
 
 	// In FM-TOWNS games F8 / restart is always enabled
 	if (_game.platform == Common::kPlatformFMTowns)
@@ -1264,7 +1282,7 @@ void ScummEngine::processKeyboard(Common::KeyState lastKeyHit) {
 			}
 
 			if ((_game.version > 2 && _game.version < 5)) {
-				if (lastKeyHit.keycode == Common::KEYCODE_s && lastKeyHit.hasFlags(Common::KBD_SHIFT)) {
+				if (lastKeyHit.keycode == Common::KEYCODE_s && lastKeyHit.hasFlags(Common::KBD_SHIFT) && !inSaveRoom) {
 					_internalSpeakerSoundsAreOn ^= 1;
 
 					if (_internalSpeakerSoundsAreOn) {




More information about the Scummvm-git-logs mailing list