Fix flightplan initialization issue.
This commit is contained in:
parent
87bd2bfd6e
commit
dbceffeae8
2 changed files with 4 additions and 1 deletions
|
@ -452,8 +452,10 @@ bool FGAIFlightPlan::createTakeOff(FGAIAircraft * ac, bool firstFlight,
|
||||||
double heading = ac->getTrafficRef()->getCourse();
|
double heading = ac->getTrafficRef()->getCourse();
|
||||||
apt->getDynamics()->getActiveRunway(rwyClass, 1, activeRunway,
|
apt->getDynamics()->getActiveRunway(rwyClass, 1, activeRunway,
|
||||||
heading);
|
heading);
|
||||||
rwy = apt->getRunwayByIdent(activeRunway);
|
|
||||||
}
|
}
|
||||||
|
rwy = apt->getRunwayByIdent(activeRunway);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
double airportElev = apt->getElevation();
|
double airportElev = apt->getElevation();
|
||||||
// Acceleration point, 105 meters into the runway,
|
// Acceleration point, 105 meters into the runway,
|
||||||
|
|
|
@ -118,6 +118,7 @@ void FGATCManager::init() {
|
||||||
fgSetDouble("/instrumentation/comm[0]/frequencies/selected-mhz", ((double) stationFreq / 100.0));
|
fgSetDouble("/instrumentation/comm[0]/frequencies/selected-mhz", ((double) stationFreq / 100.0));
|
||||||
leg = 4;
|
leg = 4;
|
||||||
string fltType = "ga";
|
string fltType = "ga";
|
||||||
|
fp->setRunway(runway);
|
||||||
fp->createTakeOff(&ai_ac, false, apt, 0, fltType);
|
fp->createTakeOff(&ai_ac, false, apt, 0, fltType);
|
||||||
} else {
|
} else {
|
||||||
controller = apt->getDynamics()->getStartupController();
|
controller = apt->getDynamics()->getStartupController();
|
||||||
|
|
Loading…
Reference in a new issue