From 9e5f1d08d20e51cce579d62a007b4672aac36b4b Mon Sep 17 00:00:00 2001 From: Dan Albert Date: Sun, 9 Oct 2022 22:45:26 -0700 Subject: [PATCH] Add a comment explaining a wtf in alt estimation. --- game/ato/flightstate/navigating.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/game/ato/flightstate/navigating.py b/game/ato/flightstate/navigating.py index e8f4cde2..44603205 100644 --- a/game/ato/flightstate/navigating.py +++ b/game/ato/flightstate/navigating.py @@ -40,6 +40,11 @@ class Navigating(InFlight): ) def estimate_altitude(self) -> tuple[Distance, str]: + # This does not behave well when one of the waypoints is AGL and the other is + # MSL. We can't really avoid that problem though. We don't know where the ground + # is, so conversions between them are impossible, and we do need to use AGL + # altitudes for takeoff and landing waypoints (even if we had the runway + # elevation, we don't have elevation for FARPs). return ( meters( lerp(