mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Avoid zero-division exception
This commit is contained in:
parent
789806637c
commit
4901443b7a
@ -302,6 +302,9 @@ class FlightPlanBuilder:
|
||||
else:
|
||||
return "-"
|
||||
|
||||
if (waypoint.tot - last_time).total_seconds() == 0.0:
|
||||
return "-"
|
||||
|
||||
speed = mps(
|
||||
self.last_waypoint.position.distance_to_point(waypoint.position)
|
||||
/ (waypoint.tot - last_time).total_seconds()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user