mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-16 06:39:17 +00:00
HDB: Fix player collision detection code
This commit is contained in:
parent
4c0181ac31
commit
252c6e61c9
@ -2064,7 +2064,8 @@ bool AI::checkPlayerCollision(int x, int y, int border) {
|
||||
if (g_hdb->getDebug() == 2 || !_player)
|
||||
return false;
|
||||
|
||||
return (x > (_player->x - 32 + border) && x < (_player->x - 32 - border) && y >(_player->y - 32 + border) && y < (_player->y - 32 - border));
|
||||
return (x > (_player->x - 32 + border) && x < (_player->x + 32 - border) &&
|
||||
y > (_player->y - 32 + border) && y < (_player->y + 32 - border));
|
||||
}
|
||||
|
||||
void AI::clearDiverters() {
|
||||
|
Loading…
Reference in New Issue
Block a user