浏览代码

fix a system crash

Sven Czarnian 3 年之前
父节点
当前提交
8d196129f0
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      aman/sys/RecedingHorizonControl.py

+ 2 - 2
aman/sys/RecedingHorizonControl.py

@@ -138,7 +138,7 @@ class RecedingHorizonControl:
                 node = Node(inbound, None, None, None, None)
 
                 if inbound.PlannedRunway.Name in runwayInbounds:
-                    if None == runwayInbounds[inbound.PlannedRunway.Name] or runwayInbounds[inbound.PlannedRunway.Name].EstimatedTouchdownTime < node.EstimatedTouchdownTime:
+                    if None == runwayInbounds[inbound.PlannedRunway.Name] or runwayInbounds[inbound.PlannedRunway.Name].Inbound.PlannedArrivalTime < node.Inbound.PlannedArrivalTime:
                         runwayInbounds[inbound.PlannedRunway.Name] = node
 
                 if inbound.PlannedArrivalRoute[0].Waypoint.Name in iafInbounds:
@@ -152,7 +152,7 @@ class RecedingHorizonControl:
 
                     if None == iafInbounds[inbound.PlannedArrivalRoute[0].Waypoint.Name][targetLevel]:
                         iafInbounds[inbound.PlannedArrivalRoute[0].Waypoint.Name][targetLevel] = node
-                    elif iafInbounds[inbound.PlannedArrivalRoute[0].Waypoint.Name][targetLevel].EstimatedIafTime < node.EstimatedIafTime:
+                    elif iafInbounds[inbound.PlannedArrivalRoute[0].Waypoint.Name][targetLevel].Inbound.PlannedArrivalTime < node.Inbound.PlannedArrivalTime:
                         iafInbounds[inbound.PlannedArrivalRoute[0].Waypoint.Name][targetLevel] = node
 
         return runwayInbounds, iafInbounds