[Scummvm-git-logs] scummvm master -> 70568e6cf289f31e7be9ac47da5d0357dfaf6bef
AndywinXp
noreply at scummvm.org
Mon Oct 16 18:27:00 UTC 2023
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:
70568e6cf2 SWORD1: Prevent softlock when saving on phone envelope screen
Commit: 70568e6cf289f31e7be9ac47da5d0357dfaf6bef
https://github.com/scummvm/scummvm/commit/70568e6cf289f31e7be9ac47da5d0357dfaf6bef
Author: AndywinXp (andywinxp at gmail.com)
Date: 2023-10-16T20:26:55+02:00
Commit Message:
SWORD1: Prevent softlock when saving on phone envelope screen
And we prevent it by... drum roll please... disabling
the main menu and saving from the GMM whenever
we are in that screen :-)
Changed paths:
engines/sword1/metaengine.cpp
engines/sword1/sword1.cpp
diff --git a/engines/sword1/metaengine.cpp b/engines/sword1/metaengine.cpp
index 464c6011b0b..54bd40e6ef7 100644
--- a/engines/sword1/metaengine.cpp
+++ b/engines/sword1/metaengine.cpp
@@ -24,6 +24,7 @@
#include "sword1/sword1.h"
#include "sword1/control.h"
+#include "sword1/logic.h"
#include "sword1/obsolete.h"
#include "common/savefile.h"
@@ -201,7 +202,7 @@ Common::Error SwordEngine::saveGameState(int slot, const Common::String &desc, b
}
bool SwordEngine::canSaveGameStateCurrently() {
- return (mouseIsActive() && !_control->isPanelShown());
+ return (mouseIsActive() && !_control->isPanelShown() && Logic::_scriptVars[SCREEN] != 91);
}
} // End of namespace Sword1
diff --git a/engines/sword1/sword1.cpp b/engines/sword1/sword1.cpp
index 4e890cb83d1..617a6cd5ca2 100644
--- a/engines/sword1/sword1.cpp
+++ b/engines/sword1/sword1.cpp
@@ -227,7 +227,9 @@ void SwordEngine::checkKeys() {
switch (_keyPressed.keycode) {
case Common::KEYCODE_F5:
case Common::KEYCODE_ESCAPE:
- if ((Logic::_scriptVars[MOUSE_STATUS] & 1) && (Logic::_scriptVars[GEORGE_HOLDING_PIECE] == 0)) {
+ if ((Logic::_scriptVars[MOUSE_STATUS] & 1) &&
+ (Logic::_scriptVars[GEORGE_HOLDING_PIECE] == 0) &&
+ (Logic::_scriptVars[SCREEN] != 91)) { // Disable the save screen on the phone envelope room!
_systemVars.saveGameFlag = SGF_SAVE;
_systemVars.snrStatus = SNR_MAINPANEL;
}
More information about the Scummvm-git-logs
mailing list