1
0
Fork 0

AI improved entry into parking (heading and postition)

This commit is contained in:
portree_kid 2022-02-13 20:34:17 +01:00
parent 49eeb6627c
commit b216658ba1

View file

@ -1157,26 +1157,39 @@ bool FGAIFlightPlan::createParking(FGAIAircraft * ac, FGAirport * apt,
SGGeodesy::direct(parking->geod(), reverseHeading, 2 * parking->getRadius(), SGGeodesy::direct(parking->geod(), reverseHeading, 2 * parking->getRadius(),
pos, az); pos, az);
wpt = createOnGround(ac, "parking", pos, aptElev, vTaxiReduced/2); wpt = createOnGround(ac, "parking1", pos, aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt); pushBackWaypoint(wpt);
SGGeodesy::direct(parking->geod(), reverseHeading, 1.5 * parking->getRadius(), SGGeodesy::direct(parking->geod(), reverseHeading, 1 * parking->getRadius(),
pos, az); pos, az);
wpt = createOnGround(ac, "parking2", pos, aptElev, vTaxiReduced/3); wpt = createOnGround(ac, "parking2", pos, aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt); pushBackWaypoint(wpt);
SGGeodesy::direct(parking->geod(), reverseHeading, parking->getRadius(), SGGeodesy::direct(parking->geod(), reverseHeading, 0.6 * parking->getRadius(),
pos, az); pos, az);
wpt = createOnGround(ac, "parking3", pos, aptElev, vTaxiReduced/3); wpt = createOnGround(ac, "parking3", pos, aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt); pushBackWaypoint(wpt);
char buffer[30]; SGGeodesy::direct(parking->geod(), reverseHeading, 0.3 * parking->getRadius(),
snprintf(buffer, 30, "Parking%s", parking->getName().c_str()); pos, az);
wpt = createOnGround(ac, "parking4", pos, aptElev, vTaxiReduced/3);
wpt = createOnGround(ac, buffer, parking->geod(), aptElev,
2);
pushBackWaypoint(wpt); pushBackWaypoint(wpt);
SGGeodesy::direct(parking->geod(), parking->getHeading(), 1,
SGGeodesy::direct(parking->geod(), reverseHeading, 0.2 * parking->getRadius(),
pos, az);
wpt = createOnGround(ac, "parking5", pos, aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt);
char buffer[30];
snprintf(buffer, sizeof(buffer), "Parking%s", parking->getName().c_str());
wpt = createOnGround(ac, buffer, parking->geod(), aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt);
SGGeodesy::direct(parking->geod(), parking->getHeading(), 2,
pos, az);
wpt = createOnGround(ac, "Beyond-Parking", pos, aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt);
SGGeodesy::direct(parking->geod(), parking->getHeading(), 3,
pos, az); pos, az);
wpt = createOnGround(ac, "END-Parking", pos, aptElev, vTaxiReduced/3); wpt = createOnGround(ac, "END-Parking", pos, aptElev, vTaxiReduced/3);
pushBackWaypoint(wpt); pushBackWaypoint(wpt);