diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/kyra/screen.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/engines/kyra/screen.cpp b/engines/kyra/screen.cpp index fda2c52ad7..4e7f391ce9 100644 --- a/engines/kyra/screen.cpp +++ b/engines/kyra/screen.cpp @@ -1413,7 +1413,7 @@ void Screen::drawShape(uint8 pageNum, const uint8 *shapeData, int x, int y, int uint8 *d = dst; - while (shapeHeight--) { + while (true) { bool normalPlot = true; if (flags & 0x800) normalPlot = (curY > _maskMinY && curY < _maskMaxY); @@ -1447,7 +1447,9 @@ void Screen::drawShape(uint8 pageNum, const uint8 *shapeData, int x, int y, int dst += dsPitch; d = dst; ++curY; - scaleCounterV -= 256; + if (!--shapeHeight) + return; + scaleCounterV -= 0x100; } while (scaleCounterV & 0xff00); } |