aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/wage/gui.h1
-rw-r--r--engines/wage/wage.cpp12
2 files changed, 13 insertions, 0 deletions
diff --git a/engines/wage/gui.h b/engines/wage/gui.h
index cd918f7bd3..3c5660b4f2 100644
--- a/engines/wage/gui.h
+++ b/engines/wage/gui.h
@@ -72,6 +72,7 @@ public:
void mouseMove(int x, int y);
Designed *getClickTarget(int x, int y);
void drawInput();
+ void setSceneDirty() { _sceneDirty = true; }
private:
void paintBorder(Graphics::Surface *g, Common::Rect &r, WindowType windowType);
diff --git a/engines/wage/wage.cpp b/engines/wage/wage.cpp
index fa00618014..6cf9e39941 100644
--- a/engines/wage/wage.cpp
+++ b/engines/wage/wage.cpp
@@ -308,6 +308,18 @@ void WageEngine::onMove(Designed *what, Designed *from, Designed *to) {
return;
}
+ if (!_temporarilyHidden) {
+ assert(what);
+ assert(from);
+ assert(to);
+ debug(6, "move: %s, %s -> %s", what->_name.c_str(), from->_name.c_str(), to->_name.c_str());
+ }
+
+ if (from == currentScene || to == currentScene ||
+ (what->_classType == CHR && ((Chr *)what)->_currentScene == currentScene) ||
+ (what->_classType == OBJ && ((Obj *)what)->_currentScene == currentScene))
+ _gui->setSceneDirty();
+
if (what != player && what->_classType == CHR) {
Chr *chr = (Chr *)what;
if (to == _world->_storageScene) {