From 06066565a6fc55d3715abc1821dd193d092920a6 Mon Sep 17 00:00:00 2001 From: Robert Göffringmann Date: Thu, 21 Oct 2004 05:18:06 +0000 Subject: fixes bug #786482, stupid gardener getting stuck in his hacky animation script. svn-id: r15623 --- sky/logic.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'sky') diff --git a/sky/logic.cpp b/sky/logic.cpp index 2eb9cd7879..e10a155ad7 100644 --- a/sky/logic.cpp +++ b/sky/logic.cpp @@ -1372,6 +1372,21 @@ bool Logic::fnDrawScreen(uint32 a, uint32 b, uint32 c) { debug(5, "Call: fnDrawScreen(%X, %X)",a,b); SkyEngine::_systemVars.currentPalette = a; _skyScreen->fnDrawScreen(a, b); + + if (Logic::_scriptVariables[SCREEN] == 32) { + /* workaround for script bug #786482 + Under certain circumstances, which never got completely cleared, + the gardener can get stuck in an animation, waiting for a sync + signal from foster. + This is most probably caused by foster leaving the screen before + sending the sync. + To work around that, we simply send a sync to the gardener every time + we enter the screen. If he isn't stuck (and thus not waiting for sync) + it will be ignored anyways */ + + debug(1, "sending gardener sync"); + fnSendSync(ID_SC32_GARDENER, 1, 0); + } return true; } -- cgit v1.2.3