aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlyssa Milburn2011-02-20 13:42:40 +0100
committerAlyssa Milburn2011-02-20 13:45:33 +0100
commit9fa6b48e1ae574c0af5be3ed2f9815c3d98be655 (patch)
tree622d290d95abe75efe736e43161b903ee56e75b3
parent2f312e9e1a5a577ebf167ba004ffea19a767c7de (diff)
downloadscummvm-rg350-9fa6b48e1ae574c0af5be3ed2f9815c3d98be655.tar.gz
scummvm-rg350-9fa6b48e1ae574c0af5be3ed2f9815c3d98be655.tar.bz2
scummvm-rg350-9fa6b48e1ae574c0af5be3ed2f9815c3d98be655.zip
MOHAWK: A zero matchFrom matches everything.
-rw-r--r--engines/mohawk/livingbooks.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/mohawk/livingbooks.cpp b/engines/mohawk/livingbooks.cpp
index cc38adb34f..4fa69e83a4 100644
--- a/engines/mohawk/livingbooks.cpp
+++ b/engines/mohawk/livingbooks.cpp
@@ -1880,8 +1880,8 @@ LBScriptEntry *LBItem::parseScriptEntry(uint16 type, uint16 &size, Common::Seeka
error("not enough bytes (%d) in kLBEventNotified, opcode 0x%04x", size, entry->opcode);
entry->matchFrom = stream->readUint16();
entry->matchNotify = stream->readUint16();
- debug(4, "kLBEventNotified: unknowns %04x, %04x",
- entry->matchFrom, entry->matchNotify);
+ debug(4, "kLBEventNotified: matches %04x (from %04x)",
+ entry->matchNotify, entry->matchFrom);
size -= 4;
}
@@ -2289,7 +2289,7 @@ void LBItem::runScript(uint event, uint16 data, uint16 from) {
continue;
if (event == kLBEventNotified) {
- if (entry->matchFrom != from || entry->matchNotify != data)
+ if ((entry->matchFrom && entry->matchFrom != from) || entry->matchNotify != data)
continue;
}