aboutsummaryrefslogtreecommitdiff
path: root/scumm/script_v8.cpp
diff options
context:
space:
mode:
authorJames Brown2003-01-14 11:59:39 +0000
committerJames Brown2003-01-14 11:59:39 +0000
commite0d2d9f7a04f7f1281ba70abe33f3bae6f3fc772 (patch)
tree6d073e146f1fd71c1764131c15b0056bf15a6358 /scumm/script_v8.cpp
parent8fa54025623977dfa23bc1ff0801f1bb1a954d21 (diff)
downloadscummvm-rg350-e0d2d9f7a04f7f1281ba70abe33f3bae6f3fc772.tar.gz
scummvm-rg350-e0d2d9f7a04f7f1281ba70abe33f3bae6f3fc772.tar.bz2
scummvm-rg350-e0d2d9f7a04f7f1281ba70abe33f3bae6f3fc772.zip
Fix inventory in vscroll'ing rooms
svn-id: r6455
Diffstat (limited to 'scumm/script_v8.cpp')
-rw-r--r--scumm/script_v8.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/scumm/script_v8.cpp b/scumm/script_v8.cpp
index 2f7c38e802..7ecd004fc6 100644
--- a/scumm/script_v8.cpp
+++ b/scumm/script_v8.cpp
@@ -1474,20 +1474,21 @@ void Scumm_v8::o8_kernelGetFunctions()
warning("o8_kernelGetFunctions: default case 0x%x (len = %d)", args[0], len);
break;
case 0xD8: { // findBlastObject
+ int x = args[1] + (camera._cur.x & 7);
+ int y = args[2] + (camera._cur.y - (_realHeight /2));;
BlastObject *eo;
- int i;
- for (i = _enqueuePos; i >= 0; i--) {
+ for (int i = _enqueuePos; i >= 0; i--) {
eo = &_enqueuedObjects[i];
- if (eo->posX <= args[1] && eo->width + eo->posX > args[1] &&
- eo->posY <= args[2] && eo->height + eo->posY > args[2]) {
+
+ if (eo->posX <= x && eo->width + eo->posX > x &&
+ eo->posY <= y && eo->height + eo->posY > y) {
if (!getClass(eo->number, 32)) {
push(eo->number);
return;
}
}
}
-
push(0);
break;
}