aboutsummaryrefslogtreecommitdiff
path: root/engines/cine
diff options
context:
space:
mode:
authorTorbjörn Andersson2006-04-12 11:27:45 +0000
committerTorbjörn Andersson2006-04-12 11:27:45 +0000
commit9dfc4b5f6905ceae92a5009d3a2c8083167971e0 (patch)
treeb2a6f58f7df8aeeba70e57162956992fcc39ad3c /engines/cine
parenteb3ae7d7260f1cd2319e605e4b054d004733228c (diff)
downloadscummvm-rg350-9dfc4b5f6905ceae92a5009d3a2c8083167971e0.tar.gz
scummvm-rg350-9dfc4b5f6905ceae92a5009d3a2c8083167971e0.tar.bz2
scummvm-rg350-9dfc4b5f6905ceae92a5009d3a2c8083167971e0.zip
Fixed serious bug in removeOverlayElement() that would cause it to fail. This
caused getObjectUnderCursor() select the wrong object because the object list was no longer guaranteed to be sorted on priority ("mask"). In Future Wars, this made it difficult (impossible?) to pick up the tunic, because the game would pick the bushes instead, even though the tunic had a higher priority. svn-id: r21825
Diffstat (limited to 'engines/cine')
-rw-r--r--engines/cine/object.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/cine/object.cpp b/engines/cine/object.cpp
index 47fee00b25..80c4b1999c 100644
--- a/engines/cine/object.cpp
+++ b/engines/cine/object.cpp
@@ -105,7 +105,7 @@ int8 removeOverlayElement(uint16 objIdx, uint16 param) {
currentHeadPtr = tempHead->next;
- while (currentHeadPtr && (objIdx == currentHeadPtr->objIdx || param == currentHeadPtr->type)) {
+ while (currentHeadPtr && (objIdx != currentHeadPtr->objIdx || param != currentHeadPtr->type)) {
tempHead = currentHeadPtr;
currentHeadPtr = tempHead->next;
}