Renamed SpeedHelper.GetMaxSpeed to GetTheoreticalMaxSpeed for distinction with Way.GetMaxSpeed
This commit is contained in:
parent
271d84f13f
commit
d82efdf973
@ -30,7 +30,7 @@ namespace astar
|
|||||||
endNode.Value.Metric = 0f;
|
endNode.Value.Metric = 0f;
|
||||||
|
|
||||||
double totalDistance = NodeUtils.DistanceBetween(startNode.Value, endNode.Value);
|
double totalDistance = NodeUtils.DistanceBetween(startNode.Value, endNode.Value);
|
||||||
PriorityHelper priorityHelper = new(totalDistance, SpeedHelper.GetMaxSpeed(car));
|
PriorityHelper priorityHelper = new(totalDistance, SpeedHelper.GetTheoreticalMaxSpeed(car));
|
||||||
|
|
||||||
logger?.Log(LogLevel.Information,
|
logger?.Log(LogLevel.Information,
|
||||||
"From {0:00.00000}#{1:000.00000} to {2:00.00000}#{3:000.00000} Great-Circle {4:00000.00}km",
|
"From {0:00.00000}#{1:000.00000} to {2:00.00000}#{3:000.00000} Great-Circle {4:00000.00}km",
|
||||||
|
@ -13,7 +13,7 @@ internal static class SpeedHelper
|
|||||||
return car ? SpeedCar[highwayType] : SpeedPedestrian[highwayType];
|
return car ? SpeedCar[highwayType] : SpeedPedestrian[highwayType];
|
||||||
}
|
}
|
||||||
|
|
||||||
public static byte GetMaxSpeed(bool car = true)
|
public static byte GetTheoreticalMaxSpeed(bool car = true)
|
||||||
{
|
{
|
||||||
return car ? SpeedCar.MaxBy(s => s.Value).Value : SpeedPedestrian.MaxBy(s => s.Value).Value;
|
return car ? SpeedCar.MaxBy(s => s.Value).Value : SpeedPedestrian.MaxBy(s => s.Value).Value;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user