Quellcode durchsuchen

add the remaining distance

Sven Czarnian vor 3 Jahren
Ursprung
Commit
ffb944fd6d
1 geänderte Dateien mit 3 neuen und 0 gelöschten Zeilen
  1. 3 0
      src/types/Inbound.cpp

+ 3 - 0
src/types/Inbound.cpp

@@ -268,6 +268,9 @@ int Inbound::matchToPredictedPath(const EuroScopePlugIn::CFlightPlanPositionPred
         lastPosition = coordinate;
     }
 
+    /* add the last step to the correct position */
+    trackmiles += lastPosition.distanceTo(position);
+
     return static_cast<int>(idx);
 }