aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTravis Howell2009-10-27 12:08:19 +0000
committerTravis Howell2009-10-27 12:08:19 +0000
commitba979cbd565f152b7a1d657f23cce5417d8b2205 (patch)
tree4017f8209036e096e4590298cc461798d1b5db24
parent26948eca76ff1abc020bbd6a2b98eb1c5c456ff5 (diff)
downloadscummvm-rg350-ba979cbd565f152b7a1d657f23cce5417d8b2205.tar.gz
scummvm-rg350-ba979cbd565f152b7a1d657f23cce5417d8b2205.tar.bz2
scummvm-rg350-ba979cbd565f152b7a1d657f23cce5417d8b2205.zip
Add patch #2856940 - MM C64: corner walkboxes fixed.
svn-id: r45438
-rw-r--r--engines/scumm/actor.cpp2
-rw-r--r--engines/scumm/boxes.cpp10
2 files changed, 12 insertions, 0 deletions
diff --git a/engines/scumm/actor.cpp b/engines/scumm/actor.cpp
index 4fde436e2f..443c66034e 100644
--- a/engines/scumm/actor.cpp
+++ b/engines/scumm/actor.cpp
@@ -1536,6 +1536,8 @@ void Actor::prepareDrawActorCostume(BaseCostumeRenderer *bcr) {
bcr->_zbuf = 0;
else {
bcr->_zbuf = _vm->getMaskFromBox(_walkbox);
+ if (_vm->_game.version == 0)
+ bcr->_zbuf &= 0x03;
if (bcr->_zbuf > _vm->_gdi->_numZBuffer-1)
bcr->_zbuf = _vm->_gdi->_numZBuffer-1;
}
diff --git a/engines/scumm/boxes.cpp b/engines/scumm/boxes.cpp
index 65e32e0a2c..dc6f10696f 100644
--- a/engines/scumm/boxes.cpp
+++ b/engines/scumm/boxes.cpp
@@ -613,6 +613,16 @@ BoxCoords ScummEngine::getBoxCoordinates(int boxnum) {
box->ll.y = bp->c64.y2;
box->lr.x = bp->c64.x2;
box->lr.y = bp->c64.y2;
+
+ if (bp->c64.mask & 0x88) {
+ // walkbox for (right/left) corner
+ // TODO: ladders (incl. man-eating plant) have mask 0x8A,
+ // must those walkboxes be adjusted?
+ if (bp->c64.mask & 0x04)
+ box->ur = box->ul;
+ else
+ box->ul = box->ur;
+ }
} else if (_game.version <= 2) {
box->ul.x = bp->v2.ulx;
box->ul.y = bp->v2.uy;