mirror of
https://github.com/FlightControl-Master/MOOSE.git
synced 2025-10-29 16:58:06 +00:00
Merge branch 'develop' into FF/Develop
This commit is contained in:
@@ -14,12 +14,12 @@
|
||||
|
||||
--- @type CONTROLLABLE
|
||||
-- @extends Wrapper.Positionable#POSITIONABLE
|
||||
-- @field Dcs.DCSWrapper.Controllable#Controllable DCSControllable The DCS controllable class.
|
||||
-- @field DCS#Controllable DCSControllable The DCS controllable class.
|
||||
-- @field #string ControllableName The name of the controllable.
|
||||
|
||||
|
||||
|
||||
--- CONTROLLABLE is a wrapper class to handle the "DCS Controllable objects", which are Groups and Units:
|
||||
--- Wrapper class to handle the "DCS Controllable objects", which are Groups and Units:
|
||||
--
|
||||
-- * Support all DCS Controllable APIs.
|
||||
-- * Enhance with Controllable specific APIs not in the DCS Controllable API set.
|
||||
@@ -171,7 +171,7 @@ CONTROLLABLE = {
|
||||
|
||||
--- Create a new CONTROLLABLE from a DCSControllable
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSWrapper.Controllable#Controllable ControllableName The DCS Controllable name
|
||||
-- @param #string ControllableName The DCS Controllable name
|
||||
-- @return #CONTROLLABLE self
|
||||
function CONTROLLABLE:New( ControllableName )
|
||||
local self = BASE:Inherit( self, POSITIONABLE:New( ControllableName ) ) -- #CONTROLLABLE
|
||||
@@ -186,7 +186,7 @@ end
|
||||
|
||||
--- Get the controller for the CONTROLLABLE.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @return Dcs.DCSController#Controller
|
||||
-- @return DCS#Controller
|
||||
function CONTROLLABLE:_GetController()
|
||||
local DCSControllable = self:GetDCSObject()
|
||||
|
||||
@@ -396,13 +396,13 @@ end
|
||||
|
||||
--- Return a condition section for a controlled task.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTime#Time time
|
||||
-- @param DCS#Time time
|
||||
-- @param #string userFlag
|
||||
-- @param #boolean userFlagValue
|
||||
-- @param #string condition
|
||||
-- @param Dcs.DCSTime#Time duration
|
||||
-- @param DCS#Time duration
|
||||
-- @param #number lastWayPoint
|
||||
-- return Dcs.DCSTasking.Task#Task
|
||||
-- return DCS#Task
|
||||
function CONTROLLABLE:TaskCondition( time, userFlag, userFlagValue, condition, duration, lastWayPoint )
|
||||
self:F2( { time, userFlag, userFlagValue, condition, duration, lastWayPoint } )
|
||||
|
||||
@@ -420,9 +420,9 @@ end
|
||||
|
||||
--- Return a Controlled Task taking a Task and a TaskCondition.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTasking.Task#Task DCSTask
|
||||
-- @param #DCSStopCondition DCSStopCondition
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @param DCS#Task DCSTask
|
||||
-- @param DCS#DCSStopCondition DCSStopCondition
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:TaskControlled( DCSTask, DCSStopCondition )
|
||||
self:F2( { DCSTask, DCSStopCondition } )
|
||||
|
||||
@@ -442,8 +442,8 @@ end
|
||||
|
||||
--- Return a Combo Task taking an array of Tasks.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTasking.Task#TaskArray DCSTasks Array of @{DCSTasking.Task#Task}
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @param DCS#TaskArray DCSTasks Array of @{DCSTasking.Task#Task}
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:TaskCombo( DCSTasks )
|
||||
self:F2( { DCSTasks } )
|
||||
|
||||
@@ -466,8 +466,8 @@ end
|
||||
|
||||
--- Return a WrappedAction Task taking a Command.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSCommand#Command DCSCommand
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @param DCS#Command DCSCommand
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:TaskWrappedAction( DCSCommand, Index )
|
||||
self:F2( { DCSCommand } )
|
||||
|
||||
@@ -490,8 +490,8 @@ end
|
||||
--- Set a Task at a Waypoint using a Route list.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #table Waypoint The Waypoint!
|
||||
-- @param Dcs.DCSTasking.Task#Task Task The Task structure to be executed!
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @param DCS#Task Task The Task structure to be executed!
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:SetTaskWaypoint( Waypoint, Task )
|
||||
|
||||
Waypoint.task = self:TaskCombo( { Task } )
|
||||
@@ -505,7 +505,7 @@ end
|
||||
|
||||
--- Executes a command action
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSCommand#Command DCSCommand
|
||||
-- @param DCS#Command DCSCommand
|
||||
-- @return #CONTROLLABLE self
|
||||
function CONTROLLABLE:SetCommand( DCSCommand )
|
||||
self:F2( DCSCommand )
|
||||
@@ -525,7 +525,7 @@ end
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #number FromWayPoint
|
||||
-- @param #number ToWayPoint
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @return DCS#Task
|
||||
-- @usage
|
||||
-- --- This test demonstrates the use(s) of the SwitchWayPoint method of the GROUP class.
|
||||
-- HeliGroup = GROUP:FindByName( "Helicopter" )
|
||||
@@ -564,7 +564,7 @@ end
|
||||
--
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #boolean StopRoute true if the ground unit needs to stop, false if it needs to continue to move.
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:CommandStopRoute( StopRoute )
|
||||
self:F2( { StopRoute } )
|
||||
|
||||
@@ -587,12 +587,12 @@ end
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Wrapper.Controllable#CONTROLLABLE AttackGroup The Controllable to be attacked.
|
||||
-- @param #number WeaponType (optional) Bitmask of weapon types those allowed to use. If parameter is not defined that means no limits on weapon usage.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param Dcs.DCSTypes#Distance Altitude (optional) Desired attack start altitude. Controllable/aircraft will make its attacks from the altitude. If the altitude is too low or too high to use weapon aircraft/controllable will choose closest altitude to the desired attack start altitude. If the desired altitude is defined controllable/aircraft will not attack from safe altitude.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Distance Altitude (optional) Desired attack start altitude. Controllable/aircraft will make its attacks from the altitude. If the altitude is too low or too high to use weapon aircraft/controllable will choose closest altitude to the desired attack start altitude. If the desired altitude is defined controllable/aircraft will not attack from safe altitude.
|
||||
-- @param #boolean AttackQtyLimit (optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackGroup" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskAttackGroup( AttackGroup, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit )
|
||||
self:F2( { self.ControllableName, AttackGroup, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit } )
|
||||
|
||||
@@ -644,13 +644,13 @@ end
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Wrapper.Unit#UNIT AttackUnit The UNIT.
|
||||
-- @param #boolean GroupAttack (optional) If true, all units in the group will attack the Unit when found.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param #number Altitude (optional) The altitude from where to attack.
|
||||
-- @param #boolean Visible (optional) not a clue.
|
||||
-- @param #number WeaponType (optional) The WeaponType.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskAttackUnit( AttackUnit, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, Visible, WeaponType )
|
||||
self:F2( { self.ControllableName, AttackUnit, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, Visible, WeaponType } )
|
||||
|
||||
@@ -680,14 +680,14 @@ end
|
||||
|
||||
--- (AIR) Delivering weapon at the point on the ground.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Vec2 2D-coordinates of the point to deliver weapon at.
|
||||
-- @param DCS#Vec2 Vec2 2D-coordinates of the point to deliver weapon at.
|
||||
-- @param #boolean GroupAttack (optional) If true, all units in the group will attack the Unit when found.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param #number Altitude (optional) The altitude from where to attack.
|
||||
-- @param #number WeaponType (optional) The WeaponType.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskBombing( Vec2, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, WeaponType )
|
||||
self:F2( { self.ControllableName, Vec2, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, WeaponType } )
|
||||
|
||||
@@ -714,14 +714,14 @@ end
|
||||
|
||||
--- (AIR) Attacking the map object (building, structure, e.t.c).
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Vec2 2D-coordinates of the point to deliver weapon at.
|
||||
-- @param DCS#Vec2 Vec2 2D-coordinates of the point to deliver weapon at.
|
||||
-- @param #boolean GroupAttack (optional) If true, all units in the group will attack the Unit when found.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param #number Altitude (optional) The altitude from where to attack.
|
||||
-- @param #number WeaponType (optional) The WeaponType.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskAttackMapObject( Vec2, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, WeaponType )
|
||||
self:F2( { self.ControllableName, Vec2, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, WeaponType } )
|
||||
|
||||
@@ -749,7 +749,7 @@ end
|
||||
|
||||
--- (AIR) Orbit at a specified position at a specified alititude during a specified duration with a specified speed.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Point The point to hold the position.
|
||||
-- @param DCS#Vec2 Point The point to hold the position.
|
||||
-- @param #number Altitude The altitude [m] to hold the position.
|
||||
-- @param #number Speed The speed [m/s] flying when holding the position.
|
||||
-- @return #CONTROLLABLE self
|
||||
@@ -832,11 +832,11 @@ end
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Wrapper.Airbase#AIRBASE Airbase Airbase to attack.
|
||||
-- @param #number WeaponType (optional) Bitmask of weapon types those allowed to use. If parameter is not defined that means no limits on weapon usage.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param #boolean ControllableAttack (optional) Flag indicates that the target must be engaged by all aircrafts of the controllable. Has effect only if the task is assigned to a controllable, not to a single aircraft.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskBombingRunway( Airbase, WeaponType, WeaponExpend, AttackQty, Direction, ControllableAttack )
|
||||
self:F2( { self.ControllableName, Airbase, WeaponType, WeaponExpend, AttackQty, Direction, ControllableAttack } )
|
||||
|
||||
@@ -871,7 +871,7 @@ end
|
||||
|
||||
--- (AIR) Refueling from the nearest tanker. No parameters.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskRefueling()
|
||||
self:F2( { self.ControllableName } )
|
||||
|
||||
@@ -893,7 +893,7 @@ end
|
||||
|
||||
--- (AIR HELICOPTER) Landing at the ground. For helicopters only.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Point The point where to land.
|
||||
-- @param DCS#Vec2 Point The point where to land.
|
||||
-- @param #number Duration The duration in seconds to stay on the ground.
|
||||
-- @return #CONTROLLABLE self
|
||||
function CONTROLLABLE:TaskLandAtVec2( Point, Duration )
|
||||
@@ -958,9 +958,9 @@ end
|
||||
-- If another controllable is on land the unit / controllable will orbit around.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Wrapper.Controllable#CONTROLLABLE FollowControllable The controllable to be followed.
|
||||
-- @param Dcs.DCSTypes#Vec3 Vec3 Position of the unit / lead unit of the controllable relative lead unit of another controllable in frame reference oriented by course of lead unit of another controllable. If another controllable is on land the unit / controllable will orbit around.
|
||||
-- @param DCS#Vec3 Vec3 Position of the unit / lead unit of the controllable relative lead unit of another controllable in frame reference oriented by course of lead unit of another controllable. If another controllable is on land the unit / controllable will orbit around.
|
||||
-- @param #number LastWaypointIndex Detach waypoint of another controllable. Once reached the unit / controllable Follow task is finished.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskFollow( FollowControllable, Vec3, LastWaypointIndex )
|
||||
self:F2( { self.ControllableName, FollowControllable, Vec3, LastWaypointIndex } )
|
||||
|
||||
@@ -1000,11 +1000,11 @@ end
|
||||
-- The unit / controllable will also protect that controllable from threats of specified types.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Wrapper.Controllable#CONTROLLABLE EscortControllable The controllable to be escorted.
|
||||
-- @param Dcs.DCSTypes#Vec3 Vec3 Position of the unit / lead unit of the controllable relative lead unit of another controllable in frame reference oriented by course of lead unit of another controllable. If another controllable is on land the unit / controllable will orbit around.
|
||||
-- @param DCS#Vec3 Vec3 Position of the unit / lead unit of the controllable relative lead unit of another controllable in frame reference oriented by course of lead unit of another controllable. If another controllable is on land the unit / controllable will orbit around.
|
||||
-- @param #number LastWaypointIndex Detach waypoint of another controllable. Once reached the unit / controllable Follow task is finished.
|
||||
-- @param #number EngagementDistanceMax Maximal distance from escorted controllable to threat. If the threat is already engaged by escort escort will disengage if the distance becomes greater than 1.5 * engagementDistMax.
|
||||
-- @param Dcs.DCSTypes#AttributeNameArray TargetTypes Array of AttributeName that is contains threat categories allowed to engage.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @param DCS#AttributeNameArray TargetTypes Array of AttributeName that is contains threat categories allowed to engage.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskEscort( FollowControllable, Vec3, LastWaypointIndex, EngagementDistance, TargetTypes )
|
||||
self:F2( { self.ControllableName, FollowControllable, Vec3, LastWaypointIndex, EngagementDistance, TargetTypes } )
|
||||
|
||||
@@ -1046,11 +1046,11 @@ end
|
||||
|
||||
--- (GROUND) Fire at a VEC2 point until ammunition is finished.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Vec2 The point to fire at.
|
||||
-- @param Dcs.DCSTypes#Distance Radius The radius of the zone to deploy the fire at.
|
||||
-- @param DCS#Vec2 Vec2 The point to fire at.
|
||||
-- @param DCS#Distance Radius The radius of the zone to deploy the fire at.
|
||||
-- @param #number AmmoCount (optional) Quantity of ammunition to expand (omit to fire until ammunition is depleted).
|
||||
-- @param #number WeaponType (optional) Enum for weapon type ID. This value is only required if you want the group firing to use a specific weapon, for instance using the task on a ship to force it to fire guided missiles at targets within cannon range. See http://wiki.hoggit.us/view/DCS_enum_weapon_flag
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskFireAtPoint( Vec2, Radius, AmmoCount, WeaponType )
|
||||
self:F2( { self.ControllableName, Vec2, Radius, AmmoCount, WeaponType } )
|
||||
|
||||
@@ -1089,7 +1089,7 @@ end
|
||||
|
||||
--- (GROUND) Hold ground controllable from moving.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskHold()
|
||||
self:F2( { self.ControllableName } )
|
||||
|
||||
@@ -1118,9 +1118,9 @@ end
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Wrapper.Controllable#CONTROLLABLE AttackGroup Target CONTROLLABLE.
|
||||
-- @param #number WeaponType Bitmask of weapon types those allowed to use. If parameter is not defined that means no limits on weapon usage.
|
||||
-- @param Dcs.DCSTypes#AI.Task.Designation Designation (optional) Designation type.
|
||||
-- @param DCS#AI.Task.Designation Designation (optional) Designation type.
|
||||
-- @param #boolean Datalink (optional) Allows to use datalink to send the target information to attack aircraft. Enabled by default.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskFAC_AttackGroup( AttackGroup, WeaponType, Designation, Datalink )
|
||||
self:F2( { self.ControllableName, AttackGroup, WeaponType, Designation, Datalink } )
|
||||
|
||||
@@ -1152,10 +1152,10 @@ end
|
||||
|
||||
--- (AIR) Engaging targets of defined types.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Distance Distance Maximal distance from the target to a route leg. If the target is on a greater distance it will be ignored.
|
||||
-- @param Dcs.DCSTypes#AttributeNameArray TargetTypes Array of target categories allowed to engage.
|
||||
-- @param DCS#Distance Distance Maximal distance from the target to a route leg. If the target is on a greater distance it will be ignored.
|
||||
-- @param DCS#AttributeNameArray TargetTypes Array of target categories allowed to engage.
|
||||
-- @param #number Priority All enroute tasks have the priority parameter. This is a number (less value - higher priority) that determines actions related to what task will be performed first.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskEngageTargets( Distance, TargetTypes, Priority )
|
||||
self:F2( { self.ControllableName, Distance, TargetTypes, Priority } )
|
||||
|
||||
@@ -1185,11 +1185,11 @@ end
|
||||
|
||||
--- (AIR) Engaging a targets of defined types at circle-shaped zone.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Vec2 2D-coordinates of the zone.
|
||||
-- @param Dcs.DCSTypes#Distance Radius Radius of the zone.
|
||||
-- @param Dcs.DCSTypes#AttributeNameArray TargetTypes Array of target categories allowed to engage.
|
||||
-- @param DCS#Vec2 Vec2 2D-coordinates of the zone.
|
||||
-- @param DCS#Distance Radius Radius of the zone.
|
||||
-- @param DCS#AttributeNameArray TargetTypes Array of target categories allowed to engage.
|
||||
-- @param #number Priority All en-route tasks have the priority parameter. This is a number (less value - higher priority) that determines actions related to what task will be performed first.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskEngageTargetsInZone( Vec2, Radius, TargetTypes, Priority )
|
||||
self:F2( { self.ControllableName, Vec2, Radius, TargetTypes, Priority } )
|
||||
|
||||
@@ -1223,12 +1223,12 @@ end
|
||||
-- @param Wrapper.Controllable#CONTROLLABLE AttackGroup The Controllable to be attacked.
|
||||
-- @param #number Priority All en-route tasks have the priority parameter. This is a number (less value - higher priority) that determines actions related to what task will be performed first.
|
||||
-- @param #number WeaponType (optional) Bitmask of weapon types those allowed to use. If parameter is not defined that means no limits on weapon usage.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param Dcs.DCSTypes#Distance Altitude (optional) Desired attack start altitude. Controllable/aircraft will make its attacks from the altitude. If the altitude is too low or too high to use weapon aircraft/controllable will choose closest altitude to the desired attack start altitude. If the desired altitude is defined controllable/aircraft will not attack from safe altitude.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Distance Altitude (optional) Desired attack start altitude. Controllable/aircraft will make its attacks from the altitude. If the altitude is too low or too high to use weapon aircraft/controllable will choose closest altitude to the desired attack start altitude. If the desired altitude is defined controllable/aircraft will not attack from safe altitude.
|
||||
-- @param #boolean AttackQtyLimit (optional) The flag determines how to interpret attackQty parameter. If the flag is true then attackQty is a limit on maximal attack quantity for "AttackGroup" and "AttackUnit" tasks. If the flag is false then attackQty is a desired attack quantity for "Bombing" and "BombingRunway" tasks.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskEngageGroup( AttackGroup, Priority, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit )
|
||||
self:F2( { self.ControllableName, AttackGroup, Priority, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit } )
|
||||
|
||||
@@ -1284,13 +1284,13 @@ end
|
||||
-- @param Wrapper.Unit#UNIT EngageUnit The UNIT.
|
||||
-- @param #number Priority (optional) All en-route tasks have the priority parameter. This is a number (less value - higher priority) that determines actions related to what task will be performed first.
|
||||
-- @param #boolean GroupAttack (optional) If true, all units in the group will attack the Unit when found.
|
||||
-- @param Dcs.DCSTypes#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param DCS#AI.Task.WeaponExpend WeaponExpend (optional) Determines how much weapon will be released at each attack. If parameter is not defined the unit / controllable will choose expend on its own discretion.
|
||||
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aicraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aicraft/controllable still have ammo. If not defined the aircraft/controllable will attack target until it will be destroyed or until the aircraft/controllable will run out of ammo.
|
||||
-- @param Dcs.DCSTypes#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param Dcs.DCSTypes#Distance Altitude (optional) Desired altitude to perform the unit engagement.
|
||||
-- @param DCS#Azimuth Direction (optional) Desired ingress direction from the target to the attacking aircraft. Controllable/aircraft will make its attacks from the direction. Of course if there is no way to attack from the direction due the terrain controllable/aircraft will choose another direction.
|
||||
-- @param DCS#Distance Altitude (optional) Desired altitude to perform the unit engagement.
|
||||
-- @param #boolean Visible (optional) Unit must be visible.
|
||||
-- @param #boolean ControllableAttack (optional) Flag indicates that the target must be engaged by all aircrafts of the controllable. Has effect only if the task is assigned to a controllable, not to a single aircraft.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskEngageUnit( EngageUnit, Priority, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, Visible, ControllableAttack )
|
||||
self:F2( { self.ControllableName, EngageUnit, Priority, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, Visible, ControllableAttack } )
|
||||
|
||||
@@ -1334,7 +1334,7 @@ end
|
||||
|
||||
--- (AIR) Aircraft will act as an AWACS for friendly units (will provide them with information about contacts). No parameters.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskAWACS( )
|
||||
self:F2( { self.ControllableName } )
|
||||
|
||||
@@ -1357,7 +1357,7 @@ end
|
||||
|
||||
--- (AIR) Aircraft will act as a tanker for friendly units. No parameters.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskTanker( )
|
||||
self:F2( { self.ControllableName } )
|
||||
|
||||
@@ -1382,7 +1382,7 @@ end
|
||||
|
||||
--- (GROUND) Ground unit (EW-radar) will act as an EWR for friendly units (will provide them with information about contacts). No parameters.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskEWR( )
|
||||
self:F2( { self.ControllableName } )
|
||||
|
||||
@@ -1412,9 +1412,9 @@ end
|
||||
-- @param Wrapper.Controllable#CONTROLLABLE AttackGroup Target CONTROLLABLE.
|
||||
-- @param #number Priority All en-route tasks have the priority parameter. This is a number (less value - higher priority) that determines actions related to what task will be performed first.
|
||||
-- @param #number WeaponType Bitmask of weapon types those allowed to use. If parameter is not defined that means no limits on weapon usage.
|
||||
-- @param Dcs.DCSTypes#AI.Task.Designation Designation (optional) Designation type.
|
||||
-- @param DCS#AI.Task.Designation Designation (optional) Designation type.
|
||||
-- @param #boolean Datalink (optional) Allows to use datalink to send the target information to attack aircraft. Enabled by default.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskFAC_EngageGroup( AttackGroup, Priority, WeaponType, Designation, Datalink )
|
||||
self:F2( { self.ControllableName, AttackGroup, WeaponType, Priority, Designation, Datalink } )
|
||||
|
||||
@@ -1449,9 +1449,9 @@ end
|
||||
-- The killer is player-controlled allied CAS-aircraft that is in contact with the FAC.
|
||||
-- If the task is assigned to the controllable lead unit will be a FAC.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Distance Radius The maximal distance from the FAC to a target.
|
||||
-- @param DCS#Distance Radius The maximal distance from the FAC to a target.
|
||||
-- @param #number Priority All en-route tasks have the priority parameter. This is a number (less value - higher priority) that determines actions related to what task will be performed first.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:EnRouteTaskFAC( Radius, Priority )
|
||||
self:F2( { self.ControllableName, Radius, Priority } )
|
||||
|
||||
@@ -1480,10 +1480,10 @@ end
|
||||
|
||||
--- (AIR) Move the controllable to a Vec2 Point, wait for a defined duration and embark a controllable.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Point The point where to wait.
|
||||
-- @param DCS#Vec2 Point The point where to wait.
|
||||
-- @param #number Duration The duration in seconds to wait.
|
||||
-- @param #CONTROLLABLE EmbarkingControllable The controllable to be embarked.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure
|
||||
-- @return DCS#Task The DCS task structure
|
||||
function CONTROLLABLE:TaskEmbarking( Point, Duration, EmbarkingControllable )
|
||||
self:F2( { self.ControllableName, Point, Duration, EmbarkingControllable.DCSControllable } )
|
||||
|
||||
@@ -1507,13 +1507,13 @@ end
|
||||
|
||||
--- Move to a defined Vec2 Point, and embark to a controllable when arrived within a defined Radius.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec2 Point The point where to wait.
|
||||
-- @param DCS#Vec2 Point The point where to wait.
|
||||
-- @param #number Radius The radius of the embarking zone around the Point.
|
||||
-- @return Dcs.DCSTasking.Task#Task The DCS task structure.
|
||||
-- @return DCS#Task The DCS task structure.
|
||||
function CONTROLLABLE:TaskEmbarkToTransport( Point, Radius )
|
||||
self:F2( { self.ControllableName, Point, Radius } )
|
||||
|
||||
local DCSTask --Dcs.DCSTasking.Task#Task
|
||||
local DCSTask --DCS#Task
|
||||
DCSTask = { id = 'EmbarkToTransport',
|
||||
params = { x = Point.x,
|
||||
y = Point.y,
|
||||
@@ -1608,7 +1608,7 @@ end
|
||||
--- (AIR + GROUND) Return a mission task from a mission template.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #table TaskMission A table containing the mission task.
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:TaskMission( TaskMission )
|
||||
self:F2( Points )
|
||||
|
||||
@@ -1762,7 +1762,7 @@ end
|
||||
--- Return a Misson task to follow a given route defined by Points.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #table Points A table of route points.
|
||||
-- @return Dcs.DCSTasking.Task#Task
|
||||
-- @return DCS#Task
|
||||
function CONTROLLABLE:TaskRoute( Points )
|
||||
self:F2( Points )
|
||||
|
||||
@@ -1777,7 +1777,7 @@ do -- Route methods
|
||||
|
||||
--- (AIR + GROUND) Make the Controllable move to fly to a given point.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec3 Point The destination point in Vec3 format.
|
||||
-- @param DCS#Vec3 Point The destination point in Vec3 format.
|
||||
-- @param #number Speed The speed [m/s] to travel.
|
||||
-- @return #CONTROLLABLE self
|
||||
function CONTROLLABLE:RouteToVec2( Point, Speed )
|
||||
@@ -1828,7 +1828,7 @@ do -- Route methods
|
||||
|
||||
--- (AIR + GROUND) Make the Controllable move to a given point.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param Dcs.DCSTypes#Vec3 Point The destination point in Vec3 format.
|
||||
-- @param DCS#Vec3 Point The destination point in Vec3 format.
|
||||
-- @param #number Speed The speed [m/s] to travel.
|
||||
-- @return #CONTROLLABLE self
|
||||
function CONTROLLABLE:RouteToVec3( Point, Speed )
|
||||
@@ -2096,7 +2096,7 @@ do -- Route methods
|
||||
-- A speed can be given in km/h.
|
||||
-- A given formation can be given.
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #Vec2 Vec2 The Vec2 where to route to.
|
||||
-- @param DCS#Vec2 Vec2 The Vec2 where to route to.
|
||||
-- @param #number Speed The speed in m/s. Default is 5.555 m/s = 20 km/h.
|
||||
-- @param Base#FORMATION Formation The formation string.
|
||||
function CONTROLLABLE:TaskRouteToVec2( Vec2, Speed, Formation )
|
||||
@@ -2152,7 +2152,7 @@ end -- Route methods
|
||||
--- Do Script command
|
||||
-- @param #CONTROLLABLE self
|
||||
-- @param #string DoScript
|
||||
-- @return #DCSCommand
|
||||
-- @return DCS#DCSCommand
|
||||
function CONTROLLABLE:CommandDoScript( DoScript )
|
||||
|
||||
local DCSDoScript = {
|
||||
|
||||
Reference in New Issue
Block a user