]> git.mxchange.org Git - flightgear.git/blobdiff - src/AIModel/AIFlightPlanCreateCruise.cxx
commradio: improvements for atis speech
[flightgear.git] / src / AIModel / AIFlightPlanCreateCruise.cxx
index 5807b9ae22c6c80495239b18bbdd9b259445c26a..709378f90013bc8d16d5278b4e21962b99f39f8d 100644 (file)
@@ -26,7 +26,7 @@
 #include <fstream>
 #include <iostream>
 
-#include <Airports/simple.hxx>
+#include <Airports/airport.hxx>
 #include <Airports/runways.hxx>
 #include <Airports/dynamics.hxx>
 
@@ -38,6 +38,7 @@
 #include "performancedata.hxx"
 
 using std::iostream;
+using std::string;
 
 /*
 void FGAIFlightPlan::evaluateRoutePart(double deplat,
@@ -295,7 +296,7 @@ bool FGAIFlightPlan::createCruise(FGAIAircraft *ac, bool firstFlight, FGAirport
   wpt = createInAir(ac, "Cruise", SGGeod::fromDeg(longitude, latitude), alt, vCruise);
   pushBackWaypoint(wpt); 
   
-  string rwyClass = getRunwayClassFromTrafficType(fltType);
+  const string& rwyClass = getRunwayClassFromTrafficType(fltType);
   double heading = ac->getTrafficRef()->getCourse();
   arr->getDynamics()->getActiveRunway(rwyClass, 2, activeRunway, heading);
   FGRunway* rwy = arr->getRunwayByIdent(activeRunway);