diff options
author | Martin Kiewitz | 2016-01-14 23:37:13 +0100 |
---|---|---|
committer | Martin Kiewitz | 2016-01-14 23:37:13 +0100 |
commit | 6269075ad67de618722e1c9e1e712950a749002b (patch) | |
tree | ee9cd9a8bfe7ee35bd2d28d69acd1a5aee8a7999 /engines | |
parent | ad1aac46ceda6e9c01d3f71994fcdd9b4080d96d (diff) | |
download | scummvm-rg350-6269075ad67de618722e1c9e1e712950a749002b.tar.gz scummvm-rg350-6269075ad67de618722e1c9e1e712950a749002b.tar.bz2 scummvm-rg350-6269075ad67de618722e1c9e1e712950a749002b.zip |
SCI: fix kernelCoordinateToPriority
do not check _priorityTop. Sierra never did it (I checked all sorts
of SCI versions, kq4 early, kq5, kq6, etc.) and checking it will
cause at least a priority issue in lsl2 in room 54 (airplane that
is taking off will be drawn using priority 1 instead of 0)
Diffstat (limited to 'engines')
-rw-r--r-- | engines/sci/graphics/ports.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/engines/sci/graphics/ports.cpp b/engines/sci/graphics/ports.cpp index bcc991081e..0d00ce01e6 100644 --- a/engines/sci/graphics/ports.cpp +++ b/engines/sci/graphics/ports.cpp @@ -717,8 +717,10 @@ void GfxPorts::kernelGraphAdjustPriority(int top, int bottom) { } byte GfxPorts::kernelCoordinateToPriority(int16 y) { - if (y < _priorityTop) - return _priorityBands[_priorityTop]; + if (y < 0) // Sierra did not check this, we do for safety reasons + return _priorityBands[0]; + // do NOT check for _priorityTop in here. Sierra never did that and it would cause + // at least priority issues in room 54 of lsl2 (airplane) if (y > _priorityBottom) return _priorityBands[_priorityBottom]; return _priorityBands[y]; |