aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/mads/player.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/mads/player.cpp b/engines/mads/player.cpp
index 3eb6b118d7..b337f8ada0 100644
--- a/engines/mads/player.cpp
+++ b/engines/mads/player.cpp
@@ -263,7 +263,7 @@ void Player::update() {
scene._spriteSlots[slotIndex]._flags = IMG_ERASE;
int newDepth = 1;
- int yp = MAX(_playerPos.y, (int16)(MADS_SCENE_HEIGHT - 1));
+ int yp = MIN(_playerPos.y, (int16)(MADS_SCENE_HEIGHT - 1));
for (int idx = 1; idx < 15; ++idx) {
if (scene._sceneInfo->_depthList[newDepth] >= yp)