Explorar o código

fix a system crash

Sven Czarnian %!s(int64=3) %!d(string=hai) anos
pai
achega
8d196129f0
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  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