1
Fork 0
mirror of https://github.com/thegeneralist01/Scene-Manager-DevRepo synced 2026-01-11 15:40:29 +01:00

Changed DistanceTo method to DistanceTo2D in GetNearbyVehicles

This commit is contained in:
Rich Dunne 2020-08-27 15:56:29 -06:00
parent 95f65c792c
commit a103d9be67

View file

@ -81,7 +81,7 @@ namespace SceneManager
private static Vehicle[] GetNearbyVehicles(Vector3 collectorPosition, float collectorRadius)
{
return (from v in World.GetAllVehicles() where v.DistanceTo(collectorPosition) <= collectorRadius && v.IsValidForCollection() select v).ToArray();
return (from v in World.GetAllVehicles() where v.DistanceTo2D(collectorPosition) <= collectorRadius && v.IsValidForCollection() select v).ToArray();
}
private static void AssignStopForVehiclesFlag(List<Path> paths, Path path, Waypoint waypointData)