[Scummvm-git-logs] scummvm master -> cf9010cd54a5c55d8613de8248d2bcb4205a7ded
tnm23
noreply at scummvm.org
Wed Aug 27 18:04:22 UTC 2025
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
7729891f2b ZVISION: Ensure cursor behaves correctly if already over a hotspot when changing to a new location.
cf9010cd54 ZVISION: Remove redundant cursor debug messages, combine into one.
Commit: 7729891f2b8dde615ba3fa1b70aabf8a5c28f933
https://github.com/scummvm/scummvm/commit/7729891f2b8dde615ba3fa1b70aabf8a5c28f933
Author: Thomas N McEwan (46427621+tnm23 at users.noreply.github.com)
Date: 2025-08-27T19:03:59+01:00
Commit Message:
ZVISION: Ensure cursor behaves correctly if already over a hotspot when changing to a new location.
Changed paths:
engines/zvision/scripting/script_manager.cpp
engines/zvision/zvision.h
diff --git a/engines/zvision/scripting/script_manager.cpp b/engines/zvision/scripting/script_manager.cpp
index 2f9904fe1c6..496dbab889e 100644
--- a/engines/zvision/scripting/script_manager.cpp
+++ b/engines/zvision/scripting/script_manager.cpp
@@ -761,6 +761,9 @@ void ScriptManager::ChangeLocationReal(bool isLoading) {
}
_engine->getRenderManager()->checkBorders();
+
+ _engine->onMouseMove(); // Trigger a pseudo mouse movement to change cursor if we enter the new location with it already over a hotspot
+
debugC(1, kDebugScript, "\tLocation change complete");
}
diff --git a/engines/zvision/zvision.h b/engines/zvision/zvision.h
index 6ddbfd77cd3..2bb22828419 100644
--- a/engines/zvision/zvision.h
+++ b/engines/zvision/zvision.h
@@ -23,8 +23,9 @@
#ifndef ZVISION_ZVISION_H
#define ZVISION_ZVISION_H
-#include "common/random.h"
#include "common/events.h"
+#include "common/random.h"
+#include "common/system.h"
#include "engines/engine.h"
#include "graphics/pixelformat.h"
#include "gui/debugger.h"
@@ -76,7 +77,7 @@ struct ScreenLayout {
};
// NB Footage of original DOS Nemesis engine indicates playfield was centrally placed on screen.
-// Subtitle scripts, however, suggest playfield was higher up, otherwise they run off the bottom of the screen.
+// Subtitle scripts, however, suggest playfield was higher up, otherwise they run off the bottom of the screen.
// This could just be an error in the scripts or an artefact of the original game's development, so we will continue to use as-released central placement.
static const ScreenLayout nemesisLayout {
@@ -270,7 +271,7 @@ public:
void saveSettings();
bool quit(bool askFirst = true, bool streaming = false);
-
+
// Engine features
bool hasFeature(EngineFeature f) const override;
bool canLoadGameStateCurrently(Common::U32String *msg = nullptr) override;
@@ -278,10 +279,15 @@ public:
Common::Error loadGameState(int slot) override;
Common::Error saveGameState(int slot, const Common::String &desc, bool isAutosave = false) override;
+ // Used to update cursor on a location change
+ void onMouseMove() {
+ onMouseMove(_system->getEventManager()->getMousePos());
+ }
+
private:
void initialize();
void initFonts();
-
+
void initializePath(const Common::FSNode &gamePath) override;
void parseStrFile(const Common::String &fileName);
Commit: cf9010cd54a5c55d8613de8248d2bcb4205a7ded
https://github.com/scummvm/scummvm/commit/cf9010cd54a5c55d8613de8248d2bcb4205a7ded
Author: Thomas N McEwan (46427621+tnm23 at users.noreply.github.com)
Date: 2025-08-27T19:03:59+01:00
Commit Message:
ZVISION: Remove redundant cursor debug messages, combine into one.
Changed paths:
engines/zvision/scripting/menu.cpp
engines/zvision/scripting/script_manager.cpp
diff --git a/engines/zvision/scripting/menu.cpp b/engines/zvision/scripting/menu.cpp
index 6967b61dcb8..727f44de1a2 100644
--- a/engines/zvision/scripting/menu.cpp
+++ b/engines/zvision/scripting/menu.cpp
@@ -117,8 +117,6 @@ void MenuManager::onMouseDown(const Common::Point &pos) {
_redraw = true;
}
}
- debugC(kDebugMouse, "mouse position %d %d", pos.x, pos.y);
- debugC(kDebugMouse, "panorama position %d %d", pos.x, pos.y);
}
void MenuManager::onMouseMove(const Common::Point &pos) {
diff --git a/engines/zvision/scripting/script_manager.cpp b/engines/zvision/scripting/script_manager.cpp
index 496dbab889e..b01c2129569 100644
--- a/engines/zvision/scripting/script_manager.cpp
+++ b/engines/zvision/scripting/script_manager.cpp
@@ -533,7 +533,7 @@ void ScriptManager::killSideFxType(ScriptingEffect::ScriptingEffectType type) {
}
void ScriptManager::onMouseDown(const Common::Point &screenSpacePos, const Common::Point &backgroundImageSpacePos) {
- debugC(1, kDebugMouse, "Mouse panorama/script coordinates %d x %d", backgroundImageSpacePos.x, backgroundImageSpacePos.y);
+ debugC(1, kDebugMouse, "Mouse screen coordinates: %d, %d, background/script coordinates: %d, %d", screenSpacePos.x, screenSpacePos.y, backgroundImageSpacePos.x, backgroundImageSpacePos.y);
if (!_activeControls) {
return;
}
More information about the Scummvm-git-logs
mailing list