mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-27 13:42:02 +00:00
SHERLOCK: Add missing check for the rightmost limit in adjustSprite
This commit is contained in:
parent
eb5579df54
commit
e3d6b25d57
@ -247,6 +247,11 @@ void Sprite::adjustSprite() {
|
||||
_position.x = LEFT_LIMIT * FIXED_INT_MULTIPLIER;
|
||||
people.gotoStand(*this);
|
||||
}
|
||||
|
||||
if ((_position.x / FIXED_INT_MULTIPLIER) > RIGHT_LIMIT) {
|
||||
_position.x = RIGHT_LIMIT * FIXED_INT_MULTIPLIER;
|
||||
people.gotoStand(*this);
|
||||
}
|
||||
} else if (!map._active) {
|
||||
_position.y = CLIP((int)_position.y, (int)UPPER_LIMIT, (int)LOWER_LIMIT);
|
||||
_position.x = CLIP((int)_position.x, (int)LEFT_LIMIT, (int)RIGHT_LIMIT);
|
||||
|
Loading…
x
Reference in New Issue
Block a user