aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilippos Karapetis2015-02-14 14:55:09 +0200
committerFilippos Karapetis2015-02-14 15:08:28 +0200
commit60c06b84b68a5711db442d8fd296f3978d685da5 (patch)
tree8e5fdb25f0bbe6e5183c8bced0fe5dc2e94d8983
parent14914b2a31399ceb6b2e4d7616535e346ee3acd6 (diff)
downloadscummvm-rg350-60c06b84b68a5711db442d8fd296f3978d685da5.tar.gz
scummvm-rg350-60c06b84b68a5711db442d8fd296f3978d685da5.tar.bz2
scummvm-rg350-60c06b84b68a5711db442d8fd296f3978d685da5.zip
ZVISION: Fix script bug #6794 - "ZVISION: Yoruk's coffin instant death"
Fixes an edge case where the player goes to the dark room with the grue without holding a torch, and then quickly runs away before the grue's sound effect finishes. Many thanks to eriktorbjorn for the original workaround
-rw-r--r--engines/zvision/scripting/actions.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/engines/zvision/scripting/actions.cpp b/engines/zvision/scripting/actions.cpp
index 5238561149..248ebaec49 100644
--- a/engines/zvision/scripting/actions.cpp
+++ b/engines/zvision/scripting/actions.cpp
@@ -480,6 +480,14 @@ ActionMusic::ActionMusic(ZVision *engine, int32 slotkey, const Common::String &l
}
_volume = new ValueSlot(engine->getScriptManager(), volumeBuffer);
}
+
+ // WORKAROUND for a script bug in Zork Nemesis, rooms mq70/mq80.
+ // Fixes an edge case where the player goes to the dark room with the grue
+ // without holding a torch, and then quickly runs away before the grue's
+ // sound effect finishes. Fixes script bug #6794.
+ if (engine->getGameId() == GID_NEMESIS && _slotKey == 14822 && engine->getScriptManager()->getStateValue(_slotKey) == 2)
+ engine->getScriptManager()->setStateValue(_slotKey, 0);
+
}
ActionMusic::~ActionMusic() {