DCS task orbit

From DCS World Wiki - Hoggitworld.com


Task: Orbit Added with: 1.2.4
Hierarchy: Scripting Root > Tasks > Main task > Orbit
Tasking Type: Main task
For: Airplanes, Helicopters
Available Under: All aircraft tasks
Description: Orders an aircraft group to orbit at the waypoint.
Format: This task needs to be in the following format.
Orbit = { 
 id = 'Orbit', 
 params = { 
   pattern = enum AI.Task.OribtPattern,
   point = Vec2,
   point2 = Vec2,
   speed = Distance,
   altitude = Distance
 } 
}


Required parameters: pattern: defines the type of orbit pattern the AI will execute.

Optional Parameters: All other variables are optional.

point: vec2 point for which the orbit will originate from. If not defined the position of their current waypoint will be used.

point2: vec2 second point for a Race-Rrack orbit pattern. If not defined the next waypoint position will be used.

speed: Speed in meters per second the AI will orbit at. If no speed is defined then the AI will orbit at 1.5 their stall speed.

altitude: Altitude in meters the AI will orbit at. If not defined the altitude of their current waypoint will be used.

Enumerators: AI.Task.OrbitPattern
"RACE_TRACK" = "Race-Track"
"CIRCLE"     = "Circle"
Examples: The following example uses mist functions to make an aircraft group named "Reaper" orbit at the average position of a group named "arty"
 local orbit = {
   id = 'Orbit', 
     params = { 
       pattern = 'Circle',
       point = mist.utils.makeVec2(mist.getAvgPos(mist.makeUnitTable({'[g]arty'}))),
       speed = 200,
       altitude = 8000,
   } 
 }
 Group.getByName('Reaper'):getController():pushTask(orbit)
Notes: See article Mission Editor: AI Tasking for more information on how AI tasking is handled within DCS.
Task List: Main Tasks: mission, AttackGroup, AttackUnit, Bombing, CarpetBombing, AttackMapObject, BombingRunway, orbit, refueling, land, follow, followBigFormation, escort, Embarking, fireAtPoint, hold, FAC_AttackGroup, EmbarkToTransport, DisembarkFromTransport, CargoTransportation, goToWaypoint

En-route Tasks: engageTargets, engageTargetsInZone, engageGroup, engageUnit, awacs, tanker, ewr, FAC_engageGroup, FAC

Commands: script, setCallsign, setFrequency, switchWaypoint, stopRoute, switchAction, setInvisible, setImmortal, activateBeacon, deactivateBeacon, eplrs, start, transmitMessage, stopTransmission

Options: ROE, Reaction To Threat, Radar Using, Flare Using, Formation, RTB On Bingo, silence, Disperse on Attack, Alarm State, RTB on Out of Ammo, ECM Using, Prohibit AA, Prohibit Jettison, Prohibit Afterburner, Prohibit AG, Missile Attack Range, Prohibit WP Pass Report, Engage Air Weapons