Merge pull request #1723 from GriffinRichards/fix-impassable

MapGridIsImpassableAt -> MapGridGetCollisionAt, and add fixes
This commit is contained in:
GriffinR
2022-08-10 21:28:14 -04:00
committed by GitHub
7 changed files with 22 additions and 12 deletions

View File

@@ -874,7 +874,12 @@ static s32 RotatingGate_CanRotate(u8 gateId, s32 rotationDirection)
if (sRotatingGate_ArmLayout[shape][2 * i + j])
{
if (MapGridIsImpassableAt(x + armPos[armIndex].x, y + armPos[armIndex].y) == TRUE)
#ifdef BUGFIX
// Collision has a range 0-3, any value != 0 is impassable
if (MapGridGetCollisionAt(x + armPos[armIndex].x, y + armPos[armIndex].y))
#else
if (MapGridGetCollisionAt(x + armPos[armIndex].x, y + armPos[armIndex].y) == 1)
#endif
return FALSE;
}
}