mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-19 08:06:42 +00:00
ACCESS: Fix initialisation of Y positioning in rooms with vertical scrolling
This commit is contained in:
parent
a7d88af24d
commit
fb686191a8
@ -267,14 +267,15 @@ void Room::setupRoom() {
|
||||
screen._scrollRow = 0;
|
||||
} else {
|
||||
screen._scrollY = _vm->_player->_rawPlayer.y -
|
||||
(_vm->_player->_rawPlayer.y >> 4);
|
||||
int yp = MAX((_vm->_player->_rawPlayer.y >> 4) -
|
||||
(_vm->_player->_rawPlayer.y / 16) * 16;
|
||||
int yc = MAX((_vm->_player->_rawPlayer.y >> 4) -
|
||||
(screen._vWindowHeight / 2), 0);
|
||||
screen._scrollRow = yp;
|
||||
screen._scrollRow = yc;
|
||||
|
||||
yp = yp + screen._vWindowHeight - _playFieldHeight;
|
||||
if (yp >= 0) {
|
||||
screen._scrollRow = yp + 1;
|
||||
yc = yc + screen._vWindowHeight - _playFieldHeight;
|
||||
if (yc >= 0) {
|
||||
screen._scrollRow = _playFieldHeight - screen._vWindowHeight;
|
||||
screen._scrollY = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user