From ffc3b480218052ec541a91431faa8ea158457faf Mon Sep 17 00:00:00 2001 From: Travis Howell Date: Sun, 5 Feb 2006 07:55:13 +0000 Subject: Revert back to original shadow detection. svn-id: r20391 --- scumm/akos.cpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'scumm/akos.cpp') diff --git a/scumm/akos.cpp b/scumm/akos.cpp index b886d8307d..52a50beb19 100644 --- a/scumm/akos.cpp +++ b/scumm/akos.cpp @@ -366,9 +366,6 @@ byte AkosRenderer::drawLimb(const Actor *a, int limb) { bool useCondMask; int lastDx, lastDy; - if (_vm->_heversion >= 90) - _shadow_mode = 0; - lastDx = lastDy = 0; for (i = 0; i < 32; ++i) { heCondMaskIndex[i] = i; @@ -467,10 +464,11 @@ byte AkosRenderer::drawLimb(const Actor *a, int limb) { _ymove -= lastDy; } + uint16 shadowMask = 0; + if (!useCondMask || !akct) { decflag = 1; } else { - uint16 shadowMask = 0; uint32 cond = READ_LE_UINT32(akct + cost.heCondMaskTable[limb] + heCondMaskIndex[i] * 4); if (cond == 0) { decflag = 1; @@ -490,9 +488,6 @@ byte AkosRenderer::drawLimb(const Actor *a, int limb) { } else { decflag = (a->_heCondMask & cond) ? 1 : 0; } - - if (_vm->_heversion >= 90 && (shadowMask & 0x8000) && xmap) - _shadow_mode = 3; } } @@ -501,6 +496,10 @@ byte AkosRenderer::drawLimb(const Actor *a, int limb) { if (decflag == 0) continue; + if (_vm->_heversion >= 90) { + _shadow_mode = ((shadowMask & 0x8000) && xmap) ? 3 : 0; + } + switch (codec) { case 1: result |= codec1(xmoveCur, ymoveCur); -- cgit v1.2.3