[Scummvm-git-logs] scummvm master -> 999048d0d2b940e1be65263290363041203ad20b
fracturehill
noreply at scummvm.org
Tue Jan 9 22:08:15 UTC 2024
This automated email contains information about 4 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
3cb405f512 NANCY: Fix state changing
1b535a5de9 NANCY: Fix janky viewport movement with auto move
bb2538b57f NANCY: Do not overwrite nancy7 savefile name
999048d0d2 NANCY: Ensure cursor is drawn after launcher load
Commit: 3cb405f512f11728f126749c94aed7f676c98ffa
https://github.com/scummvm/scummvm/commit/3cb405f512f11728f126749c94aed7f676c98ffa
Author: Kaloyan Chehlarski (strahy at outlook.com)
Date: 2024-01-09T23:06:48+01:00
Commit Message:
NANCY: Fix state changing
This fixes a regression in changing states that would
result in the player being able to continue or save the game
after losing/winning.
Changed paths:
engines/nancy/nancy.cpp
engines/nancy/nancy.h
diff --git a/engines/nancy/nancy.cpp b/engines/nancy/nancy.cpp
index 81a98bf0b5a..12a36f26394 100644
--- a/engines/nancy/nancy.cpp
+++ b/engines/nancy/nancy.cpp
@@ -236,7 +236,7 @@ void NancyEngine::setState(NancyState::NancyState state, NancyState::NancyState
_gameFlow.prevState = _gameFlow.curState;
}
- _gameFlow.curState = state;
+ _gameFlow.nextState = state;
_gameFlow.changingState = true;
}
@@ -285,6 +285,9 @@ Common::Error NancyEngine::run() {
State::State *s;
if (_gameFlow.changingState) {
+ _gameFlow.curState = _gameFlow.nextState;
+ _gameFlow.nextState = NancyState::kNone;
+
s = getStateObject(_gameFlow.curState);
if (s) {
s->onStateEnter(_gameFlow.curState);
@@ -305,10 +308,10 @@ Common::Error NancyEngine::run() {
if (_gameFlow.changingState) {
_graphicsManager->clearObjects();
- s = getStateObject(_gameFlow.prevState);
+ s = getStateObject(_gameFlow.curState);
if (s) {
- if (s->onStateExit(_gameFlow.prevState)) {
- destroyState(_gameFlow.prevState);
+ if (s->onStateExit(_gameFlow.nextState)) {
+ destroyState(_gameFlow.curState);
}
}
}
diff --git a/engines/nancy/nancy.h b/engines/nancy/nancy.h
index c79aa932c1b..784248ff3ed 100644
--- a/engines/nancy/nancy.h
+++ b/engines/nancy/nancy.h
@@ -132,6 +132,7 @@ private:
struct GameFlow {
NancyState::NancyState curState = NancyState::kNone;
NancyState::NancyState prevState = NancyState::kNone;
+ NancyState::NancyState nextState = NancyState::kNone;
bool changingState = true;
};
Commit: 1b535a5de98e6ff450469513a244b581bdf5f021
https://github.com/scummvm/scummvm/commit/1b535a5de98e6ff450469513a244b581bdf5f021
Author: Kaloyan Chehlarski (strahy at outlook.com)
Date: 2024-01-09T23:06:48+01:00
Commit Message:
NANCY: Fix janky viewport movement with auto move
Fixed an issue where, if auto move is enabled, clicking
an edge with the right mouse button wouldn't begin the
fast rotation immediately, resulting in a janky feel.
Changed paths:
engines/nancy/ui/viewport.cpp
diff --git a/engines/nancy/ui/viewport.cpp b/engines/nancy/ui/viewport.cpp
index c1c1e2655eb..573ccae5e84 100644
--- a/engines/nancy/ui/viewport.cpp
+++ b/engines/nancy/ui/viewport.cpp
@@ -156,6 +156,11 @@ void Viewport::handleInput(NancyInput &input) {
direction = 0;
}
+ // Just pressed RMB down, cancel the timer (removes jank when auto move is on)
+ if (input.input & NancyInput::kRightMouseButtonDown) {
+ _nextMovementTime = 0;
+ }
+
// If we hover over an edge we don't want to click an element in the viewport underneath
// or to change the cursor, so we make the mouse input invalid
input.eatMouseInput();
Commit: bb2538b57f2d8d3ab7141277987af8d81945844e
https://github.com/scummvm/scummvm/commit/bb2538b57f2d8d3ab7141277987af8d81945844e
Author: Kaloyan Chehlarski (strahy at outlook.com)
Date: 2024-01-09T23:06:48+01:00
Commit Message:
NANCY: Do not overwrite nancy7 savefile name
Fixed an overlooked issue in the nancy7 save menu where
just clicking the save button without entering a new name
would default the save back to the ScummVM-generated
default name.
Changed paths:
engines/nancy/state/loadsave.cpp
diff --git a/engines/nancy/state/loadsave.cpp b/engines/nancy/state/loadsave.cpp
index 4d8911a80dc..7db120b0d12 100644
--- a/engines/nancy/state/loadsave.cpp
+++ b/engines/nancy/state/loadsave.cpp
@@ -522,6 +522,8 @@ void LoadSaveMenu::save() {
}
finalDesc = _loadSaveData->_defaultSaveNamePrefix + ('0' + suffixNum);
+ } else {
+ finalDesc = _filenameStrings[_selectedSave];
}
} else {
if (!_filenameStrings[_selectedSave].equals(g_nancy->getStaticData().emptySaveText)) {
Commit: 999048d0d2b940e1be65263290363041203ad20b
https://github.com/scummvm/scummvm/commit/999048d0d2b940e1be65263290363041203ad20b
Author: Kaloyan Chehlarski (strahy at outlook.com)
Date: 2024-01-09T23:06:48+01:00
Commit Message:
NANCY: Ensure cursor is drawn after launcher load
Fixed an issue where, if a save is loaded through the
ScummVM launcher, the cursor would only become visible
the first time it changes, e.g. when the player moves it
outside the viewport.
Changed paths:
engines/nancy/cursor.cpp
diff --git a/engines/nancy/cursor.cpp b/engines/nancy/cursor.cpp
index 2bf89968474..7b3ad5862ba 100644
--- a/engines/nancy/cursor.cpp
+++ b/engines/nancy/cursor.cpp
@@ -35,7 +35,7 @@ CursorManager::CursorManager() :
_curItemID(-1),
_curCursorType(kNormal),
_curCursorID(0),
- _lastCursorID(0),
+ _lastCursorID(10000), // nonsense default value to ensure cursor is drawn the first time
_hasItem(false),
_numCursorTypes(0),
_puzzleExitCursor((g_nancy->getGameType() >= kGameTypeNancy4) ? kMoveBackward : kExit),
More information about the Scummvm-git-logs
mailing list