Improve method name for level crossing check

This commit is contained in:
Rik Smeets 2022-10-09 11:01:10 +02:00
parent bba54d2ecc
commit 7c2ec714f7
4 changed files with 6 additions and 6 deletions

View File

@ -5289,7 +5289,7 @@ void Guest::UpdateWalking()
}
}
if (PathIsBlockedByVehicle())
if (ShouldWaitForLevelCrossing())
{
// Wait for vehicle to pass
return;

View File

@ -321,7 +321,7 @@ bool Peep::CheckForPath()
return false;
}
bool Peep::PathIsBlockedByVehicle()
bool Peep::ShouldWaitForLevelCrossing()
{
auto curPos = TileCoordsXYZ(GetLocation());
if (FootpathIsBlockedByVehicle(curPos))

View File

@ -412,7 +412,7 @@ public: // Peep
// TODO: Make these private again when done refactoring
public: // Peep
[[nodiscard]] bool CheckForPath();
bool PathIsBlockedByVehicle();
bool ShouldWaitForLevelCrossing();
bool IsOnLevelCrossing();
void PerformNextAction(uint8_t& pathing_result);
void PerformNextAction(uint8_t& pathing_result, TileElement*& tile_result);

View File

@ -1338,7 +1338,7 @@ void Staff::UpdateHeadingToInspect()
if (!CheckForPath())
return;
if (PathIsBlockedByVehicle() && !IsMechanicHeadingToFixRideBlockingPath())
if (ShouldWaitForLevelCrossing() && !IsMechanicHeadingToFixRideBlockingPath())
return;
uint8_t pathingResult;
@ -1446,7 +1446,7 @@ void Staff::UpdateAnswering()
if (!CheckForPath())
return;
if (PathIsBlockedByVehicle() && !IsMechanicHeadingToFixRideBlockingPath())
if (ShouldWaitForLevelCrossing() && !IsMechanicHeadingToFixRideBlockingPath())
return;
uint8_t pathingResult;
@ -1781,7 +1781,7 @@ void Staff::UpdatePatrolling()
if (!CheckForPath())
return;
if (PathIsBlockedByVehicle() && !IsMechanicHeadingToFixRideBlockingPath())
if (ShouldWaitForLevelCrossing() && !IsMechanicHeadingToFixRideBlockingPath())
return;
uint8_t pathingResult;