Merge remote-tracking branch 'origin/master-ng' into branch

# Conflicts:
#	Moose Development/Moose/Functional/Escort.lua
#	Moose Development/Moose/Ops/CTLD.lua
#	Moose Development/Moose/Ops/CTLD_CARGO.lua
This commit is contained in:
Applevangelist
2026-03-05 09:56:05 +01:00
91 changed files with 3318 additions and 1759 deletions
+11 -7
View File
@@ -320,10 +320,12 @@ end
--- Set valid neighbours to be in a certain distance. --- Set valid neighbours to be in a certain distance.
-- @param #ASTAR self -- @param #ASTAR self
-- @param #number MaxDistance Max distance between nodes in meters. Default is 2000 m. -- @param #number MaxDistance (Optional) Max distance between nodes in meters. Default is 2000 m.
-- @return #ASTAR self -- @return #ASTAR self
function ASTAR:SetValidNeighbourDistance(MaxDistance) function ASTAR:SetValidNeighbourDistance(MaxDistance)
MaxDistance = MaxDistance or 2000
self:SetValidNeighbourFunction(ASTAR.DistMax, MaxDistance) self:SetValidNeighbourFunction(ASTAR.DistMax, MaxDistance)
return self return self
@@ -331,10 +333,12 @@ end
--- Set valid neighbours to be in a certain distance. --- Set valid neighbours to be in a certain distance.
-- @param #ASTAR self -- @param #ASTAR self
-- @param #number MaxDistance Max distance between nodes in meters. Default is 2000 m. -- @param #number MaxDistance (Optional) Max distance between nodes in meters. Default is 2000 m.
-- @return #ASTAR self -- @return #ASTAR self
function ASTAR:SetValidNeighbourRoad(MaxDistance) function ASTAR:SetValidNeighbourRoad(MaxDistance)
MaxDistance = MaxDistance or 2000
self:SetValidNeighbourFunction(ASTAR.Road, MaxDistance) self:SetValidNeighbourFunction(ASTAR.Road, MaxDistance)
return self return self
@@ -397,10 +401,10 @@ end
-- The coordinate system is oriented along the line between start and end point. -- The coordinate system is oriented along the line between start and end point.
-- @param #ASTAR self -- @param #ASTAR self
-- @param #table ValidSurfaceTypes Valid surface types. By default is all surfaces are allowed. -- @param #table ValidSurfaceTypes Valid surface types. By default is all surfaces are allowed.
-- @param #number BoxHY Box "height" in meters along the y-coordinate. Default 40000 meters (40 km). -- @param #number BoxHY (Optional) Box "height" in meters along the y-coordinate. Default 40000 meters (40 km).
-- @param #number SpaceX Additional space in meters before start and after end coordinate. Default 10000 meters (10 km). -- @param #number SpaceX (Optional) Additional space in meters before start and after end coordinate. Default 10000 meters (10 km).
-- @param #number deltaX Increment in the direction of start to end coordinate in meters. Default 2000 meters. -- @param #number deltaX (Optional) Increment in the direction of start to end coordinate in meters. Default 2000 meters.
-- @param #number deltaY Increment perpendicular to the direction of start to end coordinate in meters. Default is same as deltaX. -- @param #number deltaY (Optional) Increment perpendicular to the direction of start to end coordinate in meters. Default is same as deltaX.
-- @param #boolean MarkGrid If true, create F10 map markers at grid nodes. -- @param #boolean MarkGrid If true, create F10 map markers at grid nodes.
-- @return #ASTAR self -- @return #ASTAR self
function ASTAR:CreateGrid(ValidSurfaceTypes, BoxHY, SpaceX, deltaX, deltaY, MarkGrid) function ASTAR:CreateGrid(ValidSurfaceTypes, BoxHY, SpaceX, deltaX, deltaY, MarkGrid)
@@ -547,7 +551,7 @@ end
--- Function to check if distance between two nodes is less than a threshold distance. --- Function to check if distance between two nodes is less than a threshold distance.
-- @param #ASTAR.Node nodeA First node. -- @param #ASTAR.Node nodeA First node.
-- @param #ASTAR.Node nodeB Other node. -- @param #ASTAR.Node nodeB Other node.
-- @param #number distmax Max distance in meters. Default is 2000 m. -- @param #number distmax (Optional) Max distance in meters. Default is 2000 m.
-- @return #boolean If true, distance between the two nodes is below threshold. -- @return #boolean If true, distance between the two nodes is below threshold.
function ASTAR.DistMax(nodeA, nodeB, distmax) function ASTAR.DistMax(nodeA, nodeB, distmax)
+3 -3
View File
@@ -257,7 +257,7 @@ end
--- Evaluate conditon functions. --- Evaluate conditon functions.
-- @param #CONDITION self -- @param #CONDITION self
-- @param #boolean AnyTrue If `true`, evaluation return `true` if *any* condition function returns `true`. By default, *all* condition functions must return true. -- @param #boolean AnyTrue (Optional) If `true`, evaluation return `true` if *any* condition function returns `true`. By default, *all* condition functions must return true.
-- @return #boolean Result of condition functions. -- @return #boolean Result of condition functions.
function CONDITION:Evaluate(AnyTrue) function CONDITION:Evaluate(AnyTrue)
@@ -401,7 +401,7 @@ end
--- Condition to check if time is greater than a given threshold time. --- Condition to check if time is greater than a given threshold time.
-- @param #number Time Time in seconds. -- @param #number Time Time in seconds.
-- @param #boolean Absolute If `true`, abs. mission time from `timer.getAbsTime()` is checked. Default is relative mission time from `timer.getTime()`. -- @param #boolean Absolute (Optional) If `true`, abs. mission time from `timer.getAbsTime()` is checked. Default is relative mission time from `timer.getTime()`.
-- @return #boolean Returns `true` if time is greater than give the time. -- @return #boolean Returns `true` if time is greater than give the time.
function CONDITION.IsTimeGreater(Time, Absolute) function CONDITION.IsTimeGreater(Time, Absolute)
@@ -424,7 +424,7 @@ end
--- Function that returns `true` (success) with a certain probability. For example, if you specify `Probability=80` there is an 80% chance that `true` is returned. --- Function that returns `true` (success) with a certain probability. For example, if you specify `Probability=80` there is an 80% chance that `true` is returned.
-- Technically, a random number between 0 and 100 is created. If the given success probability is less then this number, `true` is returned. -- Technically, a random number between 0 and 100 is created. If the given success probability is less then this number, `true` is returned.
-- @param #number Probability Success probability in percent. Default 50 %. -- @param #number Probability (Optional) Success probability in percent. Default 50 %.
-- @return #boolean Returns `true` for success and `false` otherwise. -- @return #boolean Returns `true` for success and `false` otherwise.
function CONDITION.IsRandomSuccess(Probability) function CONDITION.IsRandomSuccess(Probability)
+4 -4
View File
@@ -1178,10 +1178,10 @@ end
--- Get a generic static cargo group template from scratch for dynamic cargo spawns register. Does not register the template! --- Get a generic static cargo group template from scratch for dynamic cargo spawns register. Does not register the template!
-- @param #DATABASE self -- @param #DATABASE self
-- @param #string Name Name of the static. -- @param #string Name Name of the static.
-- @param #string Typename Typename of the static. Defaults to "container_cargo". -- @param #string Typename (Optional) Typename of the static. Defaults to "container_cargo".
-- @param #number Mass Mass of the static. Defaults to 0. -- @param #number Mass (Optional) Mass of the static. Defaults to 0.
-- @param #number Coalition Coalition of the static. Defaults to coalition.side.BLUE. -- @param #number Coalition (Optional) Coalition of the static. Defaults to coalition.side.BLUE.
-- @param #number Country Country of the static. Defaults to country.id.GERMANY. -- @param #number Country (Optional) Country of the static. Defaults to country.id.GERMANY.
-- @return #table Static template table. -- @return #table Static template table.
function DATABASE:_GetGenericStaticCargoGroupTemplate(Name,Typename,Mass,Coalition,Country) function DATABASE:_GetGenericStaticCargoGroupTemplate(Name,Typename,Mass,Coalition,Country)
local StaticTemplate = {} local StaticTemplate = {}
+36 -5
View File
@@ -198,10 +198,41 @@ function MESSAGE:ToClient( Client, Settings )
return self return self
end end
--- Sends a MESSAGE to a SET_GROUP, SET_UNIT, or SET_CLIENT.
-- @param #MESSAGE self
-- @param Core.Set#SET_GROUP Set The set to send to.
-- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return self
function MESSAGE:ToSet(Set, Settings)
for _,_obj in pairs (Set:GetSetObjects() or {}) do
if _obj and _obj:IsAlive() then
if _obj:IsInstanceOf("SET_GROUP") then
self:ToGroup(_obj, Settings)
elseif _obj:IsInstanceOf("SET_CLIENT") or _obj:IsInstanceOf("SET_UNIT") then
self:ToUnit(_obj, Settings)
end
end
end
return self
end
--- Sends a MESSAGE to a SET_GROUP, SET_UNIT, or SET_CLIENT if a condition is true.
-- @param #MESSAGE self
-- @param Core.Set#SET_GROUP Set The set to send to.
-- @param #boolean Condition The condition which needs to be true.
-- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return self
function MESSAGE:ToSetIf(Set, Condition, Settings)
if Set and Condition == true then
self:ToSet(Set, Settings)
end
return self
end
--- Sends a MESSAGE to a Group. --- Sends a MESSAGE to a Group.
-- @param #MESSAGE self -- @param #MESSAGE self
-- @param Wrapper.Group#GROUP Group to which the message is displayed. -- @param Wrapper.Group#GROUP Group to which the message is displayed.
-- @param Core.Settings#Settings Settings (Optional) Settings for message display. -- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return #MESSAGE Message object. -- @return #MESSAGE Message object.
function MESSAGE:ToGroup( Group, Settings ) function MESSAGE:ToGroup( Group, Settings )
self:F( Group.GroupName ) self:F( Group.GroupName )
@@ -226,7 +257,7 @@ end
--- Sends a MESSAGE to a Unit. --- Sends a MESSAGE to a Unit.
-- @param #MESSAGE self -- @param #MESSAGE self
-- @param Wrapper.Unit#UNIT Unit to which the message is displayed. -- @param Wrapper.Unit#UNIT Unit to which the message is displayed.
-- @param Core.Settings#Settings Settings (Optional) Settings for message display. -- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return #MESSAGE Message object. -- @return #MESSAGE Message object.
function MESSAGE:ToUnit( Unit, Settings ) function MESSAGE:ToUnit( Unit, Settings )
self:F( Unit.IdentifiableName ) self:F( Unit.IdentifiableName )
@@ -252,7 +283,7 @@ end
--- Sends a MESSAGE to a Country. --- Sends a MESSAGE to a Country.
-- @param #MESSAGE self -- @param #MESSAGE self
-- @param #number Country to which the message is displayed, e.g. country.id.GERMANY. For all country numbers see here: [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_country) -- @param #number Country to which the message is displayed, e.g. country.id.GERMANY. For all country numbers see here: [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_country)
-- @param Core.Settings#Settings Settings (Optional) Settings for message display. -- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return #MESSAGE Message object. -- @return #MESSAGE Message object.
function MESSAGE:ToCountry( Country, Settings ) function MESSAGE:ToCountry( Country, Settings )
self:F(Country ) self:F(Country )
@@ -274,7 +305,7 @@ end
-- @param #MESSAGE self -- @param #MESSAGE self
-- @param #number Country to which the message is displayed, , e.g. country.id.GERMANY. For all country numbers see here: [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_country) -- @param #number Country to which the message is displayed, , e.g. country.id.GERMANY. For all country numbers see here: [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_country)
-- @param #boolean Condition Sends the message only if the condition is true. -- @param #boolean Condition Sends the message only if the condition is true.
-- @param Core.Settings#Settings Settings (Optional) Settings for message display. -- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @return #MESSAGE Message object. -- @return #MESSAGE Message object.
function MESSAGE:ToCountryIf( Country, Condition, Settings ) function MESSAGE:ToCountryIf( Country, Condition, Settings )
self:F(Country ) self:F(Country )
@@ -379,7 +410,7 @@ end
--- Sends a MESSAGE to all players. --- Sends a MESSAGE to all players.
-- @param #MESSAGE self -- @param #MESSAGE self
-- @param Core.Settings#Settings Settings (Optional) Settings for message display. -- @param Core.Settings#SETTINGS Settings (Optional) Settings for message display.
-- @param #number Delay (Optional) Delay in seconds before the message is send. Default instantly (`nil`). -- @param #number Delay (Optional) Delay in seconds before the message is send. Default instantly (`nil`).
-- @return #MESSAGE self -- @return #MESSAGE self
-- @usage -- @usage
+5 -5
View File
@@ -253,7 +253,7 @@ end
--- Get the n-th point of the pathline. --- Get the n-th point of the pathline.
-- @param #PATHLINE self -- @param #PATHLINE self
-- @param #number n The index of the point. Default is the first point. -- @param #number n (optional) The index of the point. Default is the first point.
-- @return #PATHLINE.Point Point. -- @return #PATHLINE.Point Point.
function PATHLINE:GetPointFromIndex(n) function PATHLINE:GetPointFromIndex(n)
@@ -275,7 +275,7 @@ end
--- Get the 3D position of the n-th point. --- Get the 3D position of the n-th point.
-- @param #PATHLINE self -- @param #PATHLINE self
-- @param #number n The n-th point. -- @param #number n The n-th point.
-- @return DCS#VEC3 Position in 3D. -- @return DCS#Vec3 Position in 3D.
function PATHLINE:GetPoint3DFromIndex(n) function PATHLINE:GetPoint3DFromIndex(n)
local point=self:GetPointFromIndex(n) local point=self:GetPointFromIndex(n)
@@ -290,7 +290,7 @@ end
--- Get the 2D position of the n-th point. --- Get the 2D position of the n-th point.
-- @param #PATHLINE self -- @param #PATHLINE self
-- @param #number n The n-th point. -- @param #number n The n-th point.
-- @return DCS#VEC2 Position in 3D. -- @return DCS#Vec2 Position in 3D.
function PATHLINE:GetPoint2DFromIndex(n) function PATHLINE:GetPoint2DFromIndex(n)
local point=self:GetPointFromIndex(n) local point=self:GetPointFromIndex(n)
@@ -360,8 +360,8 @@ end
--- Draw line on F10 map. --- Draw line on F10 map.
-- @param #PATHLINE self -- @param #PATHLINE self
-- @param #number Recipient Recipent of the line: -1=All. -- @param #number Recipient Recipent of the line: -1=All.
-- @param #table Color Color as RGB table plus alpha value. Default {1, 0, 0, 1.0}. -- @param #table Color (optional) Color as RGB table plus alpha value. Default {1, 0, 0, 1.0}.
-- @param #number LineType Line type: 1=Solid (default). -- @param #number LineType (optional) Line type: 1=Solid (default).
-- @return #PATHLINE self -- @return #PATHLINE self
function PATHLINE:DrawLine(Recipient, Color, LineType) function PATHLINE:DrawLine(Recipient, Color, LineType)
+59 -59
View File
@@ -610,7 +610,7 @@ do -- COORDINATE
--- Find the closest static to the COORDINATE within a certain radius. --- Find the closest static to the COORDINATE within a certain radius.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number radius Scan radius in meters. Default 100 m. -- @param #number radius (Optional) Scan radius in meters. Default 100 m.
-- @return Wrapper.Static#STATIC The closest static or #nil if no unit is inside the given radius. -- @return Wrapper.Static#STATIC The closest static or #nil if no unit is inside the given radius.
function COORDINATE:FindClosestStatic(radius) function COORDINATE:FindClosestStatic(radius)
@@ -633,7 +633,7 @@ do -- COORDINATE
--- Find the closest unit to the COORDINATE within a certain radius. --- Find the closest unit to the COORDINATE within a certain radius.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number radius Scan radius in meters. Default 100 m. -- @param #number radius (Optional) Scan radius in meters. Default 100 m.
-- @return Wrapper.Unit#UNIT The closest unit or #nil if no unit is inside the given radius. -- @return Wrapper.Unit#UNIT The closest unit or #nil if no unit is inside the given radius.
function COORDINATE:FindClosestUnit(radius) function COORDINATE:FindClosestUnit(radius)
@@ -678,7 +678,7 @@ do -- COORDINATE
--- Find the closest scenery to the COORDINATE within a certain radius. --- Find the closest scenery to the COORDINATE within a certain radius.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number radius Scan radius in meters. Default 100 m. -- @param #number radius (Optional) Scan radius in meters. Default 100 m.
-- @return Wrapper.Scenery#SCENERY The closest scenery or #nil if no object is inside the given radius. -- @return Wrapper.Scenery#SCENERY The closest scenery or #nil if no object is inside the given radius.
function COORDINATE:FindClosestScenery(radius) function COORDINATE:FindClosestScenery(radius)
@@ -716,8 +716,8 @@ do -- COORDINATE
--- Add a Distance in meters from the COORDINATE orthonormal plane, with the given angle, and calculate the new COORDINATE. --- Add a Distance in meters from the COORDINATE orthonormal plane, with the given angle, and calculate the new COORDINATE.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param DCS#Distance Distance The Distance to be added in meters. -- @param DCS#Distance Distance The Distance to be added in meters.
-- @param DCS#Angle Angle The Angle in degrees. Defaults to 0 if not specified (nil). -- @param DCS#Angle Angle (Optional) The Angle in degrees. Defaults to 0 if not specified (nil).
-- @param #boolean Keepalt If true, keep altitude of original coordinate. Default is that the new coordinate is created at the translated land height. -- @param #boolean Keepalt (Optional) If true, keep altitude of original coordinate. Default is that the new coordinate is created at the translated land height.
-- @param #boolean Overwrite If true, overwrite the original COORDINATE with the translated one. Otherwise, create a new COORDINATE. -- @param #boolean Overwrite If true, overwrite the original COORDINATE with the translated one. Otherwise, create a new COORDINATE.
-- @return #COORDINATE The new calculated COORDINATE. -- @return #COORDINATE The new calculated COORDINATE.
function COORDINATE:Translate( Distance, Angle, Keepalt, Overwrite ) function COORDINATE:Translate( Distance, Angle, Keepalt, Overwrite )
@@ -958,7 +958,7 @@ do -- COORDINATE
--- Return an intermediate COORDINATE between this an another coordinate. --- Return an intermediate COORDINATE between this an another coordinate.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #COORDINATE ToCoordinate The other coordinate. -- @param #COORDINATE ToCoordinate The other coordinate.
-- @param #number Fraction The fraction (0,1) where the new coordinate is created. Default 0.5, i.e. in the middle. -- @param #number Fraction (Optional) The fraction (0,1) where the new coordinate is created. Default 0.5, i.e. in the middle.
-- @return #COORDINATE Coordinate between this and the other coordinate. -- @return #COORDINATE Coordinate between this and the other coordinate.
function COORDINATE:GetIntermediateCoordinate( ToCoordinate, Fraction ) function COORDINATE:GetIntermediateCoordinate( ToCoordinate, Fraction )
@@ -1514,7 +1514,7 @@ do -- COORDINATE
-- @param Core.Settings#SETTINGS Settings -- @param Core.Settings#SETTINGS Settings
-- @param #string Language (Optional) Language "en" or "ru" -- @param #string Language (Optional) Language "en" or "ru"
-- @param #boolean MagVar If true, also state angle in magnetic -- @param #boolean MagVar If true, also state angle in magnetic
-- @param #number Precision Rounding precision, defaults to 0 -- @param #number Precision (Optional) Rounding precision, defaults to 0
-- @return #string The BR Text -- @return #string The BR Text
function COORDINATE:GetBRText( AngleRadians, Distance, Settings, Language, MagVar, Precision ) function COORDINATE:GetBRText( AngleRadians, Distance, Settings, Language, MagVar, Precision )
@@ -1555,7 +1555,7 @@ do -- COORDINATE
--- Set altitude. --- Set altitude.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number altitude New altitude in meters. -- @param #number altitude New altitude in meters.
-- @param #boolean asl Altitude above sea level. Default is above ground level. -- @param #boolean asl (Optional) Altitude above sea level. Default is above ground level.
-- @return #COORDINATE The COORDINATE with adjusted altitude. -- @return #COORDINATE The COORDINATE with adjusted altitude.
function COORDINATE:SetAltitude(altitude, asl) function COORDINATE:SetAltitude(altitude, asl)
local alt=altitude local alt=altitude
@@ -1581,7 +1581,7 @@ do -- COORDINATE
-- @param #COORDINATE.WaypointAltType AltType The altitude type. -- @param #COORDINATE.WaypointAltType AltType The altitude type.
-- @param #COORDINATE.WaypointType Type The route point type. -- @param #COORDINATE.WaypointType Type The route point type.
-- @param #COORDINATE.WaypointAction Action The route point action. -- @param #COORDINATE.WaypointAction Action The route point action.
-- @param DCS#Speed Speed Airspeed in km/h. Default is 500 km/h. -- @param DCS#Speed Speed (Optional) Airspeed in km/h. Default is 500 km/h.
-- @param #boolean SpeedLocked true means the speed is locked. -- @param #boolean SpeedLocked true means the speed is locked.
-- @param Wrapper.Airbase#AIRBASE airbase The airbase for takeoff and landing points. -- @param Wrapper.Airbase#AIRBASE airbase The airbase for takeoff and landing points.
-- @param #table DCSTasks A table of @{DCS#Task} items which are executed at the waypoint. -- @param #table DCSTasks A table of @{DCS#Task} items which are executed at the waypoint.
@@ -1741,7 +1741,7 @@ do -- COORDINATE
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param DCS#Speed Speed Airspeed in km/h. -- @param DCS#Speed Speed Airspeed in km/h.
-- @param Wrapper.Airbase#AIRBASE airbase The airbase for takeoff and landing points. -- @param Wrapper.Airbase#AIRBASE airbase The airbase for takeoff and landing points.
-- @param #number timeReFuAr Time in minutes, the aircraft stays at the airbase. Default 10 min. -- @param #number timeReFuAr (Optional) Time in minutes, the aircraft stays at the airbase. Default 10 min.
-- @param #table DCSTasks A table of @{DCS#Task} items which are executed at the waypoint. -- @param #table DCSTasks A table of @{DCS#Task} items which are executed at the waypoint.
-- @param #string description A text description of the waypoint, which will be shown on the F10 map. -- @param #string description A text description of the waypoint, which will be shown on the F10 map.
-- @return #table The route point. -- @return #table The route point.
@@ -2148,7 +2148,7 @@ do -- COORDINATE
--- Creates an explosion at the point of a certain intensity. --- Creates an explosion at the point of a certain intensity.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number ExplosionIntensity Intensity of the explosion in kg TNT. Default 100 kg. -- @param #number ExplosionIntensity (Optional) Intensity of the explosion in kg TNT. Default 100 kg.
-- @param #number Delay (Optional) Delay before explosion is triggered in seconds. -- @param #number Delay (Optional) Delay before explosion is triggered in seconds.
-- @return #COORDINATE self -- @return #COORDINATE self
function COORDINATE:Explosion( ExplosionIntensity, Delay ) function COORDINATE:Explosion( ExplosionIntensity, Delay )
@@ -2163,7 +2163,7 @@ do -- COORDINATE
--- Creates an illumination bomb at the point. --- Creates an illumination bomb at the point.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number Power Power of illumination bomb in Candela. Default 1000 cd. -- @param #number Power (Optional) Power of illumination bomb in Candela. Default 1000 cd.
-- @param #number Delay (Optional) Delay before bomb is ignited in seconds. -- @param #number Delay (Optional) Delay before bomb is ignited in seconds.
-- @return #COORDINATE self -- @return #COORDINATE self
function COORDINATE:IlluminationBomb(Power, Delay) function COORDINATE:IlluminationBomb(Power, Delay)
@@ -2622,10 +2622,10 @@ do -- COORDINATE
-- Creates a line on the F10 map from one point to another. -- Creates a line on the F10 map from one point to another.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #COORDINATE Endpoint COORDINATE to where the line is drawn. -- @param #COORDINATE Endpoint COORDINATE to where the line is drawn.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @param #string Text (Optional) Text displayed when mark is added. Default none. -- @param #string Text (Optional) Text displayed when mark is added. Default none.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
@@ -2646,13 +2646,13 @@ do -- COORDINATE
--- Circle to all. --- Circle to all.
-- Creates a circle on the map with a given radius, color, fill color, and outline. -- Creates a circle on the map with a given radius, color, fill color, and outline.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #number Radius Radius in meters. Default 1000 m. -- @param #number Radius (Optional) Radius in meters. Default 1000 m.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @param #string Text (Optional) Text displayed when mark is added. Default none. -- @param #string Text (Optional) Text displayed when mark is added. Default none.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
@@ -2686,12 +2686,12 @@ do -- COORDINATE
-- Creates a line on the F10 map from one point to another. -- Creates a line on the F10 map from one point to another.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #COORDINATE Endpoint COORDINATE in the opposite corner. -- @param #COORDINATE Endpoint COORDINATE in the opposite corner.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @param #string Text (Optional) Text displayed when mark is added. Default none. -- @param #string Text (Optional) Text displayed when mark is added. Default none.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
@@ -2722,12 +2722,12 @@ do -- COORDINATE
-- @param #COORDINATE Coord2 Second COORDINATE of the quad shape. -- @param #COORDINATE Coord2 Second COORDINATE of the quad shape.
-- @param #COORDINATE Coord3 Third COORDINATE of the quad shape. -- @param #COORDINATE Coord3 Third COORDINATE of the quad shape.
-- @param #COORDINATE Coord4 Fourth COORDINATE of the quad shape. -- @param #COORDINATE Coord4 Fourth COORDINATE of the quad shape.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @param #string Text (Optional) Text displayed when mark is added. Default none. -- @param #string Text (Optional) Text displayed when mark is added. Default none.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
@@ -2759,12 +2759,12 @@ do -- COORDINATE
--- Creates a free form shape on the F10 map. The first point is the current COORDINATE. The remaining points need to be specified. --- Creates a free form shape on the F10 map. The first point is the current COORDINATE. The remaining points need to be specified.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #table Coordinates Table of coordinates of the remaining points of the shape. -- @param #table Coordinates Table of coordinates of the remaining points of the shape.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @param #string Text (Optional) Text displayed when mark is added. Default none. -- @param #string Text (Optional) Text displayed when mark is added. Default none.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
@@ -2865,12 +2865,12 @@ do -- COORDINATE
--- Text to all. Creates a text imposed on the map at the COORDINATE. Text scales with the map. --- Text to all. Creates a text imposed on the map at the COORDINATE. Text scales with the map.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #string Text Text displayed on the F10 map. -- @param #string Text Text displayed on the F10 map.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.3. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.3.
-- @param #number FontSize Font size. Default 14. -- @param #number FontSize (Optional) Font size. Default 14.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
function COORDINATE:TextToAll(Text, Coalition, Color, Alpha, FillColor, FillAlpha, FontSize, ReadOnly) function COORDINATE:TextToAll(Text, Coalition, Color, Alpha, FillColor, FillAlpha, FontSize, ReadOnly)
@@ -2895,12 +2895,12 @@ do -- COORDINATE
--- Arrow to all. Creates an arrow from the COORDINATE to the endpoint COORDINATE on the F10 map. There is no control over other dimensions of the arrow. --- Arrow to all. Creates an arrow from the COORDINATE to the endpoint COORDINATE on the F10 map. There is no control over other dimensions of the arrow.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #COORDINATE Endpoint COORDINATE where the tip of the arrow is pointing at. -- @param #COORDINATE Endpoint COORDINATE where the tip of the arrow is pointing at.
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red (default). -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red (default).
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @param #string Text (Optional) Text displayed when mark is added. Default none. -- @param #string Text (Optional) Text displayed when mark is added. Default none.
-- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again. -- @return #number The resulting Mark ID, which is a number. Can be used to remove the object again.
@@ -2930,7 +2930,7 @@ do -- COORDINATE
--- Returns if a Coordinate has Line of Sight (LOS) with the ToCoordinate. --- Returns if a Coordinate has Line of Sight (LOS) with the ToCoordinate.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param #COORDINATE ToCoordinate -- @param #COORDINATE ToCoordinate
-- @param #number Offset Height offset in meters. Default 2 m. -- @param #number Offset (Optional) Height offset in meters. Default 2 m.
-- @return #boolean true If the ToCoordinate has LOS with the Coordinate, otherwise false. -- @return #boolean true If the ToCoordinate has LOS with the Coordinate, otherwise false.
function COORDINATE:IsLOS( ToCoordinate, Offset ) function COORDINATE:IsLOS( ToCoordinate, Offset )
@@ -3286,7 +3286,7 @@ do -- COORDINATE
-- @param #COORDINATE FromCoordinate The coordinate to measure the distance and the bearing from. -- @param #COORDINATE FromCoordinate The coordinate to measure the distance and the bearing from.
-- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object. -- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.
-- @param #boolean MagVar If true, also get angle in MagVar for BR/BRA -- @param #boolean MagVar If true, also get angle in MagVar for BR/BRA
-- @param #number Precision Rounding precision, currently full km as default (=0) -- @param #number Precision (Optional) Rounding precision, currently full km as default (=0)
-- @return #string The BR text. -- @return #string The BR text.
function COORDINATE:ToStringBR( FromCoordinate, Settings, MagVar, Precision ) function COORDINATE:ToStringBR( FromCoordinate, Settings, MagVar, Precision )
local DirectionVec3 = FromCoordinate:GetDirectionVec3( self ) local DirectionVec3 = FromCoordinate:GetDirectionVec3( self )
@@ -3300,7 +3300,7 @@ do -- COORDINATE
-- @param #COORDINATE FromCoordinate The coordinate to measure the distance and the bearing from. -- @param #COORDINATE FromCoordinate The coordinate to measure the distance and the bearing from.
-- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object. -- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.
-- @param #boolean MagVar If true, also get angle in MagVar for BR/BRA -- @param #boolean MagVar If true, also get angle in MagVar for BR/BRA
-- @param #number Precision Rounding precision, currently full km as default (=0) -- @param #number Precision (Optional) Rounding precision, currently full km as default (=0)
-- @return #string The BR text. -- @return #string The BR text.
function COORDINATE:ToStringBearing( FromCoordinate, Settings, MagVar, Precision ) function COORDINATE:ToStringBearing( FromCoordinate, Settings, MagVar, Precision )
local DirectionVec3 = FromCoordinate:GetDirectionVec3( self ) local DirectionVec3 = FromCoordinate:GetDirectionVec3( self )
@@ -3714,8 +3714,8 @@ do -- COORDINATE
-- * Uses default settings in COORDINATE. -- * Uses default settings in COORDINATE.
-- * Can be overridden if for a GROUP containing x clients, a menu was selected to override the default. -- * Can be overridden if for a GROUP containing x clients, a menu was selected to override the default.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param Wrapper.Controllable#CONTROLLABLE Controllable The controllable to retrieve the settings from, otherwise the default settings will be chosen. -- @param Wrapper.Controllable#CONTROLLABLE Controllable (Optional) The controllable to retrieve the settings from, otherwise the default settings will be chosen.
-- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object. -- @param Core.Settings#SETTINGS Settings (Optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.
-- @return #string The coordinate Text in the configured coordinate system. -- @return #string The coordinate Text in the configured coordinate system.
function COORDINATE:ToString( Controllable, Settings ) function COORDINATE:ToString( Controllable, Settings )
@@ -3750,7 +3750,7 @@ do -- COORDINATE
-- * Can be overridden if for a GROUP containing x clients, a menu was selected to override the default. -- * Can be overridden if for a GROUP containing x clients, a menu was selected to override the default.
-- @param #COORDINATE self -- @param #COORDINATE self
-- @param Wrapper.Controllable#CONTROLLABLE Controllable -- @param Wrapper.Controllable#CONTROLLABLE Controllable
-- @param Core.Settings#SETTINGS Settings (optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object. -- @param Core.Settings#SETTINGS Settings (Optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.
-- @return #string The pressure text in the configured measurement system. -- @return #string The pressure text in the configured measurement system.
function COORDINATE:ToStringPressure( Controllable, Settings ) function COORDINATE:ToStringPressure( Controllable, Settings )
+1 -1
View File
@@ -231,7 +231,7 @@ end
-- @param #number Repeat Specifies the time interval in seconds when the scheduler will call the event function. -- @param #number Repeat Specifies the time interval in seconds when the scheduler will call the event function.
-- @param #number RandomizeFactor Specifies a randomization factor between 0 and 1 to randomize the Repeat. -- @param #number RandomizeFactor Specifies a randomization factor between 0 and 1 to randomize the Repeat.
-- @param #number Stop Time interval in seconds after which the scheduler will be stopped. -- @param #number Stop Time interval in seconds after which the scheduler will be stopped.
-- @param #number TraceLevel Trace level [0,3]. Default 3. -- @param #number TraceLevel (Optional) Trace level [0,3]. Default 3.
-- @param Core.Fsm#FSM Fsm Finite state model. -- @param Core.Fsm#FSM Fsm Finite state model.
-- @return #string The Schedule ID of the planned schedule. -- @return #string The Schedule ID of the planned schedule.
function SCHEDULER:Schedule( MasterObject, SchedulerFunction, SchedulerArguments, Start, Repeat, RandomizeFactor, Stop, TraceLevel, Fsm ) function SCHEDULER:Schedule( MasterObject, SchedulerFunction, SchedulerArguments, Start, Repeat, RandomizeFactor, Stop, TraceLevel, Fsm )
+49 -48
View File
@@ -54,7 +54,7 @@
do -- SET_BASE do -- SET_BASE
--- --- SET_BASE class.
-- @type SET_BASE -- @type SET_BASE
-- @field #table Filter Table of filters. -- @field #table Filter Table of filters.
-- @field #table Set Table of objects. -- @field #table Set Table of objects.
@@ -62,6 +62,7 @@ do -- SET_BASE
-- @field #table List Unused table. -- @field #table List Unused table.
-- @field Core.Scheduler#SCHEDULER CallScheduler -- @field Core.Scheduler#SCHEDULER CallScheduler
-- @field #SET_BASE.Filters Filter Filters -- @field #SET_BASE.Filters Filter Filters
-- @field #booleaen filterNoRegex If true, FilterPrefix ignores special characters and evaluates plain string.
-- @extends Core.Base#BASE -- @extends Core.Base#BASE
--- The @{Core.Set#SET_BASE} class defines the core functions that define a collection of objects. --- The @{Core.Set#SET_BASE} class defines the core functions that define a collection of objects.
@@ -100,6 +101,7 @@ do -- SET_BASE
["neutral"] = coalition.side.NEUTRAL, ["neutral"] = coalition.side.NEUTRAL,
}, },
}, },
filterNoRegex=false,
} }
--- Filters --- Filters
@@ -244,6 +246,26 @@ do -- SET_BASE
return ObjectFound return ObjectFound
end end
--- Compares string for FilterPrefix function.
-- @param #SET_BASE self
-- @param #string Name The Name of the object.
-- @param #string Pattern The pattern that is contained in the Name.
-- @param #boolean NoRegex (Optional) If `true`, special characters in the Name are interpreted as plain text and not regular expressions. Default is `self.filterNoregex`.
-- @param #boolean ReplaceDash If `true`, dashes are not used as regex.
-- @return #boolean Returns `true`, if the pattern is contained in the name and false otherwise.
function SET_BASE:_SearchPattern(Name, Pattern, NoRegex, ReplaceDash)
NoRegex=NoRegex or self.filterNoRegex
if ReplaceDash==true then
-- Not sure why "-" is replaced by "%-" ?! - So we can still match group names with a dash in them
-- reason is that the string is interpreted as a pattern and "-" is a special character then. For interpreting it as a string, fourth parameter needs to be set to true.
Pattern=Pattern:gsub("-", "%%-")
end
local contain=string.find(Name, Pattern, 1, NoRegex)
return contain
end
--- Gets the Set. --- Gets the Set.
-- @param #SET_BASE self -- @param #SET_BASE self
-- @return #SET_BASE self -- @return #SET_BASE self
@@ -551,7 +573,7 @@ do -- SET_BASE
--- Define the SET iterator **"limit"**. --- Define the SET iterator **"limit"**.
-- @param #SET_BASE self -- @param #SET_BASE self
-- @param #number Limit Defines how many objects are evaluated of the set as part of the Some iterators. The default is 1. -- @param #number Limit (Optional) Defines how many objects are evaluated of the set as part of the Some iterators. The default is 1.
-- @return #SET_BASE self -- @return #SET_BASE self
function SET_BASE:SetSomeIteratorLimit(Limit) function SET_BASE:SetSomeIteratorLimit(Limit)
@@ -1556,7 +1578,7 @@ do
--- Set filter timer interval for FilterZones if using active filtering with FilterStart(). --- Set filter timer interval for FilterZones if using active filtering with FilterStart().
-- @param #SET_GROUP self -- @param #SET_GROUP self
-- @param #number Seconds Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Groups are usually not moving fast enough -- @param #number Seconds (Optional) Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Groups are usually not moving fast enough
-- to warrant a check of below 10 seconds. -- to warrant a check of below 10 seconds.
-- @return #SET_GROUP self -- @return #SET_GROUP self
function SET_GROUP:FilterZoneTimer(Seconds) function SET_GROUP:FilterZoneTimer(Seconds)
@@ -2094,19 +2116,16 @@ do
if self.Filter.GroupPrefixes and MGroupInclude then if self.Filter.GroupPrefixes and MGroupInclude then
local MGroupPrefix = false local MGroupPrefix = false
for GroupPrefixId, GroupPrefix in pairs(self.Filter.GroupPrefixes) do for GroupPrefixId, GroupPrefix in pairs(self.Filter.GroupPrefixes) do
--self:I({ "Prefix:", MGroup:GetName(), GroupPrefix }) if self:_SearchPattern(MGroup:GetName(), GroupPrefix, false, true) then
if string.find(MGroup:GetName(), string.gsub(GroupPrefix,"-","%%-"),1) then
MGroupPrefix = true MGroupPrefix = true
end end
end end
MGroupInclude = MGroupInclude and MGroupPrefix MGroupInclude = MGroupInclude and MGroupPrefix
--self:I("Is Included: "..tostring(MGroupInclude))
end end
if self.Filter.Zones and MGroupInclude then if self.Filter.Zones and MGroupInclude then
local MGroupZone = false local MGroupZone = false
for ZoneName, Zone in pairs(self.Filter.Zones) do for ZoneName, Zone in pairs(self.Filter.Zones) do
--self:T("Zone:", ZoneName)
if MGroup:IsInZone(Zone) then if MGroup:IsInZone(Zone) then
MGroupZone = true MGroupZone = true
end end
@@ -2120,7 +2139,6 @@ do
MGroupInclude = MGroupInclude and MGroupFunc MGroupInclude = MGroupInclude and MGroupFunc
end end
--self:I(MGroupInclude)
return MGroupInclude return MGroupInclude
end end
@@ -2637,7 +2655,7 @@ do -- SET_UNIT
--- Set filter timer interval for FilterZones if using active filtering with FilterStart(). --- Set filter timer interval for FilterZones if using active filtering with FilterStart().
-- @param #SET_UNIT self -- @param #SET_UNIT self
-- @param #number Seconds Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Groups are usually not moving fast enough -- @param #number Seconds (Optional) Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Groups are usually not moving fast enough
-- to warrant a check of below 10 seconds. -- to warrant a check of below 10 seconds.
-- @return #SET_UNIT self -- @return #SET_UNIT self
function SET_UNIT:FilterZoneTimer(Seconds) function SET_UNIT:FilterZoneTimer(Seconds)
@@ -3330,8 +3348,7 @@ do -- SET_UNIT
if self.Filter.UnitPrefixes and MUnitInclude then if self.Filter.UnitPrefixes and MUnitInclude then
local MUnitPrefix = false local MUnitPrefix = false
for UnitPrefixId, UnitPrefix in pairs(self.Filter.UnitPrefixes) do for UnitPrefixId, UnitPrefix in pairs(self.Filter.UnitPrefixes) do
--self:T3({ "Prefix:", string.find(MUnit:GetName(), UnitPrefix, 1), UnitPrefix }) if self:_SearchPattern(MUnit:GetName(), UnitPrefix, false, true) then
if string.find(MUnit:GetName(), UnitPrefix, 1) then
MUnitPrefix = true MUnitPrefix = true
end end
end end
@@ -4102,8 +4119,7 @@ do -- SET_STATIC
if self.Filter.StaticPrefixes then if self.Filter.StaticPrefixes then
local MStaticPrefix = false local MStaticPrefix = false
for StaticPrefixId, StaticPrefix in pairs(self.Filter.StaticPrefixes) do for StaticPrefixId, StaticPrefix in pairs(self.Filter.StaticPrefixes) do
--self:T(3({ "Prefix:", string.find(MStatic:GetName(), StaticPrefix, 1), StaticPrefix }) if self:_SearchPattern(MStatic:GetName(), StaticPrefix, false, true) then
if string.find(MStatic:GetName(), StaticPrefix, 1) then
MStaticPrefix = true MStaticPrefix = true
end end
end end
@@ -4560,7 +4576,7 @@ do -- SET_CLIENT
--- Set filter timer interval for FilterZones if using active filtering with FilterStart(). --- Set filter timer interval for FilterZones if using active filtering with FilterStart().
-- @param #SET_CLIENT self -- @param #SET_CLIENT self
-- @param #number Seconds Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Groups are usually not moving fast enough -- @param #number Seconds (Optional) Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Groups are usually not moving fast enough
-- to warrant a check of below 10 seconds. -- to warrant a check of below 10 seconds.
-- @return #SET_CLIENT self -- @return #SET_CLIENT self
function SET_CLIENT:FilterZoneTimer(Seconds) function SET_CLIENT:FilterZoneTimer(Seconds)
@@ -4886,12 +4902,10 @@ do -- SET_CLIENT
if self.Filter.ClientPrefixes and MClientInclude then if self.Filter.ClientPrefixes and MClientInclude then
local MClientPrefix = false local MClientPrefix = false
for ClientPrefixId, ClientPrefix in pairs(self.Filter.ClientPrefixes) do for ClientPrefixId, ClientPrefix in pairs(self.Filter.ClientPrefixes) do
--self:T3({ "Prefix:", string.find(MClient.UnitName, ClientPrefix, 1), ClientPrefix }) if self:_SearchPattern(MClient.UnitName, ClientPrefix) then
if string.find(MClient.UnitName, ClientPrefix, 1) then
MClientPrefix = true MClientPrefix = true
end end
end end
--self:T({ "Evaluated Prefix", MClientPrefix })
MClientInclude = MClientInclude and MClientPrefix MClientInclude = MClientInclude and MClientPrefix
end end
@@ -4912,7 +4926,7 @@ do -- SET_CLIENT
local playername = MClient:GetPlayerName() or "Unknown" local playername = MClient:GetPlayerName() or "Unknown"
--self:T(playername) --self:T(playername)
for _,_Playername in pairs(self.Filter.Playernames) do for _,_Playername in pairs(self.Filter.Playernames) do
if playername and string.find(playername,_Playername) then if playername and self:_SearchPattern(playername,_Playername) then
MClientPlayername = true MClientPlayername = true
end end
end end
@@ -4925,7 +4939,7 @@ do -- SET_CLIENT
local callsign = MClient:GetCallsign() local callsign = MClient:GetCallsign()
--self:I(callsign) --self:I(callsign)
for _,_Callsign in pairs(self.Filter.Callsigns) do for _,_Callsign in pairs(self.Filter.Callsigns) do
if callsign and string.find(callsign,_Callsign,1,true) then if callsign and self:_SearchPattern(callsign,_Callsign, true) then
MClientCallsigns = true MClientCallsigns = true
end end
end end
@@ -5346,12 +5360,10 @@ do -- SET_PLAYER
if self.Filter.ClientPrefixes then if self.Filter.ClientPrefixes then
local MClientPrefix = false local MClientPrefix = false
for ClientPrefixId, ClientPrefix in pairs(self.Filter.ClientPrefixes) do for ClientPrefixId, ClientPrefix in pairs(self.Filter.ClientPrefixes) do
--self:T(3({ "Prefix:", string.find(MClient.UnitName, ClientPrefix, 1), ClientPrefix }) if self:_SearchPattern(MClient.UnitName,ClientPrefix) then
if string.find(MClient.UnitName, ClientPrefix, 1) then
MClientPrefix = true MClientPrefix = true
end end
end end
--self:T(({ "Evaluated Prefix", MClientPrefix })
MClientInclude = MClientInclude and MClientPrefix MClientInclude = MClientInclude and MClientPrefix
end end
end end
@@ -6000,12 +6012,12 @@ do -- SET_ZONE
--- Draw all zones in the set on the F10 map. --- Draw all zones in the set on the F10 map.
-- @param #SET_ZONE self -- @param #SET_ZONE self
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red. -- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red.
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @return #SET_ZONE self -- @return #SET_ZONE self
function SET_ZONE:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType, ReadOnly) function SET_ZONE:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType, ReadOnly)
@@ -6056,12 +6068,10 @@ do -- SET_ZONE
if self.Filter.Prefixes then if self.Filter.Prefixes then
local MZonePrefix = false local MZonePrefix = false
for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do
--self:T(2({ "Prefix:", string.find(MZoneName, ZonePrefix, 1), ZonePrefix }) if self:_SearchPattern(MZoneName, ZonePrefix, false, true) then
if string.find(MZoneName, ZonePrefix, 1) then
MZonePrefix = true MZonePrefix = true
end end
end end
--self:T(({ "Evaluated Prefix", MZonePrefix })
MZoneInclude = MZoneInclude and MZonePrefix MZoneInclude = MZoneInclude and MZonePrefix
end end
end end
@@ -6147,7 +6157,7 @@ do -- SET_ZONE
--- Set the check time for SET_ZONE:Trigger() --- Set the check time for SET_ZONE:Trigger()
-- @param #SET_ZONE self -- @param #SET_ZONE self
-- @param #number seconds Check every seconds for objects entering or leaving the zone. Defaults to 5 secs. -- @param #number seconds (Optional) Check every seconds for objects entering or leaving the zone. Defaults to 5 secs.
-- @return #SET_ZONE self -- @return #SET_ZONE self
function SET_ZONE:SetCheckTime(seconds) function SET_ZONE:SetCheckTime(seconds)
self.Checktime = seconds or 5 self.Checktime = seconds or 5
@@ -6567,12 +6577,10 @@ do -- SET_ZONE_GOAL
if self.Filter.Prefixes then if self.Filter.Prefixes then
local MZonePrefix = false local MZonePrefix = false
for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do
--self:T(3({ "Prefix:", string.find(MZoneName, ZonePrefix, 1), ZonePrefix }) if self:_SearchPattern(MZoneName, ZonePrefix, false, true) then
if string.find(MZoneName, ZonePrefix, 1) then
MZonePrefix = true MZonePrefix = true
end end
end end
--self:T(({ "Evaluated Prefix", MZonePrefix })
MZoneInclude = MZoneInclude and MZonePrefix MZoneInclude = MZoneInclude and MZonePrefix
end end
end end
@@ -6929,18 +6937,14 @@ do -- SET_OPSZONE
-- Loop over prefixes. -- Loop over prefixes.
for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do
-- Prifix -- Prefix
--self:T(3({ "Prefix:", string.find(MZoneName, ZonePrefix, 1), ZonePrefix }) if self:_SearchPattern(MZoneName, ZonePrefix, false, true) then
if string.find(MZoneName, ZonePrefix, 1) then
MZonePrefix = true MZonePrefix = true
break --Break the loop as we found the prefix. break --Break the loop as we found the prefix.
end end
end end
--self:T(({ "Evaluated Prefix", MZonePrefix })
MZoneInclude = MZoneInclude and MZonePrefix MZoneInclude = MZoneInclude and MZonePrefix
end end
@@ -7728,7 +7732,7 @@ function SET_OPSGROUP:_EventOnBirth(Event)
local MGroupPrefix = false local MGroupPrefix = false
for GroupPrefixId, GroupPrefix in pairs(self.Filter.GroupPrefixes) do for GroupPrefixId, GroupPrefix in pairs(self.Filter.GroupPrefixes) do
if string.find(MGroup:GetName(), GroupPrefix:gsub ("-", "%%-"), 1) then --Not sure why "-" is replaced by "%-" ?! - So we can still match group names with a dash in them if self:_SearchPattern(MGroup:GetName(), GroupPrefix, false, true) then
MGroupPrefix = true MGroupPrefix = true
end end
end end
@@ -8062,12 +8066,10 @@ do -- SET_SCENERY
if self.Filter.Prefixes then if self.Filter.Prefixes then
local MSceneryPrefix = false local MSceneryPrefix = false
for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do for ZonePrefixId, ZonePrefix in pairs(self.Filter.Prefixes) do
--self:T(({ "Prefix:", string.find(MSceneryName, ZonePrefix, 1), ZonePrefix }) if self:_SearchPattern(MSceneryName, ZonePrefix, false, true) then
if string.find(MSceneryName, ZonePrefix, 1) then
MSceneryPrefix = true MSceneryPrefix = true
end end
end end
--self:T(({ "Evaluated Prefix", MSceneryPrefix })
MSceneryInclude = MSceneryInclude and MSceneryPrefix MSceneryInclude = MSceneryInclude and MSceneryPrefix
end end
@@ -8335,8 +8337,7 @@ do -- SET_DYNAMICCARGO
if self.Filter.StaticPrefixes then if self.Filter.StaticPrefixes then
local DCargoPrefix = false local DCargoPrefix = false
for StaticPrefixId, StaticPrefix in pairs(self.Filter.StaticPrefixes) do for StaticPrefixId, StaticPrefix in pairs(self.Filter.StaticPrefixes) do
--self:T2({ "Prefix:", string.find(DCargo:GetName(), StaticPrefix, 1), StaticPrefix }) if self:_SearchPattern(DCargo:GetName(), StaticPrefix, false, true) then
if string.find(DCargo:GetName(), StaticPrefix, 1) then
DCargoPrefix = true DCargoPrefix = true
end end
end end
@@ -8504,7 +8505,7 @@ do -- SET_DYNAMICCARGO
function SET_DYNAMICCARGO:FilterCurrentOwner(PlayerName) function SET_DYNAMICCARGO:FilterCurrentOwner(PlayerName)
self:FilterFunction( self:FilterFunction(
function(cargo) function(cargo)
if cargo and cargo.Owner and string.find(cargo.Owner,PlayerName,1,true) then if cargo and cargo.Owner and self:_SearchPattern(cargo.Owner, PlayerName, true) then
return true return true
else else
return false return false
@@ -8630,7 +8631,7 @@ do -- SET_DYNAMICCARGO
--- Set filter timer interval for FilterZones if using active filtering with FilterStart(). --- Set filter timer interval for FilterZones if using active filtering with FilterStart().
-- @param #SET_DYNAMICCARGO self -- @param #SET_DYNAMICCARGO self
-- @param #number Seconds Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Objects are usually not moving fast enough -- @param #number Seconds (Optional) Seconds between check intervals, defaults to 30. **Caution** - do not be too agressive with timing! Objects are usually not moving fast enough
-- to warrant a check of below 10 seconds. -- to warrant a check of below 10 seconds.
-- @return #SET_DYNAMICCARGO self -- @return #SET_DYNAMICCARGO self
function SET_DYNAMICCARGO:FilterZoneTimer(Seconds) function SET_DYNAMICCARGO:FilterZoneTimer(Seconds)
+2 -2
View File
@@ -1295,7 +1295,7 @@ end
--- Respawn group after landing. --- Respawn group after landing.
-- @param #SPAWN self -- @param #SPAWN self
-- @param #number WaitingTime Wait this many seconds before despawning the alive group after landing. Defaults to 3 . -- @param #number WaitingTime (Optional) Wait this many seconds before despawning the alive group after landing. Defaults to 3 .
-- @return #SPAWN self -- @return #SPAWN self
-- @usage -- @usage
-- --
@@ -1601,7 +1601,7 @@ end
-- This method can be used to "reset" the spawn counter to a specific index number. -- This method can be used to "reset" the spawn counter to a specific index number.
-- This will actually enable a respawn of groups from the specific index. -- This will actually enable a respawn of groups from the specific index.
-- @param #SPAWN self -- @param #SPAWN self
-- @param #string SpawnIndex The index of the group from where the spawning will start again. The default value would be 0, which means a complete reset of the spawnindex. -- @param #string SpawnIndex (Optional) The index of the group from where the spawning will start again. The default value would be 0, which means a complete reset of the spawnindex.
-- @return #SPAWN self -- @return #SPAWN self
function SPAWN:SetSpawnIndex( SpawnIndex ) function SPAWN:SetSpawnIndex( SpawnIndex )
self.SpawnIndex = SpawnIndex or 0 self.SpawnIndex = SpawnIndex or 0
+6 -6
View File
@@ -162,7 +162,7 @@ end
--- Creates the main object to spawn a @{Wrapper.Static} given a template table. --- Creates the main object to spawn a @{Wrapper.Static} given a template table.
-- @param #SPAWNSTATIC self -- @param #SPAWNSTATIC self
-- @param #table SpawnTemplate Template used for spawning. -- @param #table SpawnTemplate Template used for spawning.
-- @param DCS#country.id CountryID The ID of the country. Default `country.id.USA`. -- @param DCS#country.id CountryID (Optional) The ID of the country. Default `country.id.USA`.
-- @return #SPAWNSTATIC self -- @return #SPAWNSTATIC self
function SPAWNSTATIC:NewFromTemplate(SpawnTemplate, CountryID) function SPAWNSTATIC:NewFromTemplate(SpawnTemplate, CountryID)
@@ -180,7 +180,7 @@ end
-- @param #SPAWNSTATIC self -- @param #SPAWNSTATIC self
-- @param #string StaticType Type of the static. -- @param #string StaticType Type of the static.
-- @param #string StaticCategory Category of the static, e.g. "Planes". -- @param #string StaticCategory Category of the static, e.g. "Planes".
-- @param DCS#country.id CountryID The ID of the country. Default `country.id.USA`. -- @param DCS#country.id CountryID (Optional) The ID of the country. Default `country.id.USA`.
-- @return #SPAWNSTATIC self -- @return #SPAWNSTATIC self
function SPAWNSTATIC:NewFromType(StaticType, StaticCategory, CountryID) function SPAWNSTATIC:NewFromType(StaticType, StaticCategory, CountryID)
@@ -201,7 +201,7 @@ end
--- (Internal/Cargo) Init the resource table for STATIC object that should be spawned containing storage objects. --- (Internal/Cargo) Init the resource table for STATIC object that should be spawned containing storage objects.
-- NOTE that you have to init many other parameters as the resources. -- NOTE that you have to init many other parameters as the resources.
-- @param #SPAWNSTATIC self -- @param #SPAWNSTATIC self
-- @param #number CombinedWeight The weight this cargo object should have (some have fixed weights!), defaults to 1kg. -- @param #number CombinedWeight (Optional) The weight this cargo object should have (some have fixed weights!), defaults to 1kg.
-- @return #SPAWNSTATIC self -- @return #SPAWNSTATIC self
function SPAWNSTATIC:_InitResourceTable(CombinedWeight) function SPAWNSTATIC:_InitResourceTable(CombinedWeight)
if not self.TemplateStaticUnit.resourcePayload then if not self.TemplateStaticUnit.resourcePayload then
@@ -300,9 +300,9 @@ end
--- Initialize parameters for spawning FARPs. --- Initialize parameters for spawning FARPs.
-- @param #SPAWNSTATIC self -- @param #SPAWNSTATIC self
-- @param #number CallsignID Callsign ID. Default 1 (="London"). -- @param #number CallsignID (Optional) Callsign ID. Default 1 (="London").
-- @param #number Frequency Frequency in MHz. Default 127.5 MHz. -- @param #number Frequency (Optional) Frequency in MHz. Default 127.5 MHz.
-- @param #number Modulation Modulation 0=AM, 1=FM. -- @param #number Modulation (Optional) Modulation 0=AM, 1=FM. Defaults to 0
-- @param #boolean DynamicSpawns If true, allow Dynamic Spawns -- @param #boolean DynamicSpawns If true, allow Dynamic Spawns
-- @param #boolean DynamicHotStarts If true, and DynamicSpawns is true, then allow Dynamic Spawns with hot starts. -- @param #boolean DynamicHotStarts If true, and DynamicSpawns is true, then allow Dynamic Spawns with hot starts.
-- @return #SPAWNSTATIC self -- @return #SPAWNSTATIC self
+1 -1
View File
@@ -388,7 +388,7 @@ do
--- Set laser start position relative to the lasing unit. --- Set laser start position relative to the lasing unit.
-- @param #SPOT self -- @param #SPOT self
-- @param #table position Start position of the laser relative to the lasing unit. Default is { x = 0, y = 2, z = 0 } -- @param #table position (Optional) Start position of the laser relative to the lasing unit. Default is { x = 0, y = 2, z = 0 }
-- @return #SPOT self -- @return #SPOT self
-- @usage -- @usage
-- -- Set lasing position to be the position of the optics of the Gazelle M: -- -- Set lasing position to be the position of the optics of the Gazelle M:
+20 -20
View File
@@ -583,7 +583,7 @@ end
--- Return an intermediate VECTOR between this and another given vector. --- Return an intermediate VECTOR between this and another given vector.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #VECTOR Vector The destination vector. -- @param #VECTOR Vector The destination vector.
-- @param #number Fraction The fraction (0,1) where the new vector is created. Default 0.5, *i.e.* in the middle. -- @param #number Fraction (Optional) The fraction (0,1) where the new vector is created. Default 0.5, *i.e.* in the middle.
-- @return #VECTOR Vector between this and the other vector. -- @return #VECTOR Vector between this and the other vector.
function VECTOR:GetIntermediateVector(Vector, Fraction) function VECTOR:GetIntermediateVector(Vector, Fraction)
@@ -625,7 +625,7 @@ end
--- Set x-component of vector. The x-axis points to the North. --- Set x-component of vector. The x-axis points to the North.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number x Value of x. Default 0. -- @param #number x (Optional) Value of x. Default 0.
-- @return #VECTOR self -- @return #VECTOR self
function VECTOR:SetX(x) function VECTOR:SetX(x)
self.x=x or 0 self.x=x or 0
@@ -634,7 +634,7 @@ end
--- Set y-component of vector. The y-axis points to the upwards and describes the altitude above mean sea level. --- Set y-component of vector. The y-axis points to the upwards and describes the altitude above mean sea level.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number y Value of y. Default land/surface height at this point. -- @param #number y (Optional) Value of y. Default land/surface height at this point.
-- @return #VECTOR self -- @return #VECTOR self
function VECTOR:SetY(y) function VECTOR:SetY(y)
@@ -647,7 +647,7 @@ end
--- Set z-component of vector. The z-axis points to the East. --- Set z-component of vector. The z-axis points to the East.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number z Value of z. Default 0. -- @param #number z (Optional) Value of z. Default 0.
-- @return #VECTOR self -- @return #VECTOR self
function VECTOR:SetZ(z) function VECTOR:SetZ(z)
self.z=z or 0 self.z=z or 0
@@ -783,8 +783,8 @@ end
--- Translate the vector by a given distance and angle. --- Translate the vector by a given distance and angle.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Distance Distance in meters. Default 1000 meters. -- @param #number Distance (Optional) Distance in meters. Default 1000 meters.
-- @param #number Heading Heading angle in degrees. Default 0° = North. -- @param #number Heading (Optional) Heading angle in degrees. Default 0° = North.
-- @param #boolean Copy Create a copy of the VECTOR so the original stays unchanged. -- @param #boolean Copy Create a copy of the VECTOR so the original stays unchanged.
-- @return #VECTOR The translated vector or a copy of it. -- @return #VECTOR The translated vector or a copy of it.
function VECTOR:Translate(Distance, Heading, Copy) function VECTOR:Translate(Distance, Heading, Copy)
@@ -807,7 +807,7 @@ end
--- Rotate the VECTOR clockwise in the 2D (x,z) plane. --- Rotate the VECTOR clockwise in the 2D (x,z) plane.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Angle Rotation angle in degrees). Default 0. -- @param #number Angle (Optional) Rotation angle in degrees). Default 0.
-- @param #boolean Copy Create a copy of the VECTOR so the original stays unchanged. -- @param #boolean Copy Create a copy of the VECTOR so the original stays unchanged.
-- @return #VECTOR The translated vector or a copy of it. -- @return #VECTOR The translated vector or a copy of it.
function VECTOR:Rotate2D(Angle, Copy) function VECTOR:Rotate2D(Angle, Copy)
@@ -1001,7 +1001,7 @@ end
--- Returns an intercept point at which a ray drawn from the this vector in the passed normalized direction for a specified distance. --- Returns an intercept point at which a ray drawn from the this vector in the passed normalized direction for a specified distance.
-- @param #VECTOR self -- @param #VECTOR self
-- @param DCS#Vec3 DirectionVector Directional vector. -- @param DCS#Vec3 DirectionVector Directional vector.
-- @param #number Distance Distance in meters. Default 1000 m. -- @param #number Distance (Optional) Distance in meters. Default 1000 m.
-- @return #VECTOR Intercept vector. Can be `nil` if no intercept point is found. -- @return #VECTOR Intercept vector. Can be `nil` if no intercept point is found.
function VECTOR:GetInterceptPoint(DirectionVector, Distance) function VECTOR:GetInterceptPoint(DirectionVector, Distance)
@@ -1080,7 +1080,7 @@ end
--- Creates a smoke at this vector. --- Creates a smoke at this vector.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Color Color of the smoke: 0=Green, 1=Red, 2=White, 3=Orange, 4=Blue. Default 0. -- @param #number Color (Optional) Color of the smoke: 0=Green, 1=Red, 2=White, 3=Orange, 4=Blue. Default 0.
-- @param #number Duration (Optional) Duration of the smoke in seconds. Default nil. -- @param #number Duration (Optional) Duration of the smoke in seconds. Default nil.
-- @return #string Name of the smoke object. Can be used to stop it. -- @return #string Name of the smoke object. Can be used to stop it.
function VECTOR:Smoke(Color, Duration) function VECTOR:Smoke(Color, Duration)
@@ -1115,8 +1115,8 @@ end
-- * 8 = huge smoke -- * 8 = huge smoke
-- --
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Preset Preset of smoke. Default `BIGSMOKEPRESET.LargeSmokeAndFire`. -- @param #number Preset (Optional) Preset of smoke. Default `BIGSMOKEPRESET.LargeSmokeAndFire`.
-- @param #number Density Density between [0,1]. Default 0.5. -- @param #number Density (Optional) Density between [0,1]. Default 0.5.
-- @param #number Duration (Optional) Duration of the smoke and fire in seconds. -- @param #number Duration (Optional) Duration of the smoke and fire in seconds.
-- @return #string Name of the smoke. Can be used to stop it. -- @return #string Name of the smoke. Can be used to stop it.
function VECTOR:SmokeAndFire(Preset, Density, Duration) function VECTOR:SmokeAndFire(Preset, Density, Duration)
@@ -1161,7 +1161,7 @@ end
--- Creates an illumination bomb at the specified point. --- Creates an illumination bomb at the specified point.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Power The power in Candela (cd). Should be between 1 and 1000000. Default 1000 cd. -- @param #number Power (Optional) The power in Candela (cd). Should be between 1 and 1000000. Default 1000 cd.
-- @param #number Altitude (Optional) Altitude [m] at which the illumination bomb is created. -- @param #number Altitude (Optional) Altitude [m] at which the illumination bomb is created.
-- @return #VECTOR self -- @return #VECTOR self
function VECTOR:IlluminationBomb(Power, Altitude) function VECTOR:IlluminationBomb(Power, Altitude)
@@ -1180,7 +1180,7 @@ end
--- Creates an explosion at a given point at the specified power. --- Creates an explosion at a given point at the specified power.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Power The power in kg TNT. Default 100 kg. -- @param #number Power (Optional) The power in kg TNT. Default 100 kg.
-- @return #VECTOR self -- @return #VECTOR self
function VECTOR:Explosion(Power) function VECTOR:Explosion(Power)
@@ -1193,8 +1193,8 @@ end
--- Creates a signal flare at the given point in the specified color. The flare will be launched in the direction of the azimuth angle. --- Creates a signal flare at the given point in the specified color. The flare will be launched in the direction of the azimuth angle.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #number Color Color of flare. Default Green. -- @param #number Color (Optional) Color of flare. Default Green.
-- @param #number Azimuth Azimuth angle in degrees. Default 0. -- @param #number Azimuth (Optional) Azimuth angle in degrees. Default 0.
-- @return #VECTOR self -- @return #VECTOR self
function VECTOR:Flare(Color, Azimuth) function VECTOR:Flare(Color, Azimuth)
@@ -1209,10 +1209,10 @@ end
--- Creates a arrow from this VECTOR to another vector on the F10 map. --- Creates a arrow from this VECTOR to another vector on the F10 map.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #VECTOR Vector The vector defining the endpoint. -- @param #VECTOR Vector The vector defining the endpoint.
-- @param #number Coalition Coalition Id: -1=All, 0=Neutral, 1=Red, 2=Blue. Default -1. -- @param #number Coalition (Optional) Coalition Id: -1=All, 0=Neutral, 1=Red, 2=Blue. Default -1.
-- @param #table Color RGB color with alpha {r, g, b, alpha}. Default {1, 0, 0, 0.7}. -- @param #table Color (Optional) RGB color with alpha {r, g, b, alpha}. Default {1, 0, 0, 0.7}.
-- @param #table FillColor RGB color with alpha {r, g, b, alpha}. Default {1, 0, 0, 0.5}. -- @param #table FillColor (Optional) RGB color with alpha {r, g, b, alpha}. Default {1, 0, 0, 0.5}.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot Dash, 5=Long Dash, 6=Two Dash. Default 1. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot Dash, 5=Long Dash, 6=Two Dash. Default 1.
-- @return #number Marker ID. Can be used to remove the drawing. -- @return #number Marker ID. Can be used to remove the drawing.
function VECTOR:ArrowTo(Vector, Coalition, Color, FillColor, LineType) function VECTOR:ArrowTo(Vector, Coalition, Color, FillColor, LineType)
@@ -1237,7 +1237,7 @@ end
--- Create mark on F10 map. --- Create mark on F10 map.
-- @param #VECTOR self -- @param #VECTOR self
-- @param #string MarkText Free format text that shows the marking clarification. -- @param #string MarkText Free format text that shows the marking clarification.
-- @param #number Recipient Recipient of the mark: -1=All (default), 0=Neutral, 1=Red, 2=Blue. Can also be a `GROUP` object. -- @param #number Recipient (Optional) Recipient of the mark: -1=All (default), 0=Neutral, 1=Red, 2=Blue. Can also be a `GROUP` object.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @return #number Mark ID. -- @return #number Mark ID.
function VECTOR:Mark(MarkText, Recipient, ReadOnly) function VECTOR:Mark(MarkText, Recipient, ReadOnly)
+38 -38
View File
@@ -369,7 +369,7 @@ end
--- Set draw coalition of zone. --- Set draw coalition of zone.
-- @param #ZONE_BASE self -- @param #ZONE_BASE self
-- @param #number Coalition Coalition. Default -1. -- @param #number Coalition (Optional) Coalition. Default -1.
-- @return #ZONE_BASE self -- @return #ZONE_BASE self
function ZONE_BASE:SetDrawCoalition(Coalition) function ZONE_BASE:SetDrawCoalition(Coalition)
self.drawCoalition=Coalition or -1 self.drawCoalition=Coalition or -1
@@ -385,8 +385,8 @@ end
--- Set color of zone. --- Set color of zone.
-- @param #ZONE_BASE self -- @param #ZONE_BASE self
-- @param #table RGBcolor RGB color table. Default `{1, 0, 0}`. -- @param #table RGBcolor (Optional) RGB color table. Default `{1, 0, 0}`.
-- @param #number Alpha Transparency between 0 and 1. Default 0.15. -- @param #number Alpha (Optional) Transparency between 0 and 1. Default 0.15.
-- @return #ZONE_BASE self -- @return #ZONE_BASE self
function ZONE_BASE:SetColor(RGBcolor, Alpha) function ZONE_BASE:SetColor(RGBcolor, Alpha)
@@ -432,8 +432,8 @@ end
--- Set fill color of zone. --- Set fill color of zone.
-- @param #ZONE_BASE self -- @param #ZONE_BASE self
-- @param #table RGBcolor RGB color table. Default `{1, 0, 0}`. -- @param #table RGBcolor (Optional) RGB color table. Default `{1, 0, 0}`.
-- @param #number Alpha Transparacy between 0 and 1. Default 0.15. -- @param #number Alpha (Optional) Transparacy between 0 and 1. Default 0.15.
-- @return #ZONE_BASE self -- @return #ZONE_BASE self
function ZONE_BASE:SetFillColor(RGBcolor, Alpha) function ZONE_BASE:SetFillColor(RGBcolor, Alpha)
@@ -586,7 +586,7 @@ end
--- Set the check time for ZONE:Trigger() --- Set the check time for ZONE:Trigger()
-- @param #ZONE_BASE self -- @param #ZONE_BASE self
-- @param #number seconds Check every seconds for objects entering or leaving the zone. Defaults to 5 secs. -- @param #number seconds (Optional) Check every seconds for objects entering or leaving the zone. Defaults to 5 secs.
-- @return #ZONE_BASE self -- @return #ZONE_BASE self
function ZONE_BASE:SetCheckTime(seconds) function ZONE_BASE:SetCheckTime(seconds)
self.Checktime = seconds or 5 self.Checktime = seconds or 5
@@ -862,7 +862,7 @@ ZONE_RADIUS = {
-- @param #string ZoneName Name of the zone. -- @param #string ZoneName Name of the zone.
-- @param DCS#Vec2 Vec2 The location of the zone. -- @param DCS#Vec2 Vec2 The location of the zone.
-- @param DCS#Distance Radius The radius of the zone. -- @param DCS#Distance Radius The radius of the zone.
-- @param DCS#Boolean DoNotRegisterZone Determines if the Zone should not be registered in the _Database Table. Default=false -- @param DCS#Boolean DoNotRegisterZone (Optional) Determines if the Zone should not be registered in the _Database Table. Default=false
-- @return #ZONE_RADIUS self -- @return #ZONE_RADIUS self
function ZONE_RADIUS:New( ZoneName, Vec2, Radius, DoNotRegisterZone ) function ZONE_RADIUS:New( ZoneName, Vec2, Radius, DoNotRegisterZone )
@@ -946,12 +946,12 @@ end
--- Draw the zone circle on the F10 map. --- Draw the zone circle on the F10 map.
-- @param #ZONE_RADIUS self -- @param #ZONE_RADIUS self
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red. -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red.
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value.
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @return #ZONE_RADIUS self -- @return #ZONE_RADIUS self
function ZONE_RADIUS:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType, ReadOnly) function ZONE_RADIUS:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType, ReadOnly)
@@ -2506,7 +2506,7 @@ end
--- Get a vertex of the polygon. --- Get a vertex of the polygon.
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #number Index Index of the vertex. Default 1. -- @param #number Index (Optional) Index of the vertex. Default 1.
-- @return DCS#Vec2 Vertex of the polygon. -- @return DCS#Vec2 Vertex of the polygon.
function ZONE_POLYGON_BASE:GetVertexVec2(Index) function ZONE_POLYGON_BASE:GetVertexVec2(Index)
return self._.Polygon[Index or 1] return self._.Polygon[Index or 1]
@@ -2514,7 +2514,7 @@ end
--- Get a vertex of the polygon. --- Get a vertex of the polygon.
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #number Index Index of the vertex. Default 1. -- @param #number Index (Optional) Index of the vertex. Default 1.
-- @return DCS#Vec3 Vertex of the polygon. -- @return DCS#Vec3 Vertex of the polygon.
function ZONE_POLYGON_BASE:GetVertexVec3(Index) function ZONE_POLYGON_BASE:GetVertexVec3(Index)
local vec2=self:GetVertexVec2(Index) local vec2=self:GetVertexVec2(Index)
@@ -2527,7 +2527,7 @@ end
--- Get a vertex of the polygon. --- Get a vertex of the polygon.
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #number Index Index of the vertex. Default 1. -- @param #number Index (Optional) Index of the vertex. Default 1.
-- @return Core.Point#COORDINATE Vertex of the polygon. -- @return Core.Point#COORDINATE Vertex of the polygon.
function ZONE_POLYGON_BASE:GetVertexCoordinate(Index) function ZONE_POLYGON_BASE:GetVertexCoordinate(Index)
local vec2=self:GetVertexVec2(Index) local vec2=self:GetVertexVec2(Index)
@@ -2657,12 +2657,12 @@ end
--- Draw the zone on the F10 map. Infinite number of points supported --- Draw the zone on the F10 map. Infinite number of points supported
--- ported from https://github.com/nielsvaes/CCMOOSE/blob/master/Moose%20Development/Moose/Shapes/Polygon.lua --- ported from https://github.com/nielsvaes/CCMOOSE/blob/master/Moose%20Development/Moose/Shapes/Polygon.lua
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red. -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red.
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- doesn't seem to work -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- doesn't seem to work
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- doesn't seem to work -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15. -- doesn't seem to work
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.s -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.s
-- @return #ZONE_POLYGON_BASE self -- @return #ZONE_POLYGON_BASE self
function ZONE_POLYGON_BASE:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType, ReadOnly, IncludeTriangles) function ZONE_POLYGON_BASE:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType, ReadOnly, IncludeTriangles)
@@ -2710,7 +2710,7 @@ end
--- Change/Re-fill a Polygon Zone --- Change/Re-fill a Polygon Zone
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red. -- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red.
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @return #ZONE_POLYGON_BASE self -- @return #ZONE_POLYGON_BASE self
function ZONE_POLYGON_BASE:ReFill(Color,Alpha) function ZONE_POLYGON_BASE:ReFill(Color,Alpha)
local color = Color or self:GetFillColorRGB() or {1,0,0} local color = Color or self:GetFillColorRGB() or {1,0,0}
@@ -2740,8 +2740,8 @@ end
--- Change/Re-draw the border of a Polygon Zone --- Change/Re-draw the border of a Polygon Zone
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red. -- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red.
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @return #ZONE_POLYGON_BASE -- @return #ZONE_POLYGON_BASE
function ZONE_POLYGON_BASE:ReDrawBorderline(Color, Alpha, LineType) function ZONE_POLYGON_BASE:ReDrawBorderline(Color, Alpha, LineType)
local color = Color or self:GetFillColorRGB() or {1,0,0} local color = Color or self:GetFillColorRGB() or {1,0,0}
@@ -2840,7 +2840,7 @@ end
--- Remove junk inside the zone. Due to DCS limitations, this works only for rectangular zones. So we get the smallest rectangular zone encompassing all points points of the polygon zone. --- Remove junk inside the zone. Due to DCS limitations, this works only for rectangular zones. So we get the smallest rectangular zone encompassing all points points of the polygon zone.
-- @param #ZONE_POLYGON_BASE self -- @param #ZONE_POLYGON_BASE self
-- @param #number Height Height of the box in meters. Default 1000. -- @param #number Height (Optional) Height of the box in meters. Default 1000.
-- @return #number Number of removed objects. -- @return #number Number of removed objects.
function ZONE_POLYGON_BASE:RemoveJunk(Height) function ZONE_POLYGON_BASE:RemoveJunk(Height)
@@ -3761,8 +3761,8 @@ do -- ZONE_ELASTIC
--- Update the convex hull of the polygon. --- Update the convex hull of the polygon.
-- This uses the [Graham scan](https://en.wikipedia.org/wiki/Graham_scan). -- This uses the [Graham scan](https://en.wikipedia.org/wiki/Graham_scan).
-- @param #ZONE_ELASTIC self -- @param #ZONE_ELASTIC self
-- @param #number Delay Delay in seconds before the zone is updated. Default 0. -- @param #number Delay (Optional) Delay in seconds before the zone is updated. Default 0.
-- @param #boolean Draw Draw the zone. Default `nil`. -- @param #boolean Draw (Optional) Draw the zone. Default `nil`.
-- @return #ZONE_ELASTIC self -- @return #ZONE_ELASTIC self
function ZONE_ELASTIC:Update(Delay, Draw) function ZONE_ELASTIC:Update(Delay, Draw)
@@ -3803,9 +3803,9 @@ do -- ZONE_ELASTIC
--- Start the updating scheduler. --- Start the updating scheduler.
-- @param #ZONE_ELASTIC self -- @param #ZONE_ELASTIC self
-- @param #number Tstart Time in seconds before the updating starts. -- @param #number Tstart Time in seconds before the updating starts.
-- @param #number dT Time interval in seconds between updates. Default 60 sec. -- @param #number dT (Optional) Time interval in seconds between updates. Default 60 sec.
-- @param #number Tstop Time in seconds after which the updating stops. Default `nil`. -- @param #number Tstop (Optional) Time in seconds after which the updating stops. Default `nil`.
-- @param #boolean Draw Draw the zone. Default `nil`. -- @param #boolean Draw (Optional) Draw the zone. Default `nil`.
-- @return #ZONE_ELASTIC self -- @return #ZONE_ELASTIC self
function ZONE_ELASTIC:StartUpdate(Tstart, dT, Tstop, Draw) function ZONE_ELASTIC:StartUpdate(Tstart, dT, Tstop, Draw)
@@ -3816,7 +3816,7 @@ do -- ZONE_ELASTIC
--- Stop the updating scheduler. --- Stop the updating scheduler.
-- @param #ZONE_ELASTIC self -- @param #ZONE_ELASTIC self
-- @param #number Delay Delay in seconds before the scheduler will be stopped. Default 0. -- @param #number Delay (Optional) Delay in seconds before the scheduler will be stopped. Default 0.
-- @return #ZONE_ELASTIC self -- @return #ZONE_ELASTIC self
function ZONE_ELASTIC:StopUpdate(Delay) function ZONE_ELASTIC:StopUpdate(Delay)
@@ -4066,12 +4066,12 @@ end
--- Draw the zone on the F10 map. --- Draw the zone on the F10 map.
--- ported from https://github.com/nielsvaes/CCMOOSE/blob/master/Moose%20Development/Moose/Shapes/Oval.lua --- ported from https://github.com/nielsvaes/CCMOOSE/blob/master/Moose%20Development/Moose/Shapes/Oval.lua
-- @param #ZONE_OVAL self -- @param #ZONE_OVAL self
-- @param #number Coalition Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All. -- @param #number Coalition (Optional) Coalition: All=-1, Neutral=0, Red=1, Blue=2. Default -1=All.
-- @param #table Color RGB color table {r, g, b}, e.g. {1,0,0} for red. -- @param #table Color (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red.
-- @param #number Alpha Transparency [0,1]. Default 1. -- @param #number Alpha (Optional) Transparency [0,1]. Default 1.
-- @param #table FillColor RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- doesn't seem to work -- @param #table FillColor (Optional) RGB color table {r, g, b}, e.g. {1,0,0} for red. Default is same as `Color` value. -- doesn't seem to work
-- @param #number FillAlpha Transparency [0,1]. Default 0.15. -- doesn't seem to work -- @param #number FillAlpha (Optional) Transparency [0,1]. Default 0.15. -- doesn't seem to work
-- @param #number LineType Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false. -- @param #boolean ReadOnly (Optional) Mark is readonly and cannot be removed by users. Default false.
-- @return #ZONE_OVAL self -- @return #ZONE_OVAL self
function ZONE_OVAL:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType) function ZONE_OVAL:DrawZone(Coalition, Color, Alpha, FillColor, FillAlpha, LineType)
+2 -2
View File
@@ -131,7 +131,7 @@ do -- world
--- Returns a table of DCS airbase objects. --- Returns a table of DCS airbase objects.
-- @function [parent=#world] getAirbases -- @function [parent=#world] getAirbases
-- @param #number coalitionId The coalition side number ID. Default is all airbases are returned. -- @param #number coalitionId (Optional) The coalition side number ID. Default is all airbases are returned.
-- @return #table Table of DCS airbase objects. -- @return #table Table of DCS airbase objects.
@@ -1033,7 +1033,7 @@ do -- Spot
--- Sets the number that is used to define the laser code for which laser designation can track. --- Sets the number that is used to define the laser code for which laser designation can track.
-- @function [parent=#Spot] setCode -- @function [parent=#Spot] setCode
-- @param #Spot self -- @param #Spot self
-- @param #number Code The laser code. Default value is 1688. -- @param #number Code (Optional) The laser code. Default value is 1688.
--- Destroys the spot. --- Destroys the spot.
-- @function [parent=#Spot] destroy -- @function [parent=#Spot] destroy
@@ -308,7 +308,7 @@ AICSAR.RadioLength = {
-- @param #string Helotemplate Helicopter template name. -- @param #string Helotemplate Helicopter template name.
-- @param Wrapper.Airbase#AIRBASE FARP FARP object or Airbase from where to start. -- @param Wrapper.Airbase#AIRBASE FARP FARP object or Airbase from where to start.
-- @param Core.Zone#ZONE MASHZone Zone where to drop pilots after rescue. -- @param Core.Zone#ZONE MASHZone Zone where to drop pilots after rescue.
-- @param #number Helonumber Max number of alive Ai Helos at the same time. Defaults to three. -- @param #number Helonumber (Optional) Max number of alive Ai Helos at the same time. Defaults to 3.
-- @return #AICSAR self -- @return #AICSAR self
function AICSAR:New(Alias,Coalition,Pilottemplate,Helotemplate,FARP,MASHZone,Helonumber) function AICSAR:New(Alias,Coalition,Pilottemplate,Helotemplate,FARP,MASHZone,Helonumber)
-- Inherit everything from FSM class. -- Inherit everything from FSM class.
@@ -543,10 +543,10 @@ end
-- @param #AICSAR self -- @param #AICSAR self
-- @param #boolean OnOff Switch on (true) or off (false). -- @param #boolean OnOff Switch on (true) or off (false).
-- @param #string Path Path to your SRS Server External Audio Component, e.g. "C:\\\\Program Files\\\\DCS-SimpleRadio-Standalone\\\\ExternalAudio" -- @param #string Path Path to your SRS Server External Audio Component, e.g. "C:\\\\Program Files\\\\DCS-SimpleRadio-Standalone\\\\ExternalAudio"
-- @param #number Frequency Defaults to 243 (guard) -- @param #number Frequency (Optional) Defaults to 243 (guard)
-- @param #number Modulation Radio modulation. Defaults to radio.modulation.AM -- @param #number Modulation (Optional) Radio modulation. Defaults to radio.modulation.AM
-- @param #string SoundPath Where to find the audio files. Defaults to nil, i.e. add messages via "Sound to..." in the Mission Editor. -- @param #string SoundPath (Optional) Where to find the audio files. Defaults to nil, i.e. add messages via "Sound to..." in the Mission Editor.
-- @param #number Port Port of the SRS, defaults to 5002. -- @param #number Port (Optional) Port of the SRS, defaults to 5002.
-- @return #AICSAR self -- @return #AICSAR self
function AICSAR:SetSRSRadio(OnOff,Path,Frequency,Modulation,SoundPath,Port) function AICSAR:SetSRSRadio(OnOff,Path,Frequency,Modulation,SoundPath,Port)
self:T(self.lid .. "SetSRSRadio") self:T(self.lid .. "SetSRSRadio")
@@ -657,8 +657,8 @@ end
--- [User] Switch sound output on and use normale (DCS) radio --- [User] Switch sound output on and use normale (DCS) radio
-- @param #AICSAR self -- @param #AICSAR self
-- @param #boolean OnOff Switch on (true) or off (false). -- @param #boolean OnOff Switch on (true) or off (false).
-- @param #number Frequency Defaults to 243 (guard). -- @param #number Frequency(Optional) Defaults to 243 (guard).
-- @param #number Modulation Radio modulation. Defaults to radio.modulation.AM. -- @param #number Modulation (Optional) Radio modulation. Defaults to radio.modulation.AM.
-- @param Wrapper.Group#GROUP Group The group to use as sending station. -- @param Wrapper.Group#GROUP Group The group to use as sending station.
-- @return #AICSAR self -- @return #AICSAR self
function AICSAR:SetDCSRadio(OnOff,Frequency,Modulation,Group) function AICSAR:SetDCSRadio(OnOff,Frequency,Modulation,Group)
@@ -1391,7 +1391,7 @@ end
-- @param #ARTY self -- @param #ARTY self
-- @param Core.Point#COORDINATE coord Coordinates of the new position. -- @param Core.Point#COORDINATE coord Coordinates of the new position.
-- @param #string time (Optional) Day time at which the group should start moving. Passed as a string in format "08:13:45". Default is now. -- @param #string time (Optional) Day time at which the group should start moving. Passed as a string in format "08:13:45". Default is now.
-- @param #number speed (Optinal) Speed in km/h the group should move at. Default 70% of max posible speed of group. -- @param #number speed (Optional) Speed in km/h the group should move at. Default 70% of max posible speed of group.
-- @param #boolean onroad (Optional) If true, group will mainly use roads. Default off, i.e. go directly towards the specified coordinate. -- @param #boolean onroad (Optional) If true, group will mainly use roads. Default off, i.e. go directly towards the specified coordinate.
-- @param #boolean cancel (Optional) If true, cancel any running attack when move should begin. Default is false. -- @param #boolean cancel (Optional) If true, cancel any running attack when move should begin. Default is false.
-- @param #string name (Optional) Name of the coordinate. Default is LL DMS string of the coordinate. If the name was already given, the numbering "#01", "#02",... is appended automatically. -- @param #string name (Optional) Name of the coordinate. Default is LL DMS string of the coordinate. If the name was already given, the numbering "#01", "#02",... is appended automatically.
@@ -1502,7 +1502,7 @@ end
--- Set minimum firing range. Targets closer than this distance are not engaged. --- Set minimum firing range. Targets closer than this distance are not engaged.
-- @param #ARTY self -- @param #ARTY self
-- @param #number range Min range in kilometers. Default is 0.1 km. -- @param #number range (Optional) Min range in kilometers. Default is 0.1 km.
-- @return self -- @return self
function ARTY:SetMinFiringRange(range) function ARTY:SetMinFiringRange(range)
self:F({range=range}) self:F({range=range})
@@ -1512,7 +1512,7 @@ end
--- Set maximum firing range. Targets further away than this distance are not engaged. --- Set maximum firing range. Targets further away than this distance are not engaged.
-- @param #ARTY self -- @param #ARTY self
-- @param #number range Max range in kilometers. Default is 1000 km. -- @param #number range (Optional) Max range in kilometers. Default is 1000 km.
-- @return self -- @return self
function ARTY:SetMaxFiringRange(range) function ARTY:SetMaxFiringRange(range)
self:F({range=range}) self:F({range=range})
@@ -1522,7 +1522,7 @@ end
--- Set time interval between status updates. During the status check, new events are triggered. --- Set time interval between status updates. During the status check, new events are triggered.
-- @param #ARTY self -- @param #ARTY self
-- @param #number interval Time interval in seconds. Default 10 seconds. -- @param #number interval (Optional) Time interval in seconds. Default 10 seconds.
-- @return self -- @return self
function ARTY:SetStatusInterval(interval) function ARTY:SetStatusInterval(interval)
self:F({interval=interval}) self:F({interval=interval})
@@ -1532,7 +1532,7 @@ end
--- Set time interval for weapon tracking. --- Set time interval for weapon tracking.
-- @param #ARTY self -- @param #ARTY self
-- @param #number interval Time interval in seconds. Default 0.2 seconds. -- @param #number interval (Optional) Time interval in seconds. Default 0.2 seconds.
-- @return self -- @return self
function ARTY:SetTrackInterval(interval) function ARTY:SetTrackInterval(interval)
self.dtTrack=interval or 0.2 self.dtTrack=interval or 0.2
@@ -1541,7 +1541,7 @@ end
--- Set time how it is waited a unit the first shot event happens. If no shot is fired after this time, the task to fire is aborted and the target removed. --- Set time how it is waited a unit the first shot event happens. If no shot is fired after this time, the task to fire is aborted and the target removed.
-- @param #ARTY self -- @param #ARTY self
-- @param #number waittime Time in seconds. Default 300 seconds. -- @param #number waittime (Optional) Time in seconds. Default 300 seconds.
-- @return self -- @return self
function ARTY:SetWaitForShotTime(waittime) function ARTY:SetWaitForShotTime(waittime)
self:F({waittime=waittime}) self:F({waittime=waittime})
@@ -1551,7 +1551,7 @@ end
--- Define the safe distance between ARTY group and rearming unit or rearming place at which rearming process is possible. --- Define the safe distance between ARTY group and rearming unit or rearming place at which rearming process is possible.
-- @param #ARTY self -- @param #ARTY self
-- @param #number distance Safe distance in meters. Default is 100 m. -- @param #number distance (Optional) Safe distance in meters. Default is 100 m.
-- @return self -- @return self
function ARTY:SetRearmingDistance(distance) function ARTY:SetRearmingDistance(distance)
self:F({distance=distance}) self:F({distance=distance})
@@ -1813,7 +1813,7 @@ end
--- Set nuclear warhead explosion strength. --- Set nuclear warhead explosion strength.
-- @param #ARTY self -- @param #ARTY self
-- @param #number strength Explosion strength in kilo tons TNT. Default is 0.075 kt. -- @param #number strength (Optional) Explosion strength in kilo tons TNT. Default is 0.075 kt.
-- @return self -- @return self
function ARTY:SetTacNukeWarhead(strength) function ARTY:SetTacNukeWarhead(strength)
self.nukewarhead=strength or 0.075 self.nukewarhead=strength or 0.075
@@ -3903,7 +3903,7 @@ end
--- Get the number of shells a unit or group currently has. For a group the ammo count of all units is summed up. --- Get the number of shells a unit or group currently has. For a group the ammo count of all units is summed up.
-- @param #ARTY self -- @param #ARTY self
-- @param #boolean display Display ammo table as message to all. Default false. -- @param #boolean display (Optional) Display ammo table as message to all. Default false.
-- @return #number Total amount of ammo the whole group has left. -- @return #number Total amount of ammo the whole group has left.
-- @return #number Number of shells the group has left. -- @return #number Number of shells the group has left.
-- @return #number Number of rockets the group has left. -- @return #number Number of rockets the group has left.
@@ -427,7 +427,7 @@ end
--- (User) Set minimum threat level for target selection, can be 0 (lowest) to 10 (highest). --- (User) Set minimum threat level for target selection, can be 0 (lowest) to 10 (highest).
-- @param #AUTOLASE self -- @param #AUTOLASE self
-- @param #number Level Level used for filtering, defaults to 0. SAM systems and manpads have level 7 to 10, AAA level 6, MTBs and armoured vehicles level 3 to 5, APC, Artillery, Infantry and EWR level 1 to 2. -- @param #number Level (Optional) Level used for filtering, defaults to 0. SAM systems and manpads have level 7 to 10, AAA level 6, MTBs and armoured vehicles level 3 to 5, APC, Artillery, Infantry and EWR level 1 to 2.
-- @return #AUTOLASE self -- @return #AUTOLASE self
-- @usage Filter for level 3 and above: -- @usage Filter for level 3 and above:
-- `myautolase:SetMinThreatLevel(3)` -- `myautolase:SetMinThreatLevel(3)`
@@ -593,8 +593,8 @@ end
--- (User) Function to force laser cooldown and cool down time --- (User) Function to force laser cooldown and cool down time
-- @param #AUTOLASE self -- @param #AUTOLASE self
-- @param #boolean OnOff Switch cool down on (true) or off (false) - defaults to true -- @param #boolean OnOff (Optional) Switch cool down on (true) or off (false) - defaults to true
-- @param #number Seconds Number of seconds for cooldown - dafaults to 60 seconds -- @param #number Seconds (Optional) Number of seconds for cooldown - dafaults to 60 seconds
-- @return #AUTOLASE self -- @return #AUTOLASE self
function AUTOLASE:SetLaserCoolDown(OnOff, Seconds) function AUTOLASE:SetLaserCoolDown(OnOff, Seconds)
self.forcecooldown = OnOff and true self.forcecooldown = OnOff and true
@@ -615,8 +615,8 @@ end
--- (User) Function to set lasing distance in meters and duration in seconds --- (User) Function to set lasing distance in meters and duration in seconds
-- @param #AUTOLASE self -- @param #AUTOLASE self
-- @param #number Distance (Max) distance for lasing in meters - default 5000 meters -- @param #number Distance (Optional) Max distance for lasing in meters - default 5000 meters
-- @param #number Duration (Max) duration for lasing in seconds - default 300 secs -- @param #number Duration (Optional) Max duration for lasing in seconds - default 300 secs
-- @return #AUTOLASE self -- @return #AUTOLASE self
function AUTOLASE:SetLasingParameters(Distance, Duration) function AUTOLASE:SetLasingParameters(Distance, Duration)
self.LaseDistance = Distance or 5000 self.LaseDistance = Distance or 5000
@@ -640,7 +640,7 @@ end
--- (User) Function to set rounding precision for BR distance output. --- (User) Function to set rounding precision for BR distance output.
-- @param #AUTOLASE self -- @param #AUTOLASE self
-- @param #number IDP Rounding precision before/after the decimal sign. Defaults to zero. Positive values round right of the decimal sign, negative ones left of the decimal sign. -- @param #number IDP (Optional) Rounding precision before/after the decimal sign. Defaults to zero. Positive values round right of the decimal sign, negative ones left of the decimal sign.
-- @return #AUTOLASE self -- @return #AUTOLASE self
function AUTOLASE:SetRoundingPrecsion(IDP) function AUTOLASE:SetRoundingPrecsion(IDP)
self.RoundingPrecision = IDP or 0 self.RoundingPrecision = IDP or 0
@@ -178,7 +178,7 @@ end
-- Note, one can also use the method @{#CLEANUP_AIRBASE.RemoveAirbase}() to remove the airbase from the control process as a whole, -- Note, one can also use the method @{#CLEANUP_AIRBASE.RemoveAirbase}() to remove the airbase from the control process as a whole,
-- when an enemy unit is near. That is also an option... -- when an enemy unit is near. That is also an option...
-- @param #CLEANUP_AIRBASE self -- @param #CLEANUP_AIRBASE self
-- @param #string CleanMissiles (Default=true) If true, missiles fired are immediately destroyed. If false missiles are not controlled. -- @param #boolean CleanMissiles (Optional) (Default=true) If true, missiles fired are immediately destroyed. If false missiles are not controlled.
-- @return #CLEANUP_AIRBASE -- @return #CLEANUP_AIRBASE
function CLEANUP_AIRBASE:SetCleanMissiles( CleanMissiles ) function CLEANUP_AIRBASE:SetCleanMissiles( CleanMissiles )
@@ -301,12 +301,11 @@ do -- DESIGNATE
--- DESIGNATE Constructor. This class is an abstract class and should not be instantiated. --- DESIGNATE Constructor. This class is an abstract class and should not be instantiated.
-- @param #DESIGNATE self -- @param #DESIGNATE self
-- @param Tasking.CommandCenter#COMMANDCENTER CC -- @param Wrapper.Group#GROUP CC Group as Commandcenter standin. Currently unused (03/2026)
-- @param Functional.Detection#DETECTION_BASE Detection -- @param Functional.Detection#DETECTION_BASE Detection
-- @param Core.Set#SET_GROUP AttackSet The Attack collection of GROUP objects to designate and report for. -- @param Core.Set#SET_GROUP AttackSet The Attack collection of GROUP objects to designate and report for.
-- @param Tasking.Mission#MISSION Mission (Optional) The Mission where the menu needs to be attached.
-- @return #DESIGNATE -- @return #DESIGNATE
function DESIGNATE:New( CC, Detection, AttackSet, Mission ) function DESIGNATE:New( CC, Detection, AttackSet )
local self = BASE:Inherit( self, FSM:New() ) -- #DESIGNATE local self = BASE:Inherit( self, FSM:New() ) -- #DESIGNATE
self:F( { Detection } ) self:F( { Detection } )
@@ -468,7 +467,7 @@ do -- DESIGNATE
-- @param #DESIGNATE self -- @param #DESIGNATE self
-- @param #number Delay -- @param #number Delay
self.CC = CC --self.CC = CC
self.Detection = Detection self.Detection = Detection
self.AttackSet = AttackSet self.AttackSet = AttackSet
self.RecceSet = Detection:GetDetectionSet() self.RecceSet = Detection:GetDetectionSet()
@@ -480,7 +479,7 @@ do -- DESIGNATE
self:SetFlashStatusMenu( false ) self:SetFlashStatusMenu( false )
self:SetFlashDetectionMessages( true ) self:SetFlashDetectionMessages( true )
self:SetMission( Mission ) --self:SetMission( Mission )
self:SetLaserCodes( { 1688, 1130, 4785, 6547, 1465, 4578 } ) -- set self.LaserCodes self:SetLaserCodes( { 1688, 1130, 4785, 6547, 1465, 4578 } ) -- set self.LaserCodes
self:SetAutoLase( false, false ) -- set self.Autolase and don't send message. self:SetAutoLase( false, false ) -- set self.Autolase and don't send message.
@@ -682,7 +681,7 @@ do -- DESIGNATE
--- Set the lase duration for designations. --- Set the lase duration for designations.
-- @param #DESIGNATE self -- @param #DESIGNATE self
-- @param #number LaseDuration The time in seconds a lase will continue to hold on target. The default is 120 seconds. -- @param #number LaseDuration (Optional) The time in seconds a lase will continue to hold on target. The default is 120 seconds.
-- @return #DESIGNATE -- @return #DESIGNATE
function DESIGNATE:SetLaseDuration( LaseDuration ) function DESIGNATE:SetLaseDuration( LaseDuration )
self.LaseDuration = LaseDuration or 120 self.LaseDuration = LaseDuration or 120
@@ -754,10 +753,12 @@ do -- DESIGNATE
if Message then if Message then
local AutoLaseOnOff = ( self.AutoLase == true ) and "On" or "Off" local AutoLaseOnOff = ( self.AutoLase == true ) and "On" or "Off"
local CC = self.CC:GetPositionable()
if CC then MESSAGE:New(self.DesignateName .. ": Auto Lase " .. AutoLaseOnOff .. ".",15):ToSet(self.AttackSet)
CC:MessageToSetGroup( self.DesignateName .. ": Auto Lase " .. AutoLaseOnOff .. ".", 15, self.AttackSet ) --local CC = self.CC:GetPositionable()
end --if CC then
--CC:MessageToSetGroup( self.DesignateName .. ": Auto Lase " .. AutoLaseOnOff .. ".", 15, self.AttackSet )
--end
end end
self:CoordinateLase() self:CoordinateLase()
@@ -777,14 +778,14 @@ do -- DESIGNATE
return self return self
end end
--- Set the MISSION object for which designate will function. --- [DEPRECATED DO NOT USE] Set the MISSION object for which designate will function.
-- When a MISSION object is assigned, the menu for the designation will be located at the Mission Menu. -- When a MISSION object is assigned, the menu for the designation will be located at the Mission Menu.
-- @param #DESIGNATE self -- @param #DESIGNATE self
-- @param Tasking.Mission#MISSION Mission The MISSION object. -- @param Tasking.Mission#MISSION Mission The MISSION object.
-- @return #DESIGNATE -- @return #DESIGNATE
function DESIGNATE:SetMission( Mission ) --R2.2 function DESIGNATE:SetMission( Mission ) --R2.2
self.Mission = Mission --self.Mission = Mission
return self return self
end end
@@ -830,7 +831,8 @@ do -- DESIGNATE
function( AttackGroup ) function( AttackGroup )
if AttackGroup:IsAlive() == true then if AttackGroup:IsAlive() == true then
local DetectionText = self.Detection:DetectedItemReportSummary( DetectedItem, AttackGroup ):Text( ", " ) local DetectionText = self.Detection:DetectedItemReportSummary( DetectedItem, AttackGroup ):Text( ", " )
self.CC:GetPositionable():MessageToGroup( "Targets out of LOS\n" .. DetectionText, 10, AttackGroup, self.DesignateName ) --self.CC:GetPositionable():MessageToGroup( "Targets out of LOS\n" .. DetectionText, 10, AttackGroup, self.DesignateName )
MESSAGE:New("Targets out of LOS\n" .. DetectionText,10,self.DesignateName):ToGroup(AttackGroup)
end end
end end
) )
@@ -855,7 +857,8 @@ do -- DESIGNATE
function( AttackGroup ) function( AttackGroup )
if self.FlashDetectionMessage[AttackGroup] == true then if self.FlashDetectionMessage[AttackGroup] == true then
local DetectionText = self.Detection:DetectedItemReportSummary( DetectedItem, AttackGroup ):Text( ", " ) local DetectionText = self.Detection:DetectedItemReportSummary( DetectedItem, AttackGroup ):Text( ", " )
self.CC:GetPositionable():MessageToGroup( "Targets detected at \n" .. DetectionText, 10, AttackGroup, self.DesignateName ) --self.CC:GetPositionable():MessageToGroup( "Targets detected at \n" .. DetectionText, 10, AttackGroup, self.DesignateName )
MESSAGE:New( "Targets detected at \n" .. DetectionText,10,self.DesignateName):ToGroup(AttackGroup)
end end
end end
) )
@@ -929,9 +932,10 @@ do -- DESIGNATE
end end
end end
local CC = self.CC:GetPositionable() -- local CC = self.CC:GetPositionable()
CC:MessageTypeToGroup( DetectedReport:Text( "\n" ), MESSAGE.Type.Information, AttackGroup, self.DesignateName ) --CC:MessageTypeToGroup( DetectedReport:Text( "\n" ), MESSAGE.Type.Information, AttackGroup, self.DesignateName )
MESSAGE:New( DetectedReport:Text( "\n" ),15,self.DesignateName):ToGroup(AttackGroup)
local DesignationReport = REPORT:New( "Marking Targets:" ) local DesignationReport = REPORT:New( "Marking Targets:" )
@@ -965,10 +969,10 @@ do -- DESIGNATE
local MissionMenu = nil local MissionMenu = nil
if self.Mission then --if self.Mission then
--MissionMenu = self.Mission:GetRootMenu( AttackGroup ) --MissionMenu = self.Mission:GetRootMenu( AttackGroup )
MissionMenu = self.Mission:GetMenu( AttackGroup ) --MissionMenu = self.Mission:GetMenu( AttackGroup )
end --end
local MenuTime = timer.getTime() local MenuTime = timer.getTime()
@@ -1357,11 +1361,12 @@ do -- DESIGNATE
-- @return #DESIGNATE -- @return #DESIGNATE
function DESIGNATE:onafterLaseOff( From, Event, To, Index ) function DESIGNATE:onafterLaseOff( From, Event, To, Index )
local CC = self.CC:GetPositionable() MESSAGE:New("Stopped lasing.",5,self.DesignateName):ToSet(self.AttackSet)
--local CC = self.CC:GetPositionable()
if CC then --if CC then
CC:MessageToSetGroup( "Stopped lasing.", 5, self.AttackSet, self.DesignateName ) --CC:MessageToSetGroup( "Stopped lasing.", 5, self.AttackSet, self.DesignateName )
end --end
local DetectedItem = self.Detection:GetDetectedItemByIndex( Index ) local DetectedItem = self.Detection:GetDetectedItemByIndex( Index )
local TargetSetUnit = self.Detection:GetDetectedItemSet( DetectedItem ) local TargetSetUnit = self.Detection:GetDetectedItemSet( DetectedItem )
@@ -1052,9 +1052,9 @@ do -- DETECTION_BASE
--- Method to make the radar detection less accurate, e.g. for WWII scenarios. --- Method to make the radar detection less accurate, e.g. for WWII scenarios.
-- @param #DETECTION_BASE self -- @param #DETECTION_BASE self
-- @param #number minheight Minimum flight height to be detected, in meters AGL (above ground) -- @param #number minheight Minimum flight height to be detected, in meters AGL (above ground)
-- @param #number thresheight Threshold to escape the radar if flying below minheight, defaults to 90 (90% escape chance) -- @param #number thresheight (Optional) Threshold to escape the radar if flying below minheight, defaults to 90 (90% escape chance)
-- @param #number thresblur Threshold to be detected by the radar overall, defaults to 85 (85% chance to be found) -- @param #number thresblur (Optional) Threshold to be detected by the radar overall, defaults to 85 (85% chance to be found)
-- @param #number closing Closing-in in km - the limit of km from which on it becomes increasingly difficult to escape radar detection if flying towards the radar position. Should be about 1/3 of the radar detection radius in kilometers, defaults to 20. -- @param #number closing (Optional) Closing-in in km - the limit of km from which on it becomes increasingly difficult to escape radar detection if flying towards the radar position. Should be about 1/3 of the radar detection radius in kilometers, defaults to 20.
-- @return #DETECTION_BASE self -- @return #DETECTION_BASE self
function DETECTION_BASE:SetRadarBlur(minheight,thresheight,thresblur,closing) function DETECTION_BASE:SetRadarBlur(minheight,thresheight,thresblur,closing)
self.RadarBlur = true self.RadarBlur = true
@@ -1104,12 +1104,14 @@ do -- DETECTION_BASE
--- Set the parameters to calculate to optimal intercept point. --- Set the parameters to calculate to optimal intercept point.
-- @param #DETECTION_BASE self -- @param #DETECTION_BASE self
-- @param #boolean Intercept Intercept is true if an intercept point is calculated. Intercept is false if it is disabled. The default Intercept is false. -- @param #boolean Intercept (Optional) Intercept is true if an intercept point is calculated. Intercept is false if it is disabled. The default Intercept is false.
-- @param #number InterceptDelay If Intercept is true, then InterceptDelay is the average time it takes to get airplanes airborne. -- @param #number InterceptDelay If Intercept is true, then InterceptDelay is the average time it takes to get airplanes airborne.
-- @return #DETECTION_BASE self -- @return #DETECTION_BASE self
function DETECTION_BASE:SetIntercept( Intercept, InterceptDelay ) function DETECTION_BASE:SetIntercept( Intercept, InterceptDelay )
self:F2() self:F2()
Intercept = Intercept or false
self.Intercept = Intercept self.Intercept = Intercept
self.InterceptDelay = InterceptDelay self.InterceptDelay = InterceptDelay
@@ -1611,8 +1613,8 @@ do -- DETECTION_BASE
-- The DetectedItem is a table and contains a SET_UNIT in the field Set. -- The DetectedItem is a table and contains a SET_UNIT in the field Set.
-- @param #DETECTION_BASE self -- @param #DETECTION_BASE self
-- @param #string ItemPrefix Prefix of detected item. -- @param #string ItemPrefix Prefix of detected item.
-- @param #number DetectedItemKey The key of the DetectedItem. Default self.DetectedItemMax. Could also be a string in principle. -- @param #number DetectedItemKey (Optional) The key of the DetectedItem. Default self.DetectedItemMax. Could also be a string in principle.
-- @param Core.Set#SET_UNIT Set (optional) The Set of Units to be added. -- @param Core.Set#SET_UNIT Set (Optional) The Set of Units to be added.
-- @return #DETECTION_BASE.DetectedItem -- @return #DETECTION_BASE.DetectedItem
function DETECTION_BASE:AddDetectedItem( ItemPrefix, DetectedItemKey, Set ) function DETECTION_BASE:AddDetectedItem( ItemPrefix, DetectedItemKey, Set )
@@ -2536,7 +2538,7 @@ do -- DETECTION_AREAS
--- DETECTION_AREAS constructor. --- DETECTION_AREAS constructor.
-- @param #DETECTION_AREAS self -- @param #DETECTION_AREAS self
-- @param Core.Set#SET_GROUP DetectionSetGroup The @{Core.Set} of GROUPs in the Forward Air Controller role. -- @param Core.Set#SET_GROUP DetectionSetGroup The @{Core.Set} of GROUPs in the Forward Air Controller role.
-- @param #number DetectionZoneRange The range in meters within which targets are grouped upon the first detected target. Default 5000m. -- @param #number DetectionZoneRange (Optional) The range in meters within which targets are grouped upon the first detected target. Default 5000m.
-- @return #DETECTION_AREAS -- @return #DETECTION_AREAS
function DETECTION_AREAS:New( DetectionSetGroup, DetectionZoneRange ) function DETECTION_AREAS:New( DetectionSetGroup, DetectionZoneRange )
+63 -75
View File
@@ -179,7 +179,7 @@ ESCORT = {
-- @param Wrapper.Client#CLIENT EscortClient The client escorted by the EscortGroup. -- @param Wrapper.Client#CLIENT EscortClient The client escorted by the EscortGroup.
-- @param Wrapper.Group#GROUP EscortGroup The group AI escorting the EscortClient. -- @param Wrapper.Group#GROUP EscortGroup The group AI escorting the EscortClient.
-- @param #string EscortName Name of the escort. -- @param #string EscortName Name of the escort.
-- @param #string EscortBriefing A text showing the ESCORT briefing to the player. Note that if no EscortBriefing is provided, the default briefing will be shown. -- @param #string EscortBriefing (Optional) A text showing the ESCORT briefing to the player. Note that if no EscortBriefing is provided, the default briefing will be shown.
-- @return #ESCORT self -- @return #ESCORT self
-- @usage -- @usage
-- -- Declare a new EscortPlanes object as follows: -- -- Declare a new EscortPlanes object as follows:
@@ -193,7 +193,7 @@ ESCORT = {
function ESCORT:New( EscortClient, EscortGroup, EscortName, EscortBriefing ) function ESCORT:New( EscortClient, EscortGroup, EscortName, EscortBriefing )
local self = BASE:Inherit( self, BASE:New() ) -- #ESCORT local self = BASE:Inherit( self, BASE:New() ) -- #ESCORT
--self:F( { EscortClient, EscortGroup, EscortName } ) self:F( { EscortClient, EscortGroup, EscortName } )
self.EscortClient = EscortClient -- Wrapper.Client#CLIENT self.EscortClient = EscortClient -- Wrapper.Client#CLIENT
self.EscortGroup = EscortGroup -- Wrapper.Group#GROUP self.EscortGroup = EscortGroup -- Wrapper.Group#GROUP
@@ -202,7 +202,7 @@ function ESCORT:New( EscortClient, EscortGroup, EscortName, EscortBriefing )
self.EscortSetGroup = SET_GROUP:New() self.EscortSetGroup = SET_GROUP:New()
self.EscortSetGroup:AddObject( self.EscortGroup ) self.EscortSetGroup:AddObject( self.EscortGroup )
--self.EscortSetGroup:Flush() self.EscortSetGroup:Flush()
self.Detection = DETECTION_UNITS:New( self.EscortSetGroup, 15000 ) self.Detection = DETECTION_UNITS:New( self.EscortSetGroup, 15000 )
self.EscortGroup.Detection = self.Detection self.EscortGroup.Detection = self.Detection
@@ -242,11 +242,12 @@ function ESCORT:New( EscortClient, EscortGroup, EscortName, EscortBriefing )
self.CT1 = 0 self.CT1 = 0
self.GT1 = 0 self.GT1 = 0
self.FollowScheduler, self.FollowSchedule = SCHEDULER:New( self, self._FollowScheduler, {}, 1, 2, .01 ) self.FollowScheduler, self.FollowSchedule = SCHEDULER:New( self, self._FollowScheduler, {}, 1, .5, .01 )
self.FollowScheduler:Stop( self.FollowSchedule ) self.FollowScheduler:Stop( self.FollowSchedule )
self.EscortMode = ESCORT.MODE.MISSION self.EscortMode = ESCORT.MODE.MISSION
return self return self
end end
@@ -272,11 +273,12 @@ function ESCORT:TestSmokeDirectionVector( SmokeDirection )
self.SmokeDirectionVector = ( SmokeDirection == true ) and true or false self.SmokeDirectionVector = ( SmokeDirection == true ) and true or false
end end
--- Defines the default menus --- Defines the default menus
-- @param #ESCORT self -- @param #ESCORT self
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:Menus() function ESCORT:Menus()
--self:F() self:F()
self:MenuFollowAt( 100 ) self:MenuFollowAt( 100 )
self:MenuFollowAt( 200 ) self:MenuFollowAt( 200 )
@@ -297,16 +299,19 @@ function ESCORT:Menus()
self:MenuEvasion() self:MenuEvasion()
self:MenuResumeMission() self:MenuResumeMission()
return self return self
end end
--- Defines a menu slot to let the escort Join and Follow you at a certain distance. --- Defines a menu slot to let the escort Join and Follow you at a certain distance.
-- This menu will appear under **Navigation**. -- This menu will appear under **Navigation**.
-- @param #ESCORT self -- @param #ESCORT self
-- @param DCS#Distance Distance The distance in meters that the escort needs to follow the client. -- @param DCS#Distance Distance The distance in meters that the escort needs to follow the client.
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuFollowAt( Distance ) function ESCORT:MenuFollowAt( Distance )
--self:F(Distance) self:F(Distance)
if self.EscortGroup:IsAir() then if self.EscortGroup:IsAir() then
if not self.EscortMenuReportNavigation then if not self.EscortMenuReportNavigation then
@@ -328,13 +333,13 @@ end
--- Defines a menu slot to let the escort hold at their current position and stay low with a specified height during a specified time in seconds. --- Defines a menu slot to let the escort hold at their current position and stay low with a specified height during a specified time in seconds.
-- This menu will appear under **Hold position**. -- This menu will appear under **Hold position**.
-- @param #ESCORT self -- @param #ESCORT self
-- @param DCS#Distance Height Optional parameter that sets the height in meters to let the escort orbit at the current location. The default value is 30 meters. -- @param DCS#Distance Height (Optional) parameter that sets the height in meters to let the escort orbit at the current location. The default value is 30 meters.
-- @param DCS#Time Seconds Optional parameter that lets the escort orbit at the current position for a specified time. (not implemented yet). The default value is 0 seconds, meaning, that the escort will orbit forever until a sequent command is given. -- @param DCS#Time Seconds (Optional) parameter that lets the escort orbit at the current position for a specified time. (not implemented yet). The default value is 0 seconds, meaning, that the escort will orbit forever until a sequent command is given.
-- @param #string MenuTextFormat Optional parameter that shows the menu option text. The text string is formatted, and should contain two %d tokens in the string. The first for the Height, the second for the Time (if given). If no text is given, the default text will be displayed. -- @param #string MenuTextFormat (Optional) parameter that shows the menu option text. The text string is formatted, and should contain two %d tokens in the string. The first for the Height, the second for the Time (if given). If no text is given, the default text will be displayed.
-- @return #ESCORT self -- @return #ESCORT
-- TODO: Implement Seconds parameter. Challenge is to first develop the "continue from last activity" function. -- TODO: Implement Seconds parameter. Challenge is to first develop the "continue from last activity" function.
function ESCORT:MenuHoldAtEscortPosition( Height, Seconds, MenuTextFormat ) function ESCORT:MenuHoldAtEscortPosition( Height, Seconds, MenuTextFormat )
--self:F( { Height, Seconds, MenuTextFormat } ) self:F( { Height, Seconds, MenuTextFormat } )
if self.EscortGroup:IsAir() then if self.EscortGroup:IsAir() then
@@ -385,16 +390,17 @@ function ESCORT:MenuHoldAtEscortPosition( Height, Seconds, MenuTextFormat )
return self return self
end end
--- Defines a menu slot to let the escort hold at the client position and stay low with a specified height during a specified time in seconds. --- Defines a menu slot to let the escort hold at the client position and stay low with a specified height during a specified time in seconds.
-- This menu will appear under **Navigation**. -- This menu will appear under **Navigation**.
-- @param #ESCORT self -- @param #ESCORT self
-- @param DCS#Distance Height Optional parameter that sets the height in meters to let the escort orbit at the current location. The default value is 30 meters. -- @param DCS#Distance Height (Optional) parameter that sets the height in meters to let the escort orbit at the current location. The default value is 30 meters.
-- @param DCS#Time Seconds Optional parameter that lets the escort orbit at the current position for a specified time. (not implemented yet). The default value is 0 seconds, meaning, that the escort will orbit forever until a sequent command is given. -- @param DCS#Time Seconds (Optional) parameter that lets the escort orbit at the current position for a specified time. (not implemented yet). The default value is 0 seconds, meaning, that the escort will orbit forever until a sequent command is given.
-- @param #string MenuTextFormat Optional parameter that shows the menu option text. The text string is formatted, and should contain one or two %d tokens in the string. The first for the Height, the second for the Time (if given). If no text is given, the default text will be displayed. -- @param #string MenuTextFormat (Optional) parameter that shows the menu option text. The text string is formatted, and should contain one or two %d tokens in the string. The first for the Height, the second for the Time (if given). If no text is given, the default text will be displayed.
-- @return #ESCORT self -- @return #ESCORT
-- TODO: Implement Seconds parameter. Challenge is to first develop the "continue from last activity" function. -- TODO: Implement Seconds parameter. Challenge is to first develop the "continue from last activity" function.
function ESCORT:MenuHoldAtLeaderPosition( Height, Seconds, MenuTextFormat ) function ESCORT:MenuHoldAtLeaderPosition( Height, Seconds, MenuTextFormat )
--self:F( { Height, Seconds, MenuTextFormat } ) self:F( { Height, Seconds, MenuTextFormat } )
if self.EscortGroup:IsAir() then if self.EscortGroup:IsAir() then
@@ -449,12 +455,12 @@ end
--- Defines a menu slot to let the escort scan for targets at a certain height for a certain time in seconds. --- Defines a menu slot to let the escort scan for targets at a certain height for a certain time in seconds.
-- This menu will appear under **Scan targets**. -- This menu will appear under **Scan targets**.
-- @param #ESCORT self -- @param #ESCORT self
-- @param DCS#Distance Height Optional parameter that sets the height in meters to let the escort orbit at the current location. The default value is 30 meters. -- @param DCS#Distance Height (Optional) parameter that sets the height in meters to let the escort orbit at the current location. The default value is 30 meters.
-- @param DCS#Time Seconds Optional parameter that lets the escort orbit at the current position for a specified time. (not implemented yet). The default value is 0 seconds, meaning, that the escort will orbit forever until a sequent command is given. -- @param DCS#Time Seconds (Optional) parameter that lets the escort orbit at the current position for a specified time. (not implemented yet). The default value is 0 seconds, meaning, that the escort will orbit forever until a sequent command is given.
-- @param #string MenuTextFormat Optional parameter that shows the menu option text. The text string is formatted, and should contain one or two %d tokens in the string. The first for the Height, the second for the Time (if given). If no text is given, the default text will be displayed. -- @param #string MenuTextFormat (Optional) parameter that shows the menu option text. The text string is formatted, and should contain one or two %d tokens in the string. The first for the Height, the second for the Time (if given). If no text is given, the default text will be displayed.
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuScanForTargets( Height, Seconds, MenuTextFormat ) function ESCORT:MenuScanForTargets( Height, Seconds, MenuTextFormat )
--self:F( { Height, Seconds, MenuTextFormat } ) self:F( { Height, Seconds, MenuTextFormat } )
if self.EscortGroup:IsAir() then if self.EscortGroup:IsAir() then
if not self.EscortMenuScan then if not self.EscortMenuScan then
@@ -502,14 +508,16 @@ function ESCORT:MenuScanForTargets( Height, Seconds, MenuTextFormat )
return self return self
end end
--- Defines a menu slot to let the escort disperse a flare in a certain color. --- Defines a menu slot to let the escort disperse a flare in a certain color.
-- This menu will appear under **Navigation**. -- This menu will appear under **Navigation**.
-- The flare will be fired from the first unit in the group. -- The flare will be fired from the first unit in the group.
-- @param #ESCORT self -- @param #ESCORT self
-- @param #string MenuTextFormat Optional parameter that shows the menu option text. If no text is given, the default text will be displayed. -- @param #string MenuTextFormat (Optional) parameter that shows the menu option text. If no text is given, the default text will be displayed.
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuFlare( MenuTextFormat ) function ESCORT:MenuFlare( MenuTextFormat )
----self:F() self:F()
if not self.EscortMenuReportNavigation then if not self.EscortMenuReportNavigation then
self.EscortMenuReportNavigation = MENU_GROUP:New( self.EscortClient:GetGroup(), "Navigation", self.EscortMenu ) self.EscortMenuReportNavigation = MENU_GROUP:New( self.EscortClient:GetGroup(), "Navigation", self.EscortMenu )
@@ -538,10 +546,10 @@ end
-- Note that smoke menu options will only be displayed for ships and ground units. Not for air units. -- Note that smoke menu options will only be displayed for ships and ground units. Not for air units.
-- The smoke will be fired from the first unit in the group. -- The smoke will be fired from the first unit in the group.
-- @param #ESCORT self -- @param #ESCORT self
-- @param #string MenuTextFormat Optional parameter that shows the menu option text. If no text is given, the default text will be displayed. -- @param #string MenuTextFormat (Optional) parameter that shows the menu option text. If no text is given, the default text will be displayed.
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuSmoke( MenuTextFormat ) function ESCORT:MenuSmoke( MenuTextFormat )
----self:F() self:F()
if not self.EscortGroup:IsAir() then if not self.EscortGroup:IsAir() then
if not self.EscortMenuReportNavigation then if not self.EscortMenuReportNavigation then
@@ -572,10 +580,10 @@ end
-- This menu will appear under **Report targets**. -- This menu will appear under **Report targets**.
-- Note that if a report targets menu is not specified, no targets will be detected by the escort, and the attack and assisted attack menus will not be displayed. -- Note that if a report targets menu is not specified, no targets will be detected by the escort, and the attack and assisted attack menus will not be displayed.
-- @param #ESCORT self -- @param #ESCORT self
-- @param DCS#Time Seconds Optional parameter that lets the escort report their current detected targets after specified time interval in seconds. The default time is 30 seconds. -- @param DCS#Time Seconds (Optional) parameter that lets the escort report their current detected targets after specified time interval in seconds. The default time is 30 seconds.
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuReportTargets( Seconds ) function ESCORT:MenuReportTargets( Seconds )
--self:F( { Seconds } ) self:F( { Seconds } )
if not self.EscortMenuReportNearbyTargets then if not self.EscortMenuReportNearbyTargets then
self.EscortMenuReportNearbyTargets = MENU_GROUP:New( self.EscortClient:GetGroup(), "Report targets", self.EscortMenu ) self.EscortMenuReportNearbyTargets = MENU_GROUP:New( self.EscortClient:GetGroup(), "Report targets", self.EscortMenu )
@@ -593,6 +601,7 @@ function ESCORT:MenuReportTargets( Seconds )
-- Attack Targets -- Attack Targets
self.EscortMenuAttackNearbyTargets = MENU_GROUP:New( self.EscortClient:GetGroup(), "Attack targets", self.EscortMenu ) self.EscortMenuAttackNearbyTargets = MENU_GROUP:New( self.EscortClient:GetGroup(), "Attack targets", self.EscortMenu )
self.ReportTargetsScheduler, self.ReportTargetsSchedulerID = SCHEDULER:New( self, self._ReportTargetsScheduler, {}, 1, Seconds ) self.ReportTargetsScheduler, self.ReportTargetsSchedulerID = SCHEDULER:New( self, self._ReportTargetsScheduler, {}, 1, Seconds )
return self return self
@@ -602,9 +611,9 @@ end
-- This menu will appear under **Request assistance from**. -- This menu will appear under **Request assistance from**.
-- Note that this method needs to be preceded with the method MenuReportTargets. -- Note that this method needs to be preceded with the method MenuReportTargets.
-- @param #ESCORT self -- @param #ESCORT self
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuAssistedAttack() function ESCORT:MenuAssistedAttack()
--self:F() self:F()
-- Request assistance from other escorts. -- Request assistance from other escorts.
-- This is very useful to let f.e. an escorting ship attack a target detected by an escorting plane... -- This is very useful to let f.e. an escorting ship attack a target detected by an escorting plane...
@@ -616,9 +625,9 @@ end
--- Defines a menu to let the escort set its rules of engagement. --- Defines a menu to let the escort set its rules of engagement.
-- All rules of engagement will appear under the menu **ROE**. -- All rules of engagement will appear under the menu **ROE**.
-- @param #ESCORT self -- @param #ESCORT self
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuROE( MenuTextFormat ) function ESCORT:MenuROE( MenuTextFormat )
--self:F( MenuTextFormat ) self:F( MenuTextFormat )
if not self.EscortMenuROE then if not self.EscortMenuROE then
-- Rules of Engagement -- Rules of Engagement
@@ -640,12 +649,13 @@ function ESCORT:MenuROE( MenuTextFormat )
return self return self
end end
--- Defines a menu to let the escort set its evasion when under threat. --- Defines a menu to let the escort set its evasion when under threat.
-- All rules of engagement will appear under the menu **Evasion**. -- All rules of engagement will appear under the menu **Evasion**.
-- @param #ESCORT self -- @param #ESCORT self
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuEvasion( MenuTextFormat ) function ESCORT:MenuEvasion( MenuTextFormat )
--self:F( MenuTextFormat ) self:F( MenuTextFormat )
if self.EscortGroup:IsAir() then if self.EscortGroup:IsAir() then
if not self.EscortMenuEvasion then if not self.EscortMenuEvasion then
@@ -672,9 +682,9 @@ end
--- Defines a menu to let the escort resume its mission from a waypoint on its route. --- Defines a menu to let the escort resume its mission from a waypoint on its route.
-- All rules of engagement will appear under the menu **Resume mission from**. -- All rules of engagement will appear under the menu **Resume mission from**.
-- @param #ESCORT self -- @param #ESCORT self
-- @return #ESCORT self -- @return #ESCORT
function ESCORT:MenuResumeMission() function ESCORT:MenuResumeMission()
--self:F() self:F()
if not self.EscortMenuResumeMission then if not self.EscortMenuResumeMission then
-- Mission Resume Menu Root -- Mission Resume Menu Root
@@ -684,8 +694,7 @@ function ESCORT:MenuResumeMission()
return self return self
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_HoldPosition( OrbitGroup, OrbitHeight, OrbitSeconds ) function ESCORT:_HoldPosition( OrbitGroup, OrbitHeight, OrbitSeconds )
@@ -726,8 +735,6 @@ function ESCORT:_HoldPosition( OrbitGroup, OrbitHeight, OrbitSeconds )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_JoinUpAndFollow( Distance ) function ESCORT:_JoinUpAndFollow( Distance )
@@ -745,7 +752,7 @@ end
-- @param Wrapper.Client#CLIENT EscortClient -- @param Wrapper.Client#CLIENT EscortClient
-- @param DCS#Distance Distance -- @param DCS#Distance Distance
function ESCORT:JoinUpAndFollow( EscortGroup, EscortClient, Distance ) function ESCORT:JoinUpAndFollow( EscortGroup, EscortClient, Distance )
--self:F( { EscortGroup, EscortClient, Distance } ) self:F( { EscortGroup, EscortClient, Distance } )
self.FollowScheduler:Stop( self.FollowSchedule ) self.FollowScheduler:Stop( self.FollowSchedule )
@@ -761,8 +768,6 @@ function ESCORT:JoinUpAndFollow( EscortGroup, EscortClient, Distance )
EscortGroup:MessageToClient( "Rejoining and Following at " .. Distance .. "!", 30, EscortClient ) EscortGroup:MessageToClient( "Rejoining and Following at " .. Distance .. "!", 30, EscortClient )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_Flare( Color, Message ) function ESCORT:_Flare( Color, Message )
@@ -773,8 +778,6 @@ function ESCORT:_Flare( Color, Message )
EscortGroup:MessageToClient( Message, 10, EscortClient ) EscortGroup:MessageToClient( Message, 10, EscortClient )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_Smoke( Color, Message ) function ESCORT:_Smoke( Color, Message )
@@ -785,8 +788,7 @@ function ESCORT:_Smoke( Color, Message )
EscortGroup:MessageToClient( Message, 10, EscortClient ) EscortGroup:MessageToClient( Message, 10, EscortClient )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_ReportNearbyTargetsNow() function ESCORT:_ReportNearbyTargetsNow()
@@ -797,8 +799,6 @@ function ESCORT:_ReportNearbyTargetsNow()
end end
---
-- @param #ESCORT self
function ESCORT:_SwitchReportNearbyTargets( ReportTargets ) function ESCORT:_SwitchReportNearbyTargets( ReportTargets )
local EscortGroup = self.EscortGroup local EscortGroup = self.EscortGroup
@@ -816,8 +816,6 @@ function ESCORT:_SwitchReportNearbyTargets( ReportTargets )
end end
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_ScanTargets( ScanDuration ) function ESCORT:_ScanTargets( ScanDuration )
@@ -848,27 +846,24 @@ function ESCORT:_ScanTargets( ScanDuration )
end end
---
-- @param #ESCORT self
-- @param Wrapper.Group#GROUP EscortGroup -- @param Wrapper.Group#GROUP EscortGroup
function _Resume( EscortGroup ) function _Resume( EscortGroup )
--env.info( '_Resume' ) env.info( '_Resume' )
local Escort = EscortGroup:GetState( EscortGroup, "Escort" ) local Escort = EscortGroup:GetState( EscortGroup, "Escort" )
--env.info( "EscortMode = " .. Escort.EscortMode ) env.info( "EscortMode = " .. Escort.EscortMode )
if Escort.EscortMode == ESCORT.MODE.FOLLOW then if Escort.EscortMode == ESCORT.MODE.FOLLOW then
Escort:JoinUpAndFollow( EscortGroup, Escort.EscortClient, Escort.Distance ) Escort:JoinUpAndFollow( EscortGroup, Escort.EscortClient, Escort.Distance )
end end
end end
---
-- @param #ESCORT self -- @param #ESCORT self
-- @param Functional.Detection#DETECTION_BASE.DetectedItem DetectedItem -- @param Functional.Detection#DETECTION_BASE.DetectedItem DetectedItem
function ESCORT:_AttackTarget( DetectedItem ) function ESCORT:_AttackTarget( DetectedItem )
local EscortGroup = self.EscortGroup -- Wrapper.Group#GROUP local EscortGroup = self.EscortGroup -- Wrapper.Group#GROUP
--self:F( EscortGroup ) self:F( EscortGroup )
local EscortClient = self.EscortClient local EscortClient = self.EscortClient
@@ -988,8 +983,6 @@ function ESCORT:_AssistTarget( EscortGroupAttack, DetectedItem )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_ROE( EscortROEFunction, EscortROEMessage ) function ESCORT:_ROE( EscortROEFunction, EscortROEMessage )
@@ -1000,8 +993,6 @@ function ESCORT:_ROE( EscortROEFunction, EscortROEMessage )
EscortGroup:MessageToClient( EscortROEMessage, 10, EscortClient ) EscortGroup:MessageToClient( EscortROEMessage, 10, EscortClient )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_ROT( EscortROTFunction, EscortROTMessage ) function ESCORT:_ROT( EscortROTFunction, EscortROTMessage )
@@ -1012,8 +1003,6 @@ function ESCORT:_ROT( EscortROTFunction, EscortROTMessage )
EscortGroup:MessageToClient( EscortROTMessage, 10, EscortClient ) EscortGroup:MessageToClient( EscortROTMessage, 10, EscortClient )
end end
---
-- @param #ESCORT self
-- @param #MENUPARAM MenuParam -- @param #MENUPARAM MenuParam
function ESCORT:_ResumeMission( WayPoint ) function ESCORT:_ResumeMission( WayPoint )
@@ -1038,7 +1027,7 @@ end
-- @param #ESCORT self -- @param #ESCORT self
-- @return #table -- @return #table
function ESCORT:RegisterRoute() function ESCORT:RegisterRoute()
--self:F() self:F()
local EscortGroup = self.EscortGroup -- Wrapper.Group#GROUP local EscortGroup = self.EscortGroup -- Wrapper.Group#GROUP
@@ -1049,11 +1038,9 @@ function ESCORT:RegisterRoute()
return TaskPoints return TaskPoints
end end
---
-- @param #ESCORT self
-- @param Functional.Escort#ESCORT self -- @param Functional.Escort#ESCORT self
function ESCORT:_FollowScheduler() function ESCORT:_FollowScheduler()
--self:F( { self.FollowDistance } ) self:F( { self.FollowDistance } )
self:T( {self.EscortClient.UnitName, self.EscortGroup.GroupName } ) self:T( {self.EscortClient.UnitName, self.EscortGroup.GroupName } )
if self.EscortGroup:IsAlive() and self.EscortClient:IsAlive() then if self.EscortGroup:IsAlive() and self.EscortClient:IsAlive() then
@@ -1159,10 +1146,11 @@ function ESCORT:_FollowScheduler()
return false return false
end end
--- Report Targets Scheduler. --- Report Targets Scheduler.
-- @param #ESCORT self -- @param #ESCORT self
function ESCORT:_ReportTargetsScheduler() function ESCORT:_ReportTargetsScheduler()
--self:F( self.EscortGroup:GetName() ) self:F( self.EscortGroup:GetName() )
if self.EscortGroup:IsAlive() and self.EscortClient:IsAlive() then if self.EscortGroup:IsAlive() and self.EscortClient:IsAlive() then
@@ -1175,7 +1163,7 @@ function ESCORT:_ReportTargetsScheduler()
end end
local DetectedItems = self.Detection:GetDetectedItems() local DetectedItems = self.Detection:GetDetectedItems()
--self:F( DetectedItems ) self:F( DetectedItems )
local DetectedTargets = false local DetectedTargets = false
@@ -1187,7 +1175,7 @@ function ESCORT:_ReportTargetsScheduler()
--local EscortUnit = EscortGroupData:GetUnit( 1 ) --local EscortUnit = EscortGroupData:GetUnit( 1 )
for DetectedItemIndex, DetectedItem in pairs( DetectedItems ) do for DetectedItemIndex, DetectedItem in pairs( DetectedItems ) do
--self:F( { DetectedItemIndex, DetectedItem } ) self:F( { DetectedItemIndex, DetectedItem } )
-- Remove the sub menus of the Attack menu of the Escort for the EscortGroup. -- Remove the sub menus of the Attack menu of the Escort for the EscortGroup.
local DetectedItemReportSummary = self.Detection:DetectedItemReportSummary( DetectedItem, EscortGroupData.EscortGroup, _DATABASE:GetPlayerSettings( self.EscortClient:GetPlayerName() ) ) local DetectedItemReportSummary = self.Detection:DetectedItemReportSummary( DetectedItem, EscortGroupData.EscortGroup, _DATABASE:GetPlayerSettings( self.EscortClient:GetPlayerName() ) )
@@ -1228,7 +1216,7 @@ function ESCORT:_ReportTargetsScheduler()
end end
end end
--self:F( DetectedMsgs ) self:F( DetectedMsgs )
if DetectedTargets then if DetectedTargets then
self.EscortGroup:MessageToClient( "Reporting detected targets:\n" .. table.concat( DetectedMsgs, "\n" ), 20, self.EscortClient ) self.EscortGroup:MessageToClient( "Reporting detected targets:\n" .. table.concat( DetectedMsgs, "\n" ), 20, self.EscortClient )
else else
@@ -515,7 +515,7 @@ end
--- Set time interval between updates of the formation. --- Set time interval between updates of the formation.
-- @param #FORMATION self -- @param #FORMATION self
-- @param #number dt Time step in seconds between formation updates. Default is every 0.5 seconds. -- @param #number dt (Optional) Time step in seconds between formation updates. Default is every 0.5 seconds.
-- @return #FORMATION -- @return #FORMATION
function FORMATION:SetFollowTimeInterval(dt) function FORMATION:SetFollowTimeInterval(dt)
self.dtFollow=dt or 0.5 self.dtFollow=dt or 0.5
+5 -5
View File
@@ -459,7 +459,7 @@ end
--- Set explosion power. This is an "artificial" explosion generated when the missile is destroyed. Just for the visual effect. --- Set explosion power. This is an "artificial" explosion generated when the missile is destroyed. Just for the visual effect.
-- Don't set the explosion power too big or it will harm the aircraft in the vicinity. -- Don't set the explosion power too big or it will harm the aircraft in the vicinity.
-- @param #FOX self -- @param #FOX self
-- @param #number power Explosion power in kg TNT. Default 0.1 kg. -- @param #number power (Optional) Explosion power in kg TNT. Default 0.1 kg.
-- @return #FOX self -- @return #FOX self
function FOX:SetExplosionPower(power) function FOX:SetExplosionPower(power)
@@ -470,7 +470,7 @@ end
--- Set missile-player distance when missile is destroyed. --- Set missile-player distance when missile is destroyed.
-- @param #FOX self -- @param #FOX self
-- @param #number distance Distance in meters. Default 200 m. -- @param #number distance (Optional) Distance in meters. Default 200 m.
-- @return #FOX self -- @return #FOX self
function FOX:SetExplosionDistance(distance) function FOX:SetExplosionDistance(distance)
@@ -481,8 +481,8 @@ end
--- Set missile-player distance when BIG missiles are destroyed. --- Set missile-player distance when BIG missiles are destroyed.
-- @param #FOX self -- @param #FOX self
-- @param #number distance Distance in meters. Default 500 m. -- @param #number distance (Optional) Distance in meters. Default 500 m.
-- @param #number explosivemass Explosive mass of missile threshold in kg TNT. Default 50 kg. -- @param #number explosivemass (Optional) Explosive mass of missile threshold in kg TNT. Default 50 kg.
-- @return #FOX self -- @return #FOX self
function FOX:SetExplosionDistanceBigMissiles(distance, explosivemass) function FOX:SetExplosionDistanceBigMissiles(distance, explosivemass)
@@ -516,7 +516,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #FOX self -- @param #FOX self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #FOX self -- @return #FOX self
function FOX:SetVerbosity(VerbosityLevel) function FOX:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
+10 -10
View File
@@ -872,8 +872,8 @@ do
--- Set to accept accoustic detection. Set this *before* MANTIS starts! --- Set to accept accoustic detection. Set this *before* MANTIS starts!
-- @param #MANTIS self -- @param #MANTIS self
-- @param #number Radius Radius in which we can "hear" units. Defaults to 2000 meters. -- @param #number Radius (Optional) Radius in which we can "hear" units. Defaults to 2000 meters.
-- @param #table UnitCategories Set what Unit Categories we can "hear". Defaults to `{Unit.Category.HELICOPTER}` -- @param #table UnitCategories (Optional) Set what Unit Categories we can "hear". Defaults to `{Unit.Category.HELICOPTER}`
-- @return #MANTIS self -- @return #MANTIS self
function MANTIS:SetAccousticDetectionOn(Radius,UnitCategories) function MANTIS:SetAccousticDetectionOn(Radius,UnitCategories)
self.DetectAccoustic = true self.DetectAccoustic = true
@@ -1032,9 +1032,9 @@ do
--- Add a SET_ZONE of zones for Shoot&Scoot - SHORAD units will move around --- Add a SET_ZONE of zones for Shoot&Scoot - SHORAD units will move around
-- @param #MANTIS self -- @param #MANTIS self
-- @param Core.Set#SET_ZONE ZoneSet Set of zones to be used. Units will move around to the next (random) zone between 100m and 3000m away. -- @param Core.Set#SET_ZONE ZoneSet Set of zones to be used. Units will move around to the next (random) zone between 100m and 3000m away.
-- @param #number Number Number of closest zones to be considered, defaults to 3. -- @param #number Number (Optional) Number of closest zones to be considered, defaults to 3.
-- @param #boolean Random If true, use a random coordinate inside the next zone to scoot to. -- @param #boolean Random If true, use a random coordinate inside the next zone to scoot to.
-- @param #string Formation Formation to use, defaults to "Cone". See mission editor dropdown for options. -- @param #string Formation (Optional) Formation to use, defaults to "Cone". See mission editor dropdown for options.
-- @return #MANTIS self -- @return #MANTIS self
function MANTIS:AddScootZones(ZoneSet, Number, Random, Formation) function MANTIS:AddScootZones(ZoneSet, Number, Random, Formation)
self:T(self.lid .. " AddScootZones") self:T(self.lid .. " AddScootZones")
@@ -1215,11 +1215,11 @@ do
--- Function to set number of SAMs going active on a valid, detected thread --- Function to set number of SAMs going active on a valid, detected thread
-- @param #MANTIS self -- @param #MANTIS self
-- @param #number Short Number of short-range systems activated, defaults to 1. -- @param #number Short (Optional) Number of short-range systems activated, defaults to 2.
-- @param #number Mid Number of mid-range systems activated, defaults to 2. -- @param #number Mid (Optional) Number of mid-range systems activated, defaults to 2.
-- @param #number Long Number of long-range systems activated, defaults to 2. -- @param #number Long (Optional) Number of long-range systems activated, defaults to 1.
-- @param #number Classic (non-automode) Number of overall systems activated, defaults to 6. -- @param #number Classic (Optional) (non-automode) Number of overall systems activated, defaults to 6.
-- @param #number Point Number of point defense and AAA systems activated, defaults to 6. -- @param #number Point (Optional) Number of point defense and AAA systems activated, defaults to 6.
-- @return #MANTIS self -- @return #MANTIS self
function MANTIS:SetMaxActiveSAMs(Short,Mid,Long,Classic,Point) function MANTIS:SetMaxActiveSAMs(Short,Mid,Long,Classic,Point)
self:T(self.lid .. "SetMaxActiveSAMs") self:T(self.lid .. "SetMaxActiveSAMs")
@@ -1341,7 +1341,7 @@ do
--- Function to set Advanded Mode --- Function to set Advanded Mode
-- @param #MANTIS self -- @param #MANTIS self
-- @param #boolean onoff If true, will activate Advanced Mode -- @param #boolean onoff If true, will activate Advanced Mode
-- @param #number ratio [optional] Percentage to use for advanced mode, defaults to 100% -- @param #number ratio (Optional) Percentage to use for advanced mode, defaults to 100%
-- @usage Advanced mode will *decrease* reactivity of MANTIS, if HQ and/or EWR network dies. Set SAMs to RED state if both are dead. Requires usage of an **HQ** object and the **dynamic** option. -- @usage Advanced mode will *decrease* reactivity of MANTIS, if HQ and/or EWR network dies. Set SAMs to RED state if both are dead. Requires usage of an **HQ** object and the **dynamic** option.
-- E.g. `mymantis:SetAdvancedMode(true, 90)` -- E.g. `mymantis:SetAdvancedMode(true, 90)`
function MANTIS:SetAdvancedMode(onoff, ratio) function MANTIS:SetAdvancedMode(onoff, ratio)
@@ -172,7 +172,7 @@ end
--- Set duration how long messages are displayed. --- Set duration how long messages are displayed.
-- @param #PSEUDOATC self -- @param #PSEUDOATC self
-- @param #number duration Time in seconds. Default is 30 sec. -- @param #number duration (Optional) Time in seconds. Default is 30 sec.
function PSEUDOATC:SetMessageDuration(duration) function PSEUDOATC:SetMessageDuration(duration)
self.mdur=duration or 30 self.mdur=duration or 30
end end
@@ -186,21 +186,21 @@ end
--- Set time interval after which the F10 radio menu is refreshed. --- Set time interval after which the F10 radio menu is refreshed.
-- @param #PSEUDOATC self -- @param #PSEUDOATC self
-- @param #number interval Interval in seconds. Default is every 120 sec. -- @param #number interval (Optional) Interval in seconds. Default is every 120 sec.
function PSEUDOATC:SetMenuRefresh(interval) function PSEUDOATC:SetMenuRefresh(interval)
self.mrefresh=interval or 120 self.mrefresh=interval or 120
end end
--- [Deprecated] Enable/disable event handling by MOOSE or DCS. --- [Deprecated] Enable/disable event handling by MOOSE or DCS.
-- @param #PSEUDOATC self -- @param #PSEUDOATC self
-- @param #boolean switch If true, events are handled by MOOSE (default). If false, events are handled directly by DCS. -- @param #boolean switch (Optional) If true, events are handled by MOOSE (default). If false, events are handled directly by DCS.
function PSEUDOATC:SetEventsMoose(switch) function PSEUDOATC:SetEventsMoose(switch)
self.eventsmoose=switch self.eventsmoose=switch
end end
--- Set time interval for reporting altitude until touchdown. --- Set time interval for reporting altitude until touchdown.
-- @param #PSEUDOATC self -- @param #PSEUDOATC self
-- @param #number interval Interval in seconds. Default is every 3 sec. -- @param #number interval (Optional) Interval in seconds. Default is every 3 sec.
function PSEUDOATC:SetReportAltInterval(interval) function PSEUDOATC:SetReportAltInterval(interval)
self.talt=interval or 3 self.talt=interval or 3
end end
+23 -23
View File
@@ -1055,7 +1055,7 @@ end
--- Set the friendly coalitions from which the airports can be used as departure and destination. --- Set the friendly coalitions from which the airports can be used as departure and destination.
-- @param #RAT self -- @param #RAT self
-- @param #string friendly "same"=own coalition+neutral (default), "sameonly"=own coalition only, "neutral"=all neutral airports. -- @param #string friendly (Optional) "same"=own coalition+neutral (default), "sameonly"=own coalition only, "neutral"=all neutral airports.
-- Default is "same", so aircraft will use airports of the coalition their spawn template has plus all neutral airports. -- Default is "same", so aircraft will use airports of the coalition their spawn template has plus all neutral airports.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
-- @usage yak:SetCoalition("neutral") will spawn aircraft randomly on all neutral airports. -- @usage yak:SetCoalition("neutral") will spawn aircraft randomly on all neutral airports.
@@ -1137,7 +1137,7 @@ end
--- Set the scan radius around parking spots. Parking spot is considered to be occupied if any obstacle is found with the radius. --- Set the scan radius around parking spots. Parking spot is considered to be occupied if any obstacle is found with the radius.
-- @param #RAT self -- @param #RAT self
-- @param #number radius Radius in meters. Default 50 m. -- @param #number radius (Optional) Radius in meters. Default 50 m.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetParkingScanRadius(radius) function RAT:SetParkingScanRadius(radius)
self:F2(radius) self:F2(radius)
@@ -1503,7 +1503,7 @@ end
--- Set the delay before first group is spawned. --- Set the delay before first group is spawned.
-- @param #RAT self -- @param #RAT self
-- @param #number delay Delay in seconds. Default is 5 seconds. Minimum delay is 0.5 seconds. -- @param #number delay (Optional) Delay in seconds. Default is 5 seconds. Minimum delay is 0.5 seconds.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetSpawnDelay(delay) function RAT:SetSpawnDelay(delay)
self:F2(delay) self:F2(delay)
@@ -1514,7 +1514,7 @@ end
--- Set the interval between spawnings of the template group. --- Set the interval between spawnings of the template group.
-- @param #RAT self -- @param #RAT self
-- @param #number interval Interval in seconds. Default is 5 seconds. Minimum is 0.5 seconds. -- @param #number interval (Optional) Interval in seconds. Default is 5 seconds. Minimum is 0.5 seconds.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetSpawnInterval(interval) function RAT:SetSpawnInterval(interval)
self:F2(interval) self:F2(interval)
@@ -1525,7 +1525,7 @@ end
--- Set max number of groups that will be spawned. When this limit is reached, no more RAT groups are spawned. --- Set max number of groups that will be spawned. When this limit is reached, no more RAT groups are spawned.
-- @param #RAT self -- @param #RAT self
-- @param #number Nmax Max number of groups. Default `nil`=unlimited. -- @param #number Nmax (Optional) Max number of groups. Default `nil`=unlimited.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetSpawnLimit(Nmax) function RAT:SetSpawnLimit(Nmax)
self.NspawnMax=Nmax self.NspawnMax=Nmax
@@ -1545,7 +1545,7 @@ end
--- Sets the delay between despawning and respawning aircraft. --- Sets the delay between despawning and respawning aircraft.
-- @param #RAT self -- @param #RAT self
-- @param #number delay Delay in seconds until respawn happens. Default is 1 second. Minimum is 1 second. -- @param #number delay (Optional) Delay in seconds until respawn happens. Default is 1 second. Minimum is 1 second.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetRespawnDelay(delay) function RAT:SetRespawnDelay(delay)
self:F2(delay) self:F2(delay)
@@ -1566,7 +1566,7 @@ end
--- Number of tries to respawn an aircraft in case it has accidentally been spawned on runway. --- Number of tries to respawn an aircraft in case it has accidentally been spawned on runway.
-- @param #RAT self -- @param #RAT self
-- @param #number n Number of retries. Default is 3. -- @param #number n (Optional) Number of retries. Default is 3.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetMaxRespawnTriedWhenSpawnedOnRunway(n) function RAT:SetMaxRespawnTriedWhenSpawnedOnRunway(n)
self:F2(n) self:F2(n)
@@ -1624,7 +1624,7 @@ end
--- Check if aircraft have accidentally been spawned on the runway. If so they will be removed immediately. --- Check if aircraft have accidentally been spawned on the runway. If so they will be removed immediately.
-- @param #RAT self -- @param #RAT self
-- @param #boolean switch If true, check is performed. If false, this check is omitted. -- @param #boolean switch If true, check is performed. If false, this check is omitted.
-- @param #number radius Distance in meters until a unit is considered to have spawned accidentally on the runway. Default is 75 m. -- @param #number radius (Optional) Distance in meters until a unit is considered to have spawned accidentally on the runway. Default is 75 m.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:CheckOnRunway(switch, distance) function RAT:CheckOnRunway(switch, distance)
self:F2(switch) self:F2(switch)
@@ -1639,7 +1639,7 @@ end
--- Check if aircraft have accidentally been spawned on top of each other. If yes, they will be removed immediately. --- Check if aircraft have accidentally been spawned on top of each other. If yes, they will be removed immediately.
-- @param #RAT self -- @param #RAT self
-- @param #boolean switch If true, check is performed. If false, this check is omitted. -- @param #boolean switch If true, check is performed. If false, this check is omitted.
-- @param #number radius Radius in meters until which a unit is considered to be on top of each other. Default is 2 m. -- @param #number radius (Optional) Radius in meters until which a unit is considered to be on top of each other. Default is 2 m.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:CheckOnTop(switch, radius) function RAT:CheckOnTop(switch, radius)
self:F2(switch) self:F2(switch)
@@ -1755,10 +1755,10 @@ end
--- Define how aircraft that are spawned in uncontrolled state are activate. --- Define how aircraft that are spawned in uncontrolled state are activate.
-- @param #RAT self -- @param #RAT self
-- @param #number maxactivated Maximal numnber of activated aircraft. Absolute maximum will be the number of spawned groups. Default is 1. -- @param #number maxactivated (Optional) Maximal numnber of activated aircraft. Absolute maximum will be the number of spawned groups. Default is 1.
-- @param #number delay Time delay in seconds before (first) aircraft is activated. Default is 1 second. -- @param #number delay (Optional) Time delay in seconds before (first) aircraft is activated. Default is 1 second.
-- @param #number delta Time difference in seconds before next aircraft is activated. Default is 1 second. -- @param #number delta (Optional) Time difference in seconds before next aircraft is activated. Default is 1 second.
-- @param #number frand Factor [0,...,1] for randomization of time difference between aircraft activations. Default is 0, i.e. no randomization. -- @param #number frand (Optional) Factor [0,...,1] for randomization of time difference between aircraft activations. Default is 0, i.e. no randomization.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:ActivateUncontrolled(maxactivated, delay, delta, frand) function RAT:ActivateUncontrolled(maxactivated, delay, delta, frand)
self:F2({max=maxactivated, delay=delay, delta=delta, rand=frand}) self:F2({max=maxactivated, delay=delay, delta=delta, rand=frand})
@@ -1784,7 +1784,7 @@ end
--- Set the time after which inactive groups will be destroyed. --- Set the time after which inactive groups will be destroyed.
-- @param #RAT self -- @param #RAT self
-- @param #number time Time in seconds. Default is 600 seconds = 10 minutes. Minimum is 60 seconds. -- @param #number time (Optional) Time in seconds. Default is 600 seconds = 10 minutes. Minimum is 60 seconds.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:TimeDestroyInactive(time) function RAT:TimeDestroyInactive(time)
self:F2(time) self:F2(time)
@@ -1818,7 +1818,7 @@ end
--- Set the climb rate. This automatically sets the climb angle. --- Set the climb rate. This automatically sets the climb angle.
-- @param #RAT self -- @param #RAT self
-- @param #number rate Climb rate in ft/min. Default is 1500 ft/min. Minimum is 100 ft/min. Maximum is 15,000 ft/min. -- @param #number rate (Optional) Climb rate in ft/min. Default is 1500 ft/min. Minimum is 100 ft/min. Maximum is 15,000 ft/min.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:SetClimbRate(rate) function RAT:SetClimbRate(rate)
self:F2(rate) self:F2(rate)
@@ -1912,7 +1912,7 @@ end
--- Max number of planes that get landing clearance of the RAT ATC. This setting effects all RAT objects and groups! --- Max number of planes that get landing clearance of the RAT ATC. This setting effects all RAT objects and groups!
-- @param #RAT self -- @param #RAT self
-- @param #number n Number of aircraft that are allowed to land simultaniously. Default is 2. -- @param #number n (Optional) Number of aircraft that are allowed to land simultaniously. Default is 2.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:ATC_Clearance(n) function RAT:ATC_Clearance(n)
self:F2(n) self:F2(n)
@@ -1922,7 +1922,7 @@ end
--- Delay between granting landing clearance for simultanious landings. This setting effects all RAT objects and groups! --- Delay between granting landing clearance for simultanious landings. This setting effects all RAT objects and groups!
-- @param #RAT self -- @param #RAT self
-- @param #number time Delay time when the next aircraft will get landing clearance event if the previous one did not land yet. Default is 240 sec. -- @param #number time (Optional) Delay time when the next aircraft will get landing clearance event if the previous one did not land yet. Default is 240 sec.
-- @return #RAT RAT self object. -- @return #RAT RAT self object.
function RAT:ATC_Delay(time) function RAT:ATC_Delay(time)
self:F2(time) self:F2(time)
@@ -2767,7 +2767,7 @@ end
--- Despawn group. The `FLIGHTGROUP` is despawned and stopped. The ratcraft is removed from the self.ratcraft table. Menues are removed. --- Despawn group. The `FLIGHTGROUP` is despawned and stopped. The ratcraft is removed from the self.ratcraft table. Menues are removed.
-- @param #RAT self -- @param #RAT self
-- @param Wrapper.Group#GROUP group Group to be despawned. -- @param Wrapper.Group#GROUP group Group to be despawned.
-- @param #number delay Delay in seconds before the despawn happens. Default is immidiately. -- @param #number delay (Optional) Delay in seconds before the despawn happens. Default is immidiately.
function RAT:_Despawn(group, delay) function RAT:_Despawn(group, delay)
if delay and delay>0 then if delay and delay>0 then
@@ -4705,7 +4705,7 @@ end
--- Anticipated group name from alias and spawn index. --- Anticipated group name from alias and spawn index.
-- @param #RAT self -- @param #RAT self
-- @param #number index Spawnindex of group if given or self.SpawnIndex+1 by default. -- @param #number index (Optional) Spawnindex of group if given or self.SpawnIndex+1 by default.
-- @return #string Name the group will get after it is spawned. -- @return #string Name the group will get after it is spawned.
function RAT:_AnticipatedGroupName(index) function RAT:_AnticipatedGroupName(index)
local index=index or self.SpawnIndex+1 local index=index or self.SpawnIndex+1
@@ -6013,7 +6013,7 @@ end
--- Adds a RAT object to the RAT manager. Parameter min specifies the limit how many RAT groups are at least alive. --- Adds a RAT object to the RAT manager. Parameter min specifies the limit how many RAT groups are at least alive.
-- @param #RATMANAGER self -- @param #RATMANAGER self
-- @param #RAT ratobject RAT object to be managed. -- @param #RAT ratobject RAT object to be managed.
-- @param #number min Minimum number of groups for this RAT object. Default is 1. -- @param #number min (Optional) Minimum number of groups for this RAT object. Default is 1.
-- @return #RATMANAGER RATMANAGER self object. -- @return #RATMANAGER RATMANAGER self object.
function RATMANAGER:Add(ratobject,min) function RATMANAGER:Add(ratobject,min)
@@ -6041,7 +6041,7 @@ end
--- Starts the RAT manager and spawns the initial random number RAT groups for each RAT object. --- Starts the RAT manager and spawns the initial random number RAT groups for each RAT object.
-- @param #RATMANAGER self -- @param #RATMANAGER self
-- @param #number delay Time delay in seconds after which the RAT manager is started. Default is 5 seconds. -- @param #number delay (Optional) Time delay in seconds after which the RAT manager is started. Default is 5 seconds.
-- @return #RATMANAGER RATMANAGER self object. -- @return #RATMANAGER RATMANAGER self object.
function RATMANAGER:Start(delay) function RATMANAGER:Start(delay)
@@ -6114,7 +6114,7 @@ end
--- Stops the RAT manager. --- Stops the RAT manager.
-- @param #RATMANAGER self -- @param #RATMANAGER self
-- @param #number delay Delay in seconds before the manager is stopped. Default is 1 second. -- @param #number delay (Optional) Delay in seconds before the manager is stopped. Default is 1 second.
-- @return #RATMANAGER RATMANAGER self object. -- @return #RATMANAGER RATMANAGER self object.
function RATMANAGER:Stop(delay) function RATMANAGER:Stop(delay)
delay=delay or 1 delay=delay or 1
@@ -6150,7 +6150,7 @@ end
--- Sets the time interval between spawning of groups. --- Sets the time interval between spawning of groups.
-- @param #RATMANAGER self -- @param #RATMANAGER self
-- @param #number dt Time interval in seconds. Default is 1 second. -- @param #number dt (Optional) Time interval in seconds. Default is 1 second.
-- @return #RATMANAGER RATMANAGER self object. -- @return #RATMANAGER RATMANAGER self object.
function RATMANAGER:SetTspawn(dt) function RATMANAGER:SetTspawn(dt)
self.dTspawn=dt or 1.0 self.dTspawn=dt or 1.0
+36 -34
View File
@@ -949,7 +949,7 @@ end
--- Set maximal strafing altitude. Player entering a strafe pit above that altitude are not registered for a valid pass. --- Set maximal strafing altitude. Player entering a strafe pit above that altitude are not registered for a valid pass.
-- @param #RANGE self -- @param #RANGE self
-- @param #number maxalt Maximum altitude in meters AGL. Default is 914 m = 3000 ft. -- @param #number maxalt (Optional) Maximum altitude in meters AGL. Default is 914 m = 3000 ft.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetMaxStrafeAlt( maxalt ) function RANGE:SetMaxStrafeAlt( maxalt )
self.strafemaxalt = maxalt or RANGE.Defaults.strafemaxalt self.strafemaxalt = maxalt or RANGE.Defaults.strafemaxalt
@@ -958,7 +958,7 @@ end
--- Set time interval for tracking bombs. A smaller time step increases accuracy but needs more CPU time. --- Set time interval for tracking bombs. A smaller time step increases accuracy but needs more CPU time.
-- @param #RANGE self -- @param #RANGE self
-- @param #number dt Time interval in seconds. Default is 0.005 s. -- @param #number dt (Optional) Time interval in seconds. Default is 0.005 s.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetBombtrackTimestep( dt ) function RANGE:SetBombtrackTimestep( dt )
self.dtBombtrack = dt or RANGE.Defaults.dtBombtrack self.dtBombtrack = dt or RANGE.Defaults.dtBombtrack
@@ -967,7 +967,7 @@ end
--- Set time how long (most) messages are displayed. --- Set time how long (most) messages are displayed.
-- @param #RANGE self -- @param #RANGE self
-- @param #number time Time in seconds. Default is 30 s. -- @param #number time (Optional) Time in seconds. Default is 30 s.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetMessageTimeDuration( time ) function RANGE:SetMessageTimeDuration( time )
self.Tmsg = time or RANGE.Defaults.Tmsg self.Tmsg = time or RANGE.Defaults.Tmsg
@@ -1009,8 +1009,8 @@ end
--- Set FunkMan socket. Bombing and strafing results will be send to your Discord bot. --- Set FunkMan socket. Bombing and strafing results will be send to your Discord bot.
-- **Requires running FunkMan program**. -- **Requires running FunkMan program**.
-- @param #RANGE self -- @param #RANGE self
-- @param #number Port Port. Default `10042`. -- @param #number Port (Optional) Port. Default `10042`.
-- @param #string Host Host. Default "127.0.0.1". -- @param #string Host (Optional) Host. Default "127.0.0.1".
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetFunkManOn(Port, Host) function RANGE:SetFunkManOn(Port, Host)
@@ -1032,7 +1032,7 @@ end
--- Set max number of player results that are displayed. --- Set max number of player results that are displayed.
-- @param #RANGE self -- @param #RANGE self
-- @param #number nmax Number of results. Default is 10. -- @param #number nmax (Optional) Number of results. Default is 10.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetDisplayedMaxPlayerResults( nmax ) function RANGE:SetDisplayedMaxPlayerResults( nmax )
self.ndisplayresult = nmax or RANGE.Defaults.ndisplayresult self.ndisplayresult = nmax or RANGE.Defaults.ndisplayresult
@@ -1041,7 +1041,7 @@ end
--- Set range radius. Defines the area in which e.g. bomb impacts are smoked. --- Set range radius. Defines the area in which e.g. bomb impacts are smoked.
-- @param #RANGE self -- @param #RANGE self
-- @param #number radius Radius in km. Default 5 km. -- @param #number radius (Optional) Radius in km. Default 5 km.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetRangeRadius( radius ) function RANGE:SetRangeRadius( radius )
self.rangeradius = radius * 1000 or RANGE.Defaults.rangeradius self.rangeradius = radius * 1000 or RANGE.Defaults.rangeradius
@@ -1050,7 +1050,7 @@ end
--- Set player setting whether bomb impact points are smoked or not. --- Set player setting whether bomb impact points are smoked or not.
-- @param #RANGE self -- @param #RANGE self
-- @param #boolean switch If true nor nil default is to smoke impact points of bombs. -- @param #boolean switch (Optional) If true nor nil default is to smoke impact points of bombs.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetDefaultPlayerSmokeBomb( switch ) function RANGE:SetDefaultPlayerSmokeBomb( switch )
if switch == true or switch == nil then if switch == true or switch == nil then
@@ -1063,7 +1063,7 @@ end
--- Set bomb track threshold distance. Bombs/rockets/missiles are only tracked if player-range distance is less than this distance. Default 25 km. --- Set bomb track threshold distance. Bombs/rockets/missiles are only tracked if player-range distance is less than this distance. Default 25 km.
-- @param #RANGE self -- @param #RANGE self
-- @param #number distance Threshold distance in km. Default 25 km. -- @param #number distance (Optional) Threshold distance in km. Default 25 km.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetBombtrackThreshold( distance ) function RANGE:SetBombtrackThreshold( distance )
self.BombtrackThreshold = (distance or 25) * 1000 self.BombtrackThreshold = (distance or 25) * 1000
@@ -1110,7 +1110,7 @@ end
--- Enable range ceiling. Aircraft must be below the ceiling altitude to be considered in the range zone. --- Enable range ceiling. Aircraft must be below the ceiling altitude to be considered in the range zone.
-- @param #RANGE self -- @param #RANGE self
-- @param #boolean enabled True if you would like to enable the ceiling check. If no value give, will Default to false. -- @param #boolean enabled (Optional) True if you would like to enable the ceiling check. If no value give, will Default to false.
-- @return #RANGE self -- @return #RANGE self
function RANGE:EnableRangeCeiling( enabled ) function RANGE:EnableRangeCeiling( enabled )
self:T(self.lid.."EnableRangeCeiling") self:T(self.lid.."EnableRangeCeiling")
@@ -1126,7 +1126,7 @@ end
--- Set smoke color for marking bomb targets. By default bomb targets are marked by red smoke. --- Set smoke color for marking bomb targets. By default bomb targets are marked by red smoke.
-- @param #RANGE self -- @param #RANGE self
-- @param Utilities.Utils#SMOKECOLOR colorid Color id. Default `SMOKECOLOR.Red`. -- @param Utilities.Utils#SMOKECOLOR colorid (Optional) Color id. Default `SMOKECOLOR.Red`.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetBombTargetSmokeColor( colorid ) function RANGE:SetBombTargetSmokeColor( colorid )
self.BombSmokeColor = colorid or SMOKECOLOR.Red self.BombSmokeColor = colorid or SMOKECOLOR.Red
@@ -1135,7 +1135,7 @@ end
--- Set score bomb distance. --- Set score bomb distance.
-- @param #RANGE self -- @param #RANGE self
-- @param #number distance Distance in meters. Default 1000 m. -- @param #number distance (Optional) Distance in meters. Default 1000 m.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetScoreBombDistance( distance ) function RANGE:SetScoreBombDistance( distance )
self.scorebombdistance = distance or 1000 self.scorebombdistance = distance or 1000
@@ -1144,7 +1144,7 @@ end
--- Set smoke color for marking strafe targets. By default strafe targets are marked by green smoke. --- Set smoke color for marking strafe targets. By default strafe targets are marked by green smoke.
-- @param #RANGE self -- @param #RANGE self
-- @param Utilities.Utils#SMOKECOLOR colorid Color id. Default `SMOKECOLOR.Green`. -- @param Utilities.Utils#SMOKECOLOR colorid (Optional) Color id. Default `SMOKECOLOR.Green`.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetStrafeTargetSmokeColor( colorid ) function RANGE:SetStrafeTargetSmokeColor( colorid )
self.StrafeSmokeColor = colorid or SMOKECOLOR.Green self.StrafeSmokeColor = colorid or SMOKECOLOR.Green
@@ -1153,7 +1153,7 @@ end
--- Set smoke color for marking strafe pit approach boxes. By default strafe pit boxes are marked by white smoke. --- Set smoke color for marking strafe pit approach boxes. By default strafe pit boxes are marked by white smoke.
-- @param #RANGE self -- @param #RANGE self
-- @param Utilities.Utils#SMOKECOLOR colorid Color id. Default `SMOKECOLOR.White`. -- @param Utilities.Utils#SMOKECOLOR colorid (Optional) Color id. Default `SMOKECOLOR.White`.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetStrafePitSmokeColor( colorid ) function RANGE:SetStrafePitSmokeColor( colorid )
self.StrafePitSmokeColor = colorid or SMOKECOLOR.White self.StrafePitSmokeColor = colorid or SMOKECOLOR.White
@@ -1162,7 +1162,7 @@ end
--- Set time delay between bomb impact and starting to smoke the impact point. --- Set time delay between bomb impact and starting to smoke the impact point.
-- @param #RANGE self -- @param #RANGE self
-- @param #number delay Time delay in seconds. Default is 3 seconds. -- @param #number delay (Optional) Time delay in seconds. Default is 3 seconds.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetSmokeTimeDelay( delay ) function RANGE:SetSmokeTimeDelay( delay )
self.TdelaySmoke = delay or RANGE.Defaults.TdelaySmoke self.TdelaySmoke = delay or RANGE.Defaults.TdelaySmoke
@@ -1252,11 +1252,11 @@ end
--- Use SRS Simple-Text-To-Speech for transmissions. No sound files necessary. --- Use SRS Simple-Text-To-Speech for transmissions. No sound files necessary.
-- @param #RANGE self -- @param #RANGE self
-- @param #string PathToSRS Path to SRS directory. -- @param #string PathToSRS Path to SRS directory.
-- @param #number Port SRS port. Default 5002. -- @param #number Port (Optional) SRS port. Default 5002.
-- @param #number Coalition Coalition side, e.g. `coalition.side.BLUE` or `coalition.side.RED`. Default `coalition.side.BLUE`. -- @param #number Coalition (Optional) Coalition side, e.g. `coalition.side.BLUE` or `coalition.side.RED`. Default `coalition.side.BLUE`.
-- @param #number Frequency Frequency to use. Default is 256 MHz for range control and 305 MHz for instructor. If given, both control and instructor get this frequency. -- @param #number Frequency (Optional) Frequency to use. Default is 256 MHz for range control and 305 MHz for instructor. If given, both control and instructor get this frequency.
-- @param #number Modulation Modulation to use, defaults to radio.modulation.AM -- @param #number Modulation (Optional) Modulation to use, defaults to radio.modulation.AM
-- @param #number Volume Volume, between 0.0 and 1.0. Defaults to 1.0 -- @param #number Volume (Optional) Volume, between 0.0 and 1.0. Defaults to 1.0
-- @param #string PathToGoogleKey Path to Google TTS credentials. -- @param #string PathToGoogleKey Path to Google TTS credentials.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetSRS(PathToSRS, Port, Coalition, Frequency, Modulation, Volume, PathToGoogleKey) function RANGE:SetSRS(PathToSRS, Port, Coalition, Frequency, Modulation, Volume, PathToGoogleKey)
@@ -1300,11 +1300,11 @@ end
--- (SRS) Set range control frequency and voice. Use `RANGE:SetSRS()` once first before using this function. --- (SRS) Set range control frequency and voice. Use `RANGE:SetSRS()` once first before using this function.
-- @param #RANGE self -- @param #RANGE self
-- @param #number frequency Frequency in MHz. Default 256 MHz. -- @param #number frequency (Optional) Frequency in MHz. Default 256 MHz.
-- @param #number modulation Modulation, defaults to radio.modulation.AM. -- @param #number modulation (Optional) Modulation, defaults to radio.modulation.AM.
-- @param #string voice Voice. -- @param #string voice Voice.
-- @param #string culture Culture, defaults to "en-US". -- @param #string culture (Optional) Culture, defaults to "en-US".
-- @param #string gender Gender, defaults to "female". -- @param #string gender (Optional) Gender, defaults to "female".
-- @param #string relayunitname Name of the unit used for transmission location. -- @param #string relayunitname Name of the unit used for transmission location.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetSRSRangeControl( frequency, modulation, voice, culture, gender, relayunitname ) function RANGE:SetSRSRangeControl( frequency, modulation, voice, culture, gender, relayunitname )
@@ -1334,11 +1334,11 @@ end
--- (SRS) Set range instructor frequency and voice. Use `RANGE:SetSRS()` once first before using this function. --- (SRS) Set range instructor frequency and voice. Use `RANGE:SetSRS()` once first before using this function.
-- @param #RANGE self -- @param #RANGE self
-- @param #number frequency Frequency in MHz. Default 305 MHz. -- @param #number frequency (Optional) Frequency in MHz. Default 305 MHz.
-- @param #number modulation Modulation, defaults to radio.modulation.AM. -- @param #number modulation (Optional) Modulation, defaults to radio.modulation.AM.
-- @param #string voice Voice. -- @param #string voice Voice.
-- @param #string culture Culture, defaults to "en-US". -- @param #string culture (Optional) Culture, defaults to "en-US".
-- @param #string gender Gender, defaults to "male". -- @param #string gender (Optional) Gender, defaults to "male".
-- @param #string relayunitname Name of the unit used for transmission location. -- @param #string relayunitname Name of the unit used for transmission location.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetSRSRangeInstructor( frequency, modulation, voice, culture, gender, relayunitname ) function RANGE:SetSRSRangeInstructor( frequency, modulation, voice, culture, gender, relayunitname )
@@ -1368,7 +1368,7 @@ end
--- Enable range control and set frequency (non-SRS). --- Enable range control and set frequency (non-SRS).
-- @param #RANGE self -- @param #RANGE self
-- @param #number frequency Frequency in MHz. Default 256 MHz. -- @param #number frequency (Optional) Frequency in MHz. Default 256 MHz.
-- @param #string relayunitname Name of the unit used for transmission. -- @param #string relayunitname Name of the unit used for transmission.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetRangeControl( frequency, relayunitname ) function RANGE:SetRangeControl( frequency, relayunitname )
@@ -1379,7 +1379,7 @@ end
--- Enable instructor radio and set frequency (non-SRS). --- Enable instructor radio and set frequency (non-SRS).
-- @param #RANGE self -- @param #RANGE self
-- @param #number frequency Frequency in MHz. Default 305 MHz. -- @param #number frequency (Optional) Frequency in MHz. Default 305 MHz.
-- @param #string relayunitname Name of the unit used for transmission. -- @param #string relayunitname Name of the unit used for transmission.
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetInstructorRadio( frequency, relayunitname ) function RANGE:SetInstructorRadio( frequency, relayunitname )
@@ -1390,7 +1390,7 @@ end
--- Set sound files folder within miz file. --- Set sound files folder within miz file.
-- @param #RANGE self -- @param #RANGE self
-- @param #string path Path for sound files. Default "Range Soundfiles/". Mind the slash "/" at the end! -- @param #string path (Optional) Path for sound files. Default "Range Soundfiles/". Mind the slash "/" at the end!
-- @return #RANGE self -- @return #RANGE self
function RANGE:SetSoundfilesPath( path ) function RANGE:SetSoundfilesPath( path )
self.soundpath = tostring( path or "Range Soundfiles/" ) self.soundpath = tostring( path or "Range Soundfiles/" )
@@ -1630,11 +1630,13 @@ end
-- @param #RANGE self -- @param #RANGE self
-- @param #table targetnames Single or multiple (Table) names of unit or static objects serving as bomb targets. -- @param #table targetnames Single or multiple (Table) names of unit or static objects serving as bomb targets.
-- @param #number goodhitrange (Optional) Max distance from target unit (in meters) which is considered as a good hit. Default is 25 m. -- @param #number goodhitrange (Optional) Max distance from target unit (in meters) which is considered as a good hit. Default is 25 m.
-- @param #boolean randommove If true, unit will move randomly within the range. Default is false. -- @param #boolean randommove (Optional) If true, unit will move randomly within the range. Default is false.
-- @return #RANGE self -- @return #RANGE self
function RANGE:AddBombingTargets( targetnames, goodhitrange, randommove ) function RANGE:AddBombingTargets( targetnames, goodhitrange, randommove )
self:F( { targetnames = targetnames, goodhitrange = goodhitrange, randommove = randommove } ) self:F( { targetnames = targetnames, goodhitrange = goodhitrange, randommove = randommove } )
randommove = randommove or false
-- Create a table if necessary. -- Create a table if necessary.
if type( targetnames ) ~= "table" then if type( targetnames ) ~= "table" then
targetnames = { targetnames } targetnames = { targetnames }
@@ -1669,7 +1671,7 @@ end
-- @param #RANGE self -- @param #RANGE self
-- @param Wrapper.Positionable#POSITIONABLE unit Positionable (unit or static) of the bombing target. -- @param Wrapper.Positionable#POSITIONABLE unit Positionable (unit or static) of the bombing target.
-- @param #number goodhitrange Max distance from unit which is considered as a good hit. -- @param #number goodhitrange Max distance from unit which is considered as a good hit.
-- @param #boolean randommove If true, unit will move randomly within the range. Default is false. -- @param #boolean randommove (Optional) If true, unit will move randomly within the range. Default is false.
-- @return #RANGE self -- @return #RANGE self
function RANGE:AddBombingTargetUnit( unit, goodhitrange, randommove ) function RANGE:AddBombingTargetUnit( unit, goodhitrange, randommove )
self:F( { unit = unit, goodhitrange = goodhitrange, randommove = randommove } ) self:F( { unit = unit, goodhitrange = goodhitrange, randommove = randommove } )
@@ -1785,7 +1787,7 @@ end
-- @param #RANGE self -- @param #RANGE self
-- @param Wrapper.Group#GROUP group Group of bombing targets. Can also be given as group name. -- @param Wrapper.Group#GROUP group Group of bombing targets. Can also be given as group name.
-- @param #number goodhitrange Max distance from unit which is considered as a good hit. -- @param #number goodhitrange Max distance from unit which is considered as a good hit.
-- @param #boolean randommove If true, unit will move randomly within the range. Default is false. -- @param #boolean randommove (Optional) If true, unit will move randomly within the range. Default is false.
-- @return #RANGE self -- @return #RANGE self
function RANGE:AddBombingTargetGroup( group, goodhitrange, randommove ) function RANGE:AddBombingTargetGroup( group, goodhitrange, randommove )
self:F( { group = group, goodhitrange = goodhitrange, randommove = randommove } ) self:F( { group = group, goodhitrange = goodhitrange, randommove = randommove } )
@@ -394,7 +394,7 @@ end
--- Set a prefix string that will be displayed at each scoring message sent. --- Set a prefix string that will be displayed at each scoring message sent.
-- @param #SCORING self -- @param #SCORING self
-- @param #string DisplayMessagePrefix (Default="Scoring: ") The scoring prefix string. -- @param #string DisplayMessagePrefix (Optional) (Default="Scoring: ") The scoring prefix string.
-- @return #SCORING -- @return #SCORING
function SCORING:SetDisplayMessagePrefix( DisplayMessagePrefix ) function SCORING:SetDisplayMessagePrefix( DisplayMessagePrefix )
self.DisplayMessagePrefix = DisplayMessagePrefix or "" self.DisplayMessagePrefix = DisplayMessagePrefix or ""
+2 -2
View File
@@ -182,7 +182,7 @@ end
--- Sets the engagement range of the SAMs. Defaults to 75% to make it more deadly. Feature Request #1355 --- Sets the engagement range of the SAMs. Defaults to 75% to make it more deadly. Feature Request #1355
-- @param #SEAD self -- @param #SEAD self
-- @param #number range Set the engagement range in percent, e.g. 55 (default 75) -- @param #number range (Optional) Set the engagement range in percent, e.g. 55 (default 75)
-- @return #SEAD self -- @return #SEAD self
function SEAD:SetEngagementRange(range) function SEAD:SetEngagementRange(range)
self:T( { range } ) self:T( { range } )
@@ -197,7 +197,7 @@ end
--- Set the padding in seconds, which extends the radar off time calculated by SEAD --- Set the padding in seconds, which extends the radar off time calculated by SEAD
-- @param #SEAD self -- @param #SEAD self
-- @param #number Padding Extra number of seconds to add for the switch-on (default 10 seconds) -- @param #number Padding (Optional) Extra number of seconds to add for the switch-on (default 10 seconds)
-- @return #SEAD self -- @return #SEAD self
function SEAD:SetPadding(Padding) function SEAD:SetPadding(Padding)
self:T( { Padding } ) self:T( { Padding } )
@@ -158,15 +158,15 @@ do
--- Instantiates a new SHORAD object --- Instantiates a new SHORAD object
-- @param #SHORAD self -- @param #SHORAD self
-- @param #string Name Name of this SHORAD -- @param #string Name (Optional) Name of this SHORAD. Default "MyShorad"
-- @param #string ShoradPrefix Filter for the Shorad #SET_GROUP -- @param #string ShoradPrefix (Optional) Filter for the Shorad #SET_GROUP. Default "SAM SHORAD"
-- @param Core.Set#SET_GROUP Samset The #SET_GROUP of SAM sites to defend -- @param Core.Set#SET_GROUP Samset (Optional) The #SET_GROUP of SAM sites to defend. Default is based on default ShoradPrefix and default Coalition.
-- @param #number Radius Defense radius in meters, used to switch on SHORAD groups **within** this radius -- @param #number Radius (Optional) Defense radius in meters, used to switch on SHORAD groups **within** this radius. Default is 20000m.
-- @param #number ActiveTimer Determines how many seconds the systems stay on red alert after wake-up call -- @param #number ActiveTimer (Optional) Determines how many seconds the systems stay on red alert after wake-up call. Default 600s
-- @param #string Coalition Coalition, i.e. "blue", "red", or "neutral" -- @param #string Coalition Coalition, i.e. "blue", "red", or "neutral"
-- @param #boolean UseEmOnOff Use Emissions On/Off rather than Alarm State Red/Green (default: use Emissions switch) -- @param #boolean UseEmOnOff Use Emissions On/Off rather than Alarm State Red/Green (default: use Emissions switch)
-- @param #boolean SmokeDecoy Throw smoke decoy when getting activated. Defaults to false. -- @param #boolean SmokeDecoy (Optional) Throw smoke decoy when getting activated. Defaults to false.
-- @param #number SmokeDecoyColor SMOLECOLOR to use. Defaults to SMOLECOLOR.White -- @param #number SmokeDecoyColor (Optional) SMOLECOLOR to use. Defaults to SMOLECOLOR.White
-- @return #SHORAD self -- @return #SHORAD self
function SHORAD:New(Name, ShoradPrefix, Samset, Radius, ActiveTimer, Coalition, UseEmOnOff, SmokeDecoy, SmokeDecoyColor) function SHORAD:New(Name, ShoradPrefix, Samset, Radius, ActiveTimer, Coalition, UseEmOnOff, SmokeDecoy, SmokeDecoyColor)
local self = BASE:Inherit( self, FSM:New() ) local self = BASE:Inherit( self, FSM:New() )
@@ -240,9 +240,9 @@ do
--- Add a SET_ZONE of zones for Shoot&Scoot --- Add a SET_ZONE of zones for Shoot&Scoot
-- @param #SHORAD self -- @param #SHORAD self
-- @param Core.Set#SET_ZONE ZoneSet Set of zones to be used. Units will move around to the next (random) zone between 100m and 3000m away. -- @param Core.Set#SET_ZONE ZoneSet Set of zones to be used. Units will move around to the next (random) zone between 100m and 3000m away.
-- @param #number Number Number of closest zones to be considered, defaults to 3. -- @param #number Number (Optional) Number of closest zones to be considered, defaults to 3.
-- @param #boolean Random If true, use a random coordinate inside the next zone to scoot to. -- @param #boolean Random If true, use a random coordinate inside the next zone to scoot to.
-- @param #string Formation Formation to use, defaults to "Cone". See mission editor dropdown for options. -- @param #string Formation (Optional) Formation to use, defaults to "Cone". See mission editor dropdown for options.
-- @return #SHORAD self -- @return #SHORAD self
function SHORAD:AddScootZones(ZoneSet, Number, Random, Formation) function SHORAD:AddScootZones(ZoneSet, Number, Random, Formation)
self:T(self.lid .. " AddScootZones") self:T(self.lid .. " AddScootZones")
+10 -10
View File
@@ -251,7 +251,7 @@ STRATEGO.Type = {
-- @param #STRATEGO self -- @param #STRATEGO self
-- @param #string Name Name of the Adviser. -- @param #string Name Name of the Adviser.
-- @param #number Coalition Coalition, e.g. coalition.side.BLUE. -- @param #number Coalition Coalition, e.g. coalition.side.BLUE.
-- @param #number MaxDist Maximum distance of a single route in kilometers, defaults to 150. -- @param #number MaxDist (Optional) Maximum distance of a single route in kilometers, defaults to 150.
-- @return #STRATEGO self -- @return #STRATEGO self
function STRATEGO:New(Name,Coalition,MaxDist) function STRATEGO:New(Name,Coalition,MaxDist)
-- Inherit everything from FSM class. -- Inherit everything from FSM class.
@@ -362,7 +362,7 @@ end
--- [USER] Set up usage of budget and set an initial budget in points. --- [USER] Set up usage of budget and set an initial budget in points.
-- @param #STRATEGO self -- @param #STRATEGO self
-- @param #boolean Usebudget If true, use budget for advisory calculations. -- @param #boolean Usebudget If true, use budget for advisory calculations.
-- @param #number StartBudget Initial budget to be used, defaults to 500. -- @param #number StartBudget (Optional) Initial budget to be used, defaults to 500.
function STRATEGO:SetUsingBudget(Usebudget,StartBudget) function STRATEGO:SetUsingBudget(Usebudget,StartBudget)
self:T(self.lid.."SetUsingBudget") self:T(self.lid.."SetUsingBudget")
self.usebudget = Usebudget self.usebudget = Usebudget
@@ -394,10 +394,10 @@ end
--- [USER] Set weights for nodes and routes to determine their importance. --- [USER] Set weights for nodes and routes to determine their importance.
-- @param #STRATEGO self -- @param #STRATEGO self
-- @param #number MaxRunways Set the maximum number of runways the big (equals strategic) airbases on the map have. Defaults to 3. The weight of an airbase node hence equals the number of runways. -- @param #number MaxRunways (Optional) Set the maximum number of runways the big (equals strategic) airbases on the map have. Defaults to 3. The weight of an airbase node hence equals the number of runways.
-- @param #number PortWeight Set what weight a port node has. Defaults to 3. -- @param #number PortWeight (Optional) Set what weight a port node has. Defaults to 3.
-- @param #number POIWeight Set what weight a POI node has. Defaults to 1. -- @param #number POIWeight (Optional) Set what weight a POI node has. Defaults to 1.
-- @param #number RouteFactor Defines which weight each route between two defined nodes gets: Weight * RouteFactor. -- @param #number RouteFactor (Optional) Defines which weight each route between two defined nodes gets: Weight * RouteFactor. Defaults to 5.
-- @return #STRATEGO self -- @return #STRATEGO self
function STRATEGO:SetWeights(MaxRunways,PortWeight,POIWeight,RouteFactor) function STRATEGO:SetWeights(MaxRunways,PortWeight,POIWeight,RouteFactor)
self:T(self.lid.."SetWeights") self:T(self.lid.."SetWeights")
@@ -410,7 +410,7 @@ end
--- [USER] Set neutral benefit, i.e. how many points it is cheaper to decide for a neutral vs an enemy node when taking decisions. --- [USER] Set neutral benefit, i.e. how many points it is cheaper to decide for a neutral vs an enemy node when taking decisions.
-- @param #STRATEGO self -- @param #STRATEGO self
-- @param #number NeutralBenefit Pointsm defaults to 100. -- @param #number NeutralBenefit (Optional) Pointsm defaults to 100.
-- @return #STRATEGO self -- @return #STRATEGO self
function STRATEGO:SetNeutralBenefit(NeutralBenefit) function STRATEGO:SetNeutralBenefit(NeutralBenefit)
self:T(self.lid.."SetNeutralBenefit") self:T(self.lid.."SetNeutralBenefit")
@@ -420,9 +420,9 @@ end
--- [USER] Set how many units of which minimum threat level are needed to capture one node (i.e. the underlying OpsZone). --- [USER] Set how many units of which minimum threat level are needed to capture one node (i.e. the underlying OpsZone).
-- @param #STRATEGO self -- @param #STRATEGO self
-- @param #number CaptureUnits Number of units needed, defaults to three. -- @param #number CaptureUnits (Optional) Number of units needed, defaults to 3.
-- @param #number CaptureThreatlevel Threat level needed, can be 0..10, defaults to one. -- @param #number CaptureThreatlevel (Optional) Threat level needed, can be 0..10, defaults to 1.
-- @param #table CaptureCategories Table of object categories which can capture a node, defaults to `{Object.Category.UNIT}`. -- @param #table CaptureCategories (Optional) Table of object categories which can capture a node, defaults to `{Object.Category.UNIT}`.
-- @return #STRATEGO self -- @return #STRATEGO self
function STRATEGO:SetCaptureOptions(CaptureUnits,CaptureThreatlevel,CaptureCategories) function STRATEGO:SetCaptureOptions(CaptureUnits,CaptureThreatlevel,CaptureCategories)
self:T(self.lid.."SetCaptureOptions") self:T(self.lid.."SetCaptureOptions")
@@ -642,7 +642,7 @@ end
--- Set average, minimum and maximum time a unit is suppressed each time it gets hit. --- Set average, minimum and maximum time a unit is suppressed each time it gets hit.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #number Tave Average time [seconds] a group will be suppressed. Default is 15 seconds. -- @param #number Tave (Optional) Average time [seconds] a group will be suppressed. Default is 15 seconds.
-- @param #number Tmin (Optional) Minimum time [seconds] a group will be suppressed. Default is 5 seconds. -- @param #number Tmin (Optional) Minimum time [seconds] a group will be suppressed. Default is 5 seconds.
-- @param #number Tmax (Optional) Maximum time a group will be suppressed. Default is 25 seconds. -- @param #number Tmax (Optional) Maximum time a group will be suppressed. Default is 25 seconds.
function SUPPRESSION:SetSuppressionTime(Tave, Tmin, Tmax) function SUPPRESSION:SetSuppressionTime(Tave, Tmin, Tmax)
@@ -697,7 +697,7 @@ end
--- Set the formation a group uses for fall back, hide or retreat. --- Set the formation a group uses for fall back, hide or retreat.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #string formation Formation of the group. Default "Vee". -- @param #string formation (Optional) Formation of the group. Default "Vee".
function SUPPRESSION:SetFormation(formation) function SUPPRESSION:SetFormation(formation)
self:F(formation) self:F(formation)
self.Formation=formation or "Vee" self.Formation=formation or "Vee"
@@ -705,7 +705,7 @@ end
--- Set speed a group moves at for fall back, hide or retreat. --- Set speed a group moves at for fall back, hide or retreat.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #number speed Speed in km/h of group. Default max speed the group can do. -- @param #number speed (Optional) Speed in km/h of group. Default max speed the group can do.
function SUPPRESSION:SetSpeed(speed) function SUPPRESSION:SetSpeed(speed)
self:F(speed) self:F(speed)
self.Speed=speed or self.SpeedMax self.Speed=speed or self.SpeedMax
@@ -793,7 +793,7 @@ end
-- If the group consists of only a singe unit, this referrs to the life of the unit. -- If the group consists of only a singe unit, this referrs to the life of the unit.
-- If the group consists of more than one unit, this referrs to the group strength relative to its initial strength. -- If the group consists of more than one unit, this referrs to the group strength relative to its initial strength.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #number damage Damage in percent. If group gets damaged above this value, the group will retreat. Default 50 %. -- @param #number damage (Optional) Damage in percent. If group gets damaged above this value, the group will retreat. Default 50 %.
function SUPPRESSION:SetRetreatDamage(damage) function SUPPRESSION:SetRetreatDamage(damage)
self:F(damage) self:F(damage)
self.RetreatDamage=damage or 50 self.RetreatDamage=damage or 50
@@ -801,7 +801,7 @@ end
--- Set time a group waits in the retreat zone before it resumes its mission. Default is two hours. --- Set time a group waits in the retreat zone before it resumes its mission. Default is two hours.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #number time Time in seconds. Default 7200 seconds = 2 hours. -- @param #number time (Optional) Time in seconds. Default 7200 seconds = 2 hours.
function SUPPRESSION:SetRetreatWait(time) function SUPPRESSION:SetRetreatWait(time)
self:F(time) self:F(time)
self.RetreatWait=time or 7200 self.RetreatWait=time or 7200
@@ -809,7 +809,7 @@ end
--- Set alarm state a group will get after it returns from a fall back or take cover. --- Set alarm state a group will get after it returns from a fall back or take cover.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #string alarmstate Alarm state. Possible "Auto", "Green", "Red". Default is "Auto". -- @param #string alarmstate (Optional) Alarm state. Possible "Auto", "Green", "Red". Default is "Auto".
function SUPPRESSION:SetDefaultAlarmState(alarmstate) function SUPPRESSION:SetDefaultAlarmState(alarmstate)
self:F(alarmstate) self:F(alarmstate)
if alarmstate:lower()=="auto" then if alarmstate:lower()=="auto" then
@@ -825,7 +825,7 @@ end
--- Set Rules of Engagement (ROE) a group will get when it recovers from suppression. --- Set Rules of Engagement (ROE) a group will get when it recovers from suppression.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #string roe ROE after suppression. Possible "Free", "Hold" or "Return". Default "Free". -- @param #string roe (Optional) ROE after suppression. Possible "Free", "Hold" or "Return". Default "Free".
function SUPPRESSION:SetDefaultROE(roe) function SUPPRESSION:SetDefaultROE(roe)
self:F(roe) self:F(roe)
if roe:lower()=="free" then if roe:lower()=="free" then
@@ -841,7 +841,7 @@ end
--- Create an F10 menu entry for the suppressed group. The menu is mainly for Debugging purposes. --- Create an F10 menu entry for the suppressed group. The menu is mainly for Debugging purposes.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #boolean switch Enable=true or disable=false menu group. Default is true. -- @param #boolean switch (Optional) Enable=true or disable=false menu group. Default is true.
function SUPPRESSION:MenuOn(switch) function SUPPRESSION:MenuOn(switch)
self:F(switch) self:F(switch)
if switch==nil then if switch==nil then
@@ -1682,9 +1682,9 @@ end
--- Make group run/drive to a certain point. We put in several intermediate waypoints because sometimes the group stops before it arrived at the desired point. --- Make group run/drive to a certain point. We put in several intermediate waypoints because sometimes the group stops before it arrived at the desired point.
--@param #SUPPRESSION self --@param #SUPPRESSION self
--@param Core.Point#COORDINATE fin Coordinate where we want to go. --@param Core.Point#COORDINATE fin Coordinate where we want to go.
--@param #number speed Speed of group. Default is 20. --@param #number speed (Optional) Speed of group. Default is 20.
--@param #string formation Formation of group. Default is "Vee". --@param #string formation (Optional) Formation of group. Default is "Vee".
--@param #number wait Time the group will wait/hold at final waypoint. Default is 30 seconds. --@param #number wait (Optional) Time the group will wait/hold at final waypoint. Default is 30 seconds.
function SUPPRESSION:_Run(fin, speed, formation, wait) function SUPPRESSION:_Run(fin, speed, formation, wait)
speed=speed or 20 speed=speed or 20
@@ -1946,7 +1946,7 @@ end
--- Sets the ROE for the group and updates the current ROE variable. --- Sets the ROE for the group and updates the current ROE variable.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #string roe ROE the group will get. Possible "Free", "Hold", "Return". Default is self.DefaultROE. -- @param #string roe (Optional) ROE the group will get. Possible "Free", "Hold", "Return". Default is self.DefaultROE.
function SUPPRESSION:_SetROE(roe) function SUPPRESSION:_SetROE(roe)
local group=self.Controllable --Wrapper.Controllable#CONTROLLABLE local group=self.Controllable --Wrapper.Controllable#CONTROLLABLE
@@ -1975,7 +1975,7 @@ end
--- Sets the alarm state of the group and updates the current alarm state variable. --- Sets the alarm state of the group and updates the current alarm state variable.
-- @param #SUPPRESSION self -- @param #SUPPRESSION self
-- @param #string state Alarm state the group will get. Possible "Auto", "Green", "Red". Default is self.DefaultAlarmState. -- @param #string state (Optional) Alarm state the group will get. Possible "Auto", "Green", "Red". Default is self.DefaultAlarmState.
function SUPPRESSION:_SetAlarmState(state) function SUPPRESSION:_SetAlarmState(state)
local group=self.Controllable --Wrapper.Controllable#CONTROLLABLE local group=self.Controllable --Wrapper.Controllable#CONTROLLABLE
@@ -181,8 +181,8 @@ end
--- [USER] Set activation radius for Helos and Planes in Nautical Miles. --- [USER] Set activation radius for Helos and Planes in Nautical Miles.
-- @param #TIRESIAS self -- @param #TIRESIAS self
-- @param #number HeloMiles Radius around a Helicopter in which AI ground units will be activated. Defaults to 10NM. -- @param #number HeloMiles (Optional) Radius around a Helicopter in which AI ground units will be activated. Defaults to 10NM.
-- @param #number PlaneMiles Radius around an Airplane in which AI ground units will be activated. Defaults to 25NM. -- @param #number PlaneMiles (Optional) Radius around an Airplane in which AI ground units will be activated. Defaults to 25NM.
-- @return #TIRESIAS self -- @return #TIRESIAS self
function TIRESIAS:SetActivationRanges(HeloMiles, PlaneMiles) function TIRESIAS:SetActivationRanges(HeloMiles, PlaneMiles)
self.HeloSwitchRange = HeloMiles or 10 self.HeloSwitchRange = HeloMiles or 10
@@ -194,8 +194,8 @@ end
---[USER] Set AAA Ranges - AAA equals non-SAM systems which qualify as AAA in DCS world. ---[USER] Set AAA Ranges - AAA equals non-SAM systems which qualify as AAA in DCS world.
-- @param #TIRESIAS self -- @param #TIRESIAS self
-- @param #number FiringRange The engagement range that AAA units will be set to. Can be 0 to 100 (percent). Defaults to 60. -- @param #number FiringRange (Optional) The engagement range that AAA units will be set to. Can be 0 to 100 (percent). Defaults to 60.
-- @param #boolean SwitchAAA Decide if these system will have their AI switched off, too. Defaults to true. -- @param #boolean SwitchAAA (Optional) Decide if these system will have their AI switched off, too. Defaults to true.
-- @return #TIRESIAS self -- @return #TIRESIAS self
function TIRESIAS:SetAAARanges(FiringRange, SwitchAAA) function TIRESIAS:SetAAARanges(FiringRange, SwitchAAA)
self.AAARange = FiringRange or 60 self.AAARange = FiringRange or 60
@@ -2467,14 +2467,14 @@ function WAREHOUSE:New(warehouse, alias)
--- Triggers the FSM event "Save" when the warehouse assets are saved to file on disk. --- Triggers the FSM event "Save" when the warehouse assets are saved to file on disk.
-- @function [parent=#WAREHOUSE] Save -- @function [parent=#WAREHOUSE] Save
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #string path Path where the file is saved. Default is the DCS installation root directory. -- @param #string path (Optional) Path where the file is saved. Default is the DCS installation root directory.
-- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt. -- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt.
--- Triggers the FSM event "Save" with a delay when the warehouse assets are saved to a file. --- Triggers the FSM event "Save" with a delay when the warehouse assets are saved to a file.
-- @function [parent=#WAREHOUSE] __Save -- @function [parent=#WAREHOUSE] __Save
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #number delay Delay in seconds. -- @param #number delay Delay in seconds.
-- @param #string path Path where the file is saved. Default is the DCS installation root directory. -- @param #string path (Optional) Path where the file is saved. Default is the DCS installation root directory.
-- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt. -- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt.
--- On after "Save" event user function. Called when the warehouse assets are saved to disk. --- On after "Save" event user function. Called when the warehouse assets are saved to disk.
@@ -2483,21 +2483,21 @@ function WAREHOUSE:New(warehouse, alias)
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #string path Path where the file is saved. Default is the DCS installation root directory. -- @param #string path (Optional) Path where the file is saved. Default is the DCS installation root directory.
-- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt. -- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt.
--- Triggers the FSM event "Load" when the warehouse is loaded from a file on disk. --- Triggers the FSM event "Load" when the warehouse is loaded from a file on disk.
-- @function [parent=#WAREHOUSE] Load -- @function [parent=#WAREHOUSE] Load
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #string path Path where the file is located. Default is the DCS installation root directory. -- @param #string path (Optional) Path where the file is located. Default is the DCS installation root directory.
-- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt. -- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt.
--- Triggers the FSM event "Load" with a delay when the warehouse assets are loaded from disk. --- Triggers the FSM event "Load" with a delay when the warehouse assets are loaded from disk.
-- @function [parent=#WAREHOUSE] __Load -- @function [parent=#WAREHOUSE] __Load
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #number delay Delay in seconds. -- @param #number delay Delay in seconds.
-- @param #string path Path where the file is located. Default is the DCS installation root directory. -- @param #string path (Optional) Path where the file is located. Default is the DCS installation root directory.
-- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt. -- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt.
--- On after "Load" event user function. Called when the warehouse assets are loaded from disk. --- On after "Load" event user function. Called when the warehouse assets are loaded from disk.
@@ -2506,7 +2506,7 @@ function WAREHOUSE:New(warehouse, alias)
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #string path Path where the file is located. Default is the DCS installation root directory. -- @param #string path (Optional) Path where the file is located. Default is the DCS installation root directory.
-- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt. -- @param #string filename (Optional) File name. Default is WAREHOUSE-<UID>_<ALIAS>.txt.
@@ -2576,7 +2576,7 @@ end
--- Set low fuel threshold. If one unit of an asset has less fuel than this number, the event AssetLowFuel will be fired. --- Set low fuel threshold. If one unit of an asset has less fuel than this number, the event AssetLowFuel will be fired.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #number threshold Relative low fuel threshold, i.e. a number in [0,1]. Default 0.15 (15%). -- @param #number threshold (Optional) Relative low fuel threshold, i.e. a number in [0,1]. Default 0.15 (15%).
-- @return #WAREHOUSE self -- @return #WAREHOUSE self
function WAREHOUSE:SetLowFuelThreshold(threshold) function WAREHOUSE:SetLowFuelThreshold(threshold)
self.lowfuelthresh=threshold or 0.15 self.lowfuelthresh=threshold or 0.15
@@ -2594,7 +2594,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #WAREHOUSE self -- @return #WAREHOUSE self
function WAREHOUSE:SetVerbosityLevel(VerbosityLevel) function WAREHOUSE:SetVerbosityLevel(VerbosityLevel)
self.verbosity=VerbosityLevel or 0 self.verbosity=VerbosityLevel or 0
@@ -2705,7 +2705,7 @@ end
--- Enable auto save of warehouse assets at mission end event. --- Enable auto save of warehouse assets at mission end event.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #string path Path where to save the asset data file. -- @param #string path Path where to save the asset data file.
-- @param #string filename File name. Default is generated automatically from warehouse id. -- @param #string filename (Optional) File name. Default is generated automatically from warehouse id.
-- @return #WAREHOUSE self -- @return #WAREHOUSE self
function WAREHOUSE:SetSaveOnMissionEnd(path, filename) function WAREHOUSE:SetSaveOnMissionEnd(path, filename)
self.autosave=true self.autosave=true
@@ -3349,7 +3349,7 @@ end
-- Note that this is the time, the DCS engine uses not something we can control on a user level or we could get via scripting. -- Note that this is the time, the DCS engine uses not something we can control on a user level or we could get via scripting.
-- You need to input the value. On the DCS forum it was stated that this is currently one hour. Hence this is the default value. -- You need to input the value. On the DCS forum it was stated that this is currently one hour. Hence this is the default value.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #number RepairTime Time in seconds until the runway is repaired. Default 3600 sec (one hour). -- @param #number RepairTime (Optional) Time in seconds until the runway is repaired. Default 3600 sec (one hour).
-- @return #WAREHOUSE self -- @return #WAREHOUSE self
function WAREHOUSE:SetRunwayRepairtime(RepairTime) function WAREHOUSE:SetRunwayRepairtime(RepairTime)
self.runwayrepairtime=RepairTime or 3600 self.runwayrepairtime=RepairTime or 3600
@@ -3891,7 +3891,7 @@ end
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param Wrapper.Group#GROUP group Group or template group to be added to the warehouse stock. -- @param Wrapper.Group#GROUP group Group or template group to be added to the warehouse stock.
-- @param #number ngroups Number of groups to add to the warehouse stock. Default is 1. -- @param #number ngroups (Optional) Number of groups to add to the warehouse stock. Default is 1.
-- @param #WAREHOUSE.Attribute forceattribute (Optional) Explicitly force a generalized attribute for the asset. This has to be an @{#WAREHOUSE.Attribute}. -- @param #WAREHOUSE.Attribute forceattribute (Optional) Explicitly force a generalized attribute for the asset. This has to be an @{#WAREHOUSE.Attribute}.
-- @param #number forcecargobay (Optional) Explicitly force cargobay weight limit in kg for cargo carriers. This is for each *unit* of the group. -- @param #number forcecargobay (Optional) Explicitly force cargobay weight limit in kg for cargo carriers. This is for each *unit* of the group.
-- @param #number forceweight (Optional) Explicitly force weight in kg of each unit in the group. -- @param #number forceweight (Optional) Explicitly force weight in kg of each unit in the group.
@@ -6226,7 +6226,7 @@ end
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param Wrapper.Group#GROUP Group The train group. -- @param Wrapper.Group#GROUP Group The train group.
-- @param Core.Point#COORDINATE Coordinate of the destination. Tail will be routed to the closest point -- @param Core.Point#COORDINATE Coordinate of the destination. Tail will be routed to the closest point
-- @param #number Speed Speed in km/h to drive to the destination coordinate. Default is 60% of max possible speed the unit can go. -- @param #number Speed (Optional) Speed in km/h to drive to the destination coordinate. Default is 60% of max possible speed the unit can go.
function WAREHOUSE:_RouteTrain(Group, Coordinate, Speed) function WAREHOUSE:_RouteTrain(Group, Coordinate, Speed)
if Group and Group:IsAlive() then if Group and Group:IsAlive() then
@@ -8783,7 +8783,7 @@ end
--- Info Message. Message send to coalition if reports or debug mode activated (and duration > 0). Text self:I(text) added to DCS.log file. --- Info Message. Message send to coalition if reports or debug mode activated (and duration > 0). Text self:I(text) added to DCS.log file.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #string text The text of the error message. -- @param #string text The text of the error message.
-- @param #number duration Message display duration in seconds. Default 20 sec. If duration is zero, no message is displayed. -- @param #number duration (Optional) Message display duration in seconds. Default 20 sec. If duration is zero, no message is displayed.
function WAREHOUSE:_InfoMessage(text, duration) function WAREHOUSE:_InfoMessage(text, duration)
duration=duration or 20 duration=duration or 20
if duration>0 and self.Debug or self.Report then if duration>0 and self.Debug or self.Report then
@@ -8796,7 +8796,7 @@ end
--- Debug message. Message send to all if debug mode is activated (and duration > 0). Text self:T(text) added to DCS.log file. --- Debug message. Message send to all if debug mode is activated (and duration > 0). Text self:T(text) added to DCS.log file.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #string text The text of the error message. -- @param #string text The text of the error message.
-- @param #number duration Message display duration in seconds. Default 20 sec. If duration is zero, no message is displayed. -- @param #number duration (Optional) Message display duration in seconds. Default 20 sec. If duration is zero, no message is displayed.
function WAREHOUSE:_DebugMessage(text, duration) function WAREHOUSE:_DebugMessage(text, duration)
duration=duration or 20 duration=duration or 20
if self.Debug and duration>0 then if self.Debug and duration>0 then
@@ -8808,7 +8808,7 @@ end
--- Error message. Message send to all (if duration > 0). Text self:E(text) added to DCS.log file. --- Error message. Message send to all (if duration > 0). Text self:E(text) added to DCS.log file.
-- @param #WAREHOUSE self -- @param #WAREHOUSE self
-- @param #string text The text of the error message. -- @param #string text The text of the error message.
-- @param #number duration Message display duration in seconds. Default 20 sec. If duration is zero, no message is displayed. -- @param #number duration (Optional) Message display duration in seconds. Default 20 sec. If duration is zero, no message is displayed.
function WAREHOUSE:_ErrorMessage(text, duration) function WAREHOUSE:_ErrorMessage(text, duration)
duration=duration or 20 duration=duration or 20
if duration>0 then if duration>0 then
@@ -365,8 +365,8 @@ do -- ZONE_CAPTURE_COALITION
-- @param #ZONE_CAPTURE_COALITION self -- @param #ZONE_CAPTURE_COALITION self
-- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved. Alternatively, can be handed as the name of late activated group describing a @{Core.Zone#ZONE_POLYGON} with its waypoints. -- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved. Alternatively, can be handed as the name of late activated group describing a @{Core.Zone#ZONE_POLYGON} with its waypoints.
-- @param #number Coalition The initial coalition owning the zone. -- @param #number Coalition The initial coalition owning the zone.
-- @param #table UnitCategories Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}. -- @param #table UnitCategories (Optional) Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}.
-- @param #table ObjectCategories Table of unit categories. See [DCS Class Object](https://wiki.hoggitworld.com/view/DCS_Class_Object). Default {Object.Category.UNIT, Object.Category.STATIC}, i.e. all UNITS and STATICS. -- @param #table ObjectCategories (Optional) Table of unit categories. See [DCS Class Object](https://wiki.hoggitworld.com/view/DCS_Class_Object). Default {Object.Category.UNIT, Object.Category.STATIC}, i.e. all UNITS and STATICS.
-- @return #ZONE_CAPTURE_COALITION -- @return #ZONE_CAPTURE_COALITION
-- @usage -- @usage
-- --
@@ -54,8 +54,8 @@ do -- ZoneGoal
--- ZONE_GOAL_COALITION Constructor. --- ZONE_GOAL_COALITION Constructor.
-- @param #ZONE_GOAL_COALITION self -- @param #ZONE_GOAL_COALITION self
-- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved. -- @param Core.Zone#ZONE Zone A @{Core.Zone} object with the goal to be achieved.
-- @param #number Coalition The initial coalition owning the zone. Default coalition.side.NEUTRAL. -- @param #number Coalition (Optional) The initial coalition owning the zone. Default coalition.side.NEUTRAL.
-- @param #table UnitCategories Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}. -- @param #table UnitCategories (Optional) Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}.
-- @return #ZONE_GOAL_COALITION -- @return #ZONE_GOAL_COALITION
function ZONE_GOAL_COALITION:New( Zone, Coalition, UnitCategories ) function ZONE_GOAL_COALITION:New( Zone, Coalition, UnitCategories )
@@ -90,7 +90,7 @@ do -- ZoneGoal
--- Set the owning coalition of the zone. --- Set the owning coalition of the zone.
-- @param #ZONE_GOAL_COALITION self -- @param #ZONE_GOAL_COALITION self
-- @param #table UnitCategories Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}. -- @param #table UnitCategories (Optional) Table of unit categories. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). Default {Unit.Category.GROUND_UNIT}.
-- @return #ZONE_GOAL_COALITION -- @return #ZONE_GOAL_COALITION
function ZONE_GOAL_COALITION:SetUnitCategories( UnitCategories ) function ZONE_GOAL_COALITION:SetUnitCategories( UnitCategories )
@@ -105,7 +105,7 @@ do -- ZoneGoal
--- Set the owning coalition of the zone. --- Set the owning coalition of the zone.
-- @param #ZONE_GOAL_COALITION self -- @param #ZONE_GOAL_COALITION self
-- @param #table ObjectCategories Table of unit categories. See [DCS Class Object](https://wiki.hoggitworld.com/view/DCS_Class_Object). Default {Object.Category.UNIT, Object.Category.STATIC}, i.e. all UNITS and STATICS. -- @param #table ObjectCategories (Optional) Table of unit categories. See [DCS Class Object](https://wiki.hoggitworld.com/view/DCS_Class_Object). Default {Object.Category.UNIT, Object.Category.STATIC}, i.e. all UNITS and STATICS.
-- @return #ZONE_GOAL_COALITION -- @return #ZONE_GOAL_COALITION
function ZONE_GOAL_COALITION:SetObjectCategories( ObjectCategories ) function ZONE_GOAL_COALITION:SetObjectCategories( ObjectCategories )
+3
View File
@@ -85,6 +85,9 @@ __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/RecoveryTanker.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/RescueHelo.lua' ) __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/RescueHelo.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/ATIS.lua' ) __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/ATIS.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CTLD.lua' ) __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CTLD.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CTLD_CARGO.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CTLD_Localization.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CTLD_Hercules.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CSAR.lua' ) __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/CSAR.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/AirWing.lua' ) __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/AirWing.lua' )
__Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/ArmyGroup.lua' ) __Moose.Include( MOOSE_DEVELOPMENT_FOLDER..'/Moose/Ops/ArmyGroup.lua' )
@@ -242,7 +242,7 @@ end
--- Find closest beacons to a given coordinate. --- Find closest beacons to a given coordinate.
-- @param #BEACONS self -- @param #BEACONS self
-- @param Core.Point#COORDINATE Coordinate The reference coordinate. -- @param Core.Point#COORDINATE Coordinate The reference coordinate.
-- @param #number Nmax Max number of beacons. Default 5. -- @param #number Nmax (Optional) Max number of beacons. Default 5.
-- @param #number TypeID (Optional) Only search for specific beacon types, *e.g.* `BEACON.Type.TACAN`. -- @param #number TypeID (Optional) Only search for specific beacon types, *e.g.* `BEACON.Type.TACAN`.
-- @param #number DistMax (Optional) Max search distance in meters. -- @param #number DistMax (Optional) Max search distance in meters.
-- @return #table Table of #BEACONS.Beacon closest beacons. -- @return #table Table of #BEACONS.Beacon closest beacons.
+6 -6
View File
@@ -115,7 +115,7 @@ NAVFIX.version="0.1.0"
--- Create a new NAVFIX class instance from a given VECTOR. --- Create a new NAVFIX class instance from a given VECTOR.
-- @param #NAVFIX self -- @param #NAVFIX self
-- @param #string Name Name/ident of the point. Should be unique! -- @param #string Name Name/ident of the point. Should be unique!
-- @param #string Type Type of the point. Default `NAVFIX.Type.POINT`. -- @param #string Type (Optional) Type of the point. Default `NAVFIX.Type.POINT`.
-- @param Core.Vector#VECTOR Vector Position vector of the navpoint. -- @param Core.Vector#VECTOR Vector Position vector of the navpoint.
-- @return #NAVFIX self -- @return #NAVFIX self
function NAVFIX:NewFromVector(Name, Type, Vector) function NAVFIX:NewFromVector(Name, Type, Vector)
@@ -150,7 +150,7 @@ end
--- Create a new NAVFIX class instance from a given COORDINATE. --- Create a new NAVFIX class instance from a given COORDINATE.
-- @param #NAVFIX self -- @param #NAVFIX self
-- @param #string Name Name of the fix. Should be unique! -- @param #string Name Name of the fix. Should be unique!
-- @param #string Type Type of the point. Default `NAVFIX.Type.POINT`. -- @param #string Type (Optional) Type of the point. Default `NAVFIX.Type.POINT`.
-- @param Core.Point#COORDINATE Coordinate Coordinate of the point. -- @param Core.Point#COORDINATE Coordinate Coordinate of the point.
-- @return #NAVFIX self -- @return #NAVFIX self
function NAVFIX:NewFromCoordinate(Name, Type, Coordinate) function NAVFIX:NewFromCoordinate(Name, Type, Coordinate)
@@ -168,7 +168,7 @@ end
--- Create a new NAVFIX instance from given latitude and longitude in degrees, minutes and seconds (DMS). --- Create a new NAVFIX instance from given latitude and longitude in degrees, minutes and seconds (DMS).
-- @param #NAVFIX self -- @param #NAVFIX self
-- @param #string Name Name of the fix. Should be unique! -- @param #string Name Name of the fix. Should be unique!
-- @param #string Type Type of the point. Default `NAVFIX.Type.POINT`. -- @param #string Type (Optional) Type of the point. Default `NAVFIX.Type.POINT`.
-- @param #string Latitude Latitude in DMS as string. -- @param #string Latitude Latitude in DMS as string.
-- @param #string Longitude Longitude in DMS as string. -- @param #string Longitude Longitude in DMS as string.
-- @return #NAVFIX self -- @return #NAVFIX self
@@ -186,7 +186,7 @@ end
--- Create a new NAVFIX instance from given latitude and longitude in decimal degrees (DD). --- Create a new NAVFIX instance from given latitude and longitude in decimal degrees (DD).
-- @param #NAVFIX self -- @param #NAVFIX self
-- @param #string Name Name of the fix. Should be unique! -- @param #string Name Name of the fix. Should be unique!
-- @param #string Type Type of the point. Default `NAVFIX.Type.POINT`. -- @param #string Type (Optional) Type of the point. Default `NAVFIX.Type.POINT`.
-- @param #number Latitude Latitude in DD. -- @param #number Latitude Latitude in DD.
-- @param #number Longitude Longitude in DD. -- @param #number Longitude Longitude in DD.
-- @return #NAVFIX self -- @return #NAVFIX self
@@ -523,7 +523,7 @@ NAVAID.version="0.1.0"
--- Create a new NAVAID class instance. --- Create a new NAVAID class instance.
-- @param #NAVAID self -- @param #NAVAID self
-- @param #string Name Name/ident of this navaid. -- @param #string Name Name/ident of this navaid.
-- @param #string Type Type of the point. Default `NAVFIX.Type.POINT`. -- @param #string Type (Optional) Type of the point. Default `NAVFIX.Type.POINT`.
-- @param #string ZoneName Name of the zone to scan the scenery. -- @param #string ZoneName Name of the zone to scan the scenery.
-- @param #string SceneryName Name of the scenery object. -- @param #string SceneryName Name of the scenery object.
-- @return #NAVAID self -- @return #NAVAID self
@@ -579,7 +579,7 @@ end
--- Set channel of, *e.g.*, TACAN beacons. --- Set channel of, *e.g.*, TACAN beacons.
-- @param #NAVAID self -- @param #NAVAID self
-- @param #number Channel The channel. -- @param #number Channel The channel.
-- @param #string Band The band either `"X"` (default) or `"Y"`. -- @param #string Band (Optional) The band either `"X"` (default) or `"Y"`.
-- @return #NAVAID self -- @return #NAVAID self
function NAVAID:SetChannel(Channel, Band) function NAVAID:SetChannel(Channel, Band)
@@ -249,7 +249,7 @@ end
--- Find closest radios to a given coordinate. --- Find closest radios to a given coordinate.
-- @param #RADIOS self -- @param #RADIOS self
-- @param Core.Point#COORDINATE Coordinate The reference coordinate. -- @param Core.Point#COORDINATE Coordinate The reference coordinate.
-- @param #number Nmax Max number of radios. Default 5. -- @param #number Nmax (Optional) Max number of radios. Default 5.
-- @param #number DistMax (Optional) Max search distance in meters. -- @param #number DistMax (Optional) Max search distance in meters.
-- @return #table Table of #RADIOS.Radio closest radios. -- @return #table Table of #RADIOS.Radio closest radios.
function RADIOS:GetClosestRadios(Coordinate, Nmax, DistMax) function RADIOS:GetClosestRadios(Coordinate, Nmax, DistMax)
+1 -1
View File
@@ -240,7 +240,7 @@ end
--- Find closest towns to a given coordinate. --- Find closest towns to a given coordinate.
-- @param #TOWNS self -- @param #TOWNS self
-- @param Core.Point#COORDINATE Coordinate The reference coordinate. -- @param Core.Point#COORDINATE Coordinate The reference coordinate.
-- @param #number Nmax Max number of towns. Default 5. -- @param #number Nmax (Optional) Max number of towns. Default 5.
-- @param #number DistMax (Optional) Max search distance in meters. -- @param #number DistMax (Optional) Max search distance in meters.
-- @return #table Table of #TOWNS.Town closest towns. -- @return #table Table of #TOWNS.Town closest towns.
function TOWNS:GetClosestTowns(Coordinate, Nmax, DistMax) function TOWNS:GetClosestTowns(Coordinate, Nmax, DistMax)
+22 -22
View File
@@ -1003,8 +1003,8 @@ ATIS.version = "1.0.1"
--- Create a new ATIS class object for a specific airbase. --- Create a new ATIS class object for a specific airbase.
-- @param #ATIS self -- @param #ATIS self
-- @param #string AirbaseName Name of the airbase. -- @param #string AirbaseName Name of the airbase.
-- @param #number Frequency Radio frequency in MHz. Default 143.00 MHz. When using **SRS** this can be passed as a table of multiple frequencies. -- @param #number Frequency (Optional) Radio frequency in MHz. Default 143.00 MHz. When using **SRS** this can be passed as a table of multiple frequencies.
-- @param #number Modulation Radio modulation: 0=AM, 1=FM. Default 0=AM. See `radio.modulation.AM` and `radio.modulation.FM` enumerators. When using **SRS** this can be passed as a table of multiple modulations. -- @param #number Modulation (Optional) Radio modulation: 0=AM, 1=FM. Default 0=AM. See `radio.modulation.AM` and `radio.modulation.FM` enumerators. When using **SRS** this can be passed as a table of multiple modulations.
-- @return #ATIS self -- @return #ATIS self
function ATIS:New(AirbaseName, Frequency, Modulation) function ATIS:New(AirbaseName, Frequency, Modulation)
@@ -1161,9 +1161,9 @@ end
--- Set sound files folder within miz file (not your local hard drive!). --- Set sound files folder within miz file (not your local hard drive!).
-- @param #ATIS self -- @param #ATIS self
-- @param #string pathMain Path to folder containing main sound files. Default "ATIS Soundfiles/". Mind the slash "/" at the end! -- @param #string pathMain (Optional) Path to folder containing main sound files. Default "ATIS Soundfiles/". Mind the slash "/" at the end!
-- @param #string pathAirports Path folder containing the airport names sound files. Default is `"ATIS Soundfiles/<Map Name>"`, *e.g.* `"ATIS Soundfiles/Caucasus/"`. -- @param #string pathAirports (Optional) Path folder containing the airport names sound files. Default is `"ATIS Soundfiles/<Map Name>"`, *e.g.* `"ATIS Soundfiles/Caucasus/"`.
-- @param #string pathNato Path folder containing the NATO alphabet sound files. Default is "ATIS Soundfiles/NATO Alphabet/". -- @param #string pathNato (Optional) Path folder containing the NATO alphabet sound files. Default is "ATIS Soundfiles/NATO Alphabet/".
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetSoundfilesPath( pathMain, pathAirports, pathNato ) function ATIS:SetSoundfilesPath( pathMain, pathAirports, pathNato )
self.soundpath = tostring( pathMain or "ATIS Soundfiles/" ) self.soundpath = tostring( pathMain or "ATIS Soundfiles/" )
@@ -1283,8 +1283,8 @@ end
--- Set the active runway for landing. --- Set the active runway for landing.
-- @param #ATIS self -- @param #ATIS self
-- @param #string runway : Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction. -- @param #string runway (Optional) Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction.
-- @param #boolean preferleft : If true, perfer the left runway. If false, prefer the right runway. If nil (default), do not care about left or right. -- @param #boolean preferleft (Optional) If true, perfer the left runway. If false, prefer the right runway. If nil (default), do not care about left or right.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetActiveRunwayLanding(runway, preferleft) function ATIS:SetActiveRunwayLanding(runway, preferleft)
self.airbase:SetActiveRunwayLanding(runway,preferleft) self.airbase:SetActiveRunwayLanding(runway,preferleft)
@@ -1294,7 +1294,7 @@ end
--- Set the active runway for take-off. --- Set the active runway for take-off.
-- @param #ATIS self -- @param #ATIS self
-- @param #string runway : Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction. -- @param #string runway : Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction.
-- @param #boolean preferleft : If true, perfer the left runway. If false, prefer the right runway. If nil (default), do not care about left or right. -- @param #boolean preferleft (Optional) If true, perfer the left runway. If false, prefer the right runway. If nil (default), do not care about left or right.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetActiveRunwayTakeoff(runway,preferleft) function ATIS:SetActiveRunwayTakeoff(runway,preferleft)
self.airbase:SetActiveRunwayTakeoff(runway,preferleft) self.airbase:SetActiveRunwayTakeoff(runway,preferleft)
@@ -1328,7 +1328,7 @@ end
--- Set radio power. Note that this only applies if no relay unit is used. --- Set radio power. Note that this only applies if no relay unit is used.
-- @param #ATIS self -- @param #ATIS self
-- @param #number power Radio power in Watts. Default 100 W. -- @param #number power (Optional) Radio power in Watts. Default 100 W.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetRadioPower( power ) function ATIS:SetRadioPower( power )
self.power = power or 100 self.power = power or 100
@@ -1337,7 +1337,7 @@ end
--- Use F10 map mark points. --- Use F10 map mark points.
-- @param #ATIS self -- @param #ATIS self
-- @param #boolean switch If *true* or *nil*, marks are placed on F10 map. If *false* this feature is set to off (default). -- @param #boolean switch (Optional) If *true* or *nil*, marks are placed on F10 map. If *false* this feature is set to off (default).
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetMapMarks( switch ) function ATIS:SetMapMarks( switch )
if switch == nil or switch == true then if switch == nil or switch == true then
@@ -1406,7 +1406,7 @@ end
--- Set duration how long subtitles are displayed. --- Set duration how long subtitles are displayed.
-- @param #ATIS self -- @param #ATIS self
-- @param #number duration Duration in seconds. Default 10 seconds. -- @param #number duration (Optional) Duration in seconds. Default 10 seconds.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetSubtitleDuration( duration ) function ATIS:SetSubtitleDuration( duration )
self.subduration = tonumber( duration or 10 ) self.subduration = tonumber( duration or 10 )
@@ -1449,7 +1449,7 @@ end
--- Set relative humidity. This is used to approximately calculate the dew point. --- Set relative humidity. This is used to approximately calculate the dew point.
-- Note that the dew point is only an artificial information as DCS does not have an atmospheric model that includes humidity (yet). -- Note that the dew point is only an artificial information as DCS does not have an atmospheric model that includes humidity (yet).
-- @param #ATIS self -- @param #ATIS self
-- @param #number Humidity Relative Humidity, i.e. a number between 0 and 100 %. Default is 50 %. -- @param #number Humidity (Optional) Relative Humidity, i.e. a number between 0 and 100 %. Default is 50 %.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetRelativeHumidity( Humidity ) function ATIS:SetRelativeHumidity( Humidity )
self.relHumidity = Humidity or 50 self.relHumidity = Humidity or 50
@@ -1524,7 +1524,7 @@ end
-- Or you make your life simple and just include the sign so you don't have to bother about East/West. -- Or you make your life simple and just include the sign so you don't have to bother about East/West.
-- --
-- @param #ATIS self -- @param #ATIS self
-- @param #number magvar Magnetic variation in degrees. Positive for easterly and negative for westerly variation. Default is magnatic declinaton of the used map, c.f. @{Utilities.Utils#UTILS.GetMagneticDeclination}. -- @param #number magvar (Optional) Magnetic variation in degrees. Positive for easterly and negative for westerly variation. Default is magnatic declinaton of the used map, c.f. @{Utilities.Utils#UTILS.GetMagneticDeclination}.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetMagneticDeclination( magvar ) function ATIS:SetMagneticDeclination( magvar )
self.magvar = magvar or UTILS.GetMagneticDeclination() self.magvar = magvar or UTILS.GetMagneticDeclination()
@@ -1654,7 +1654,7 @@ end
--- Place marks with runway data on the F10 map. --- Place marks with runway data on the F10 map.
-- @param #ATIS self -- @param #ATIS self
-- @param #boolean markall If true, mark all runways of the map. By default only the current ATIS runways are marked. -- @param #boolean markall (Optional) If true, mark all runways of the map. By default only the current ATIS runways are marked.
function ATIS:MarkRunways( markall ) function ATIS:MarkRunways( markall )
local airbases = AIRBASE.GetAllAirbases() local airbases = AIRBASE.GetAllAirbases()
for _, _airbase in pairs( airbases ) do for _, _airbase in pairs( airbases ) do
@@ -1667,11 +1667,11 @@ end
--- Use SRS Simple-Text-To-Speech for transmissions. No sound files necessary.`SetSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible. --- Use SRS Simple-Text-To-Speech for transmissions. No sound files necessary.`SetSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible.
-- @param #ATIS self -- @param #ATIS self
-- @param #string PathToSRS Path to SRS directory (only necessary if SRS exe backend is used). -- @param #string PathToSRS (Optional) Path to SRS directory (only necessary if SRS exe backend is used).
-- @param #string Gender Gender: "male" or "female" (default). -- @param #string Gender (Optional) Gender: "male" or "female" (default).
-- @param #string Culture Culture, e.g. "en-GB" (default). -- @param #string Culture (Optional) Culture, e.g. "en-GB" (default).
-- @param #string Voice Specific voice. Overrides `Gender` and `Culture`. -- @param #string Voice (Optional) Specific voice. Overrides `Gender` and `Culture`.
-- @param #number Port SRS port. Default 5002. -- @param #number Port (Optional) SRS port. Default 5002.
-- @param #string GoogleKey Path to Google JSON-Key (SRS exe backend) or Google API key (DCS-gRPC backend). -- @param #string GoogleKey Path to Google JSON-Key (SRS exe backend) or Google API key (DCS-gRPC backend).
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetSRS(PathToSRS, Gender, Culture, Voice, Port, GoogleKey) function ATIS:SetSRS(PathToSRS, Gender, Culture, Voice, Port, GoogleKey)
@@ -1727,7 +1727,7 @@ end
--- Set the time interval between radio queue updates. --- Set the time interval between radio queue updates.
-- @param #ATIS self -- @param #ATIS self
-- @param #number TimeInterval Interval in seconds. Default 5 sec. -- @param #number TimeInterval (Optional) Interval in seconds. Default 5 sec.
-- @return #ATIS self -- @return #ATIS self
function ATIS:SetQueueUpdateTime( TimeInterval ) function ATIS:SetQueueUpdateTime( TimeInterval )
self.dTQueueCheck = TimeInterval or 5 self.dTQueueCheck = TimeInterval or 5
@@ -3195,7 +3195,7 @@ end
--- Get active runway runway. --- Get active runway runway.
-- @param #ATIS self -- @param #ATIS self
-- @param #boolean Takeoff If `true`, get runway for takeoff. Default is for landing. -- @param #boolean Takeoff (Optional) If `true`, get runway for takeoff. Default is for landing.
-- @return #string Active runway, e.g. "31" for 310 deg. -- @return #string Active runway, e.g. "31" for 310 deg.
-- @return #boolean Use Left=true, Right=false, or nil. -- @return #boolean Use Left=true, Right=false, or nil.
function ATIS:GetActiveRunway(Takeoff) function ATIS:GetActiveRunway(Takeoff)
@@ -3305,7 +3305,7 @@ end
-- @param #ATIS.Soundfile sound ATIS sound object. -- @param #ATIS.Soundfile sound ATIS sound object.
-- @param #number interval Interval in seconds after the last transmission finished. -- @param #number interval Interval in seconds after the last transmission finished.
-- @param #string subtitle Subtitle of the transmission. -- @param #string subtitle Subtitle of the transmission.
-- @param #string path Path to sound file. Default `self.soundpath`. -- @param #string path (Optional) Path to sound file. Default `self.soundpath`.
function ATIS:Transmission( sound, interval, subtitle, path ) function ATIS:Transmission( sound, interval, subtitle, path )
self.radioqueue:NewTransmission( sound.filename, sound.duration, path or self.soundpath, nil, interval, subtitle, self.subduration ) self.radioqueue:NewTransmission( sound.filename, sound.duration, path or self.soundpath, nil, interval, subtitle, self.subduration )
end end
+26 -26
View File
@@ -369,9 +369,9 @@ end
--- Add a **new** payload to the airwing resources. --- Add a **new** payload to the airwing resources.
-- @param #AIRWING self -- @param #AIRWING self
-- @param Wrapper.Unit#UNIT Unit The unit, the payload is extracted from. Can also be given as *#string* name of the unit. -- @param Wrapper.Unit#UNIT Unit The unit, the payload is extracted from. Can also be given as *#string* name of the unit.
-- @param #number Npayloads Number of payloads to add to the airwing resources. Default 99 (which should be enough for most scenarios). Set to -1 for unlimited. -- @param #number Npayloads (Optional) Number of payloads to add to the airwing resources. Default 99 (which should be enough for most scenarios). Set to -1 for unlimited.
-- @param #table MissionTypes Mission types this payload can be used for. -- @param #table MissionTypes Mission types this payload can be used for.
-- @param #number Performance A number between 0 (worst) and 100 (best) to describe the performance of the loadout for the given mission types. Default is 50. -- @param #number Performance (Optional) A number between 0 (worst) and 100 (best) to describe the performance of the loadout for the given mission types. Default is 50.
-- @return #AIRWING.Payload The payload table or nil if the unit does not exist. -- @return #AIRWING.Payload The payload table or nil if the unit does not exist.
function AIRWING:NewPayload(Unit, Npayloads, MissionTypes, Performance) function AIRWING:NewPayload(Unit, Npayloads, MissionTypes, Performance)
@@ -454,7 +454,7 @@ end
--- Set the number of payload available. --- Set the number of payload available.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #AIRWING.Payload Payload The payload table created by the `:NewPayload` function. -- @param #AIRWING.Payload Payload The payload table created by the `:NewPayload` function.
-- @param #number Navailable Number of payloads available to the airwing resources. Default 99 (which should be enough for most scenarios). Set to -1 for unlimited. -- @param #number Navailable (Optional) Number of payloads available to the airwing resources. Default 99 (which should be enough for most scenarios). Set to -1 for unlimited.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetPayloadAmount(Payload, Navailable) function AIRWING:SetPayloadAmount(Payload, Navailable)
@@ -477,7 +477,7 @@ end
--- Increase or decrease the amount of available payloads. Unlimited playloads first need to be set to a limited number with the `SetPayloadAmount` function. --- Increase or decrease the amount of available payloads. Unlimited playloads first need to be set to a limited number with the `SetPayloadAmount` function.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #AIRWING.Payload Payload The payload table created by the `:NewPayload` function. -- @param #AIRWING.Payload Payload The payload table created by the `:NewPayload` function.
-- @param #number N Number of payloads to be added. Use negative number to decrease amount. Default 1. -- @param #number N (Optional) Number of payloads to be added. Use negative number to decrease amount. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:IncreasePayloadAmount(Payload, N) function AIRWING:IncreasePayloadAmount(Payload, N)
@@ -516,7 +516,7 @@ end
-- @param #AIRWING self -- @param #AIRWING self
-- @param #AIRWING.Payload Payload The payload table to which the capability should be added. -- @param #AIRWING.Payload Payload The payload table to which the capability should be added.
-- @param #table MissionTypes Mission types to be added. -- @param #table MissionTypes Mission types to be added.
-- @param #number Performance A number between 0 (worst) and 100 (best) to describe the performance of the loadout for the given mission types. Default is 50. -- @param #number Performance (Optional) A number between 0 (worst) and 100 (best) to describe the performance of the loadout for the given mission types. Default is 50.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:AddPayloadCapability(Payload, MissionTypes, Performance) function AIRWING:AddPayloadCapability(Payload, MissionTypes, Performance)
@@ -739,7 +739,7 @@ end
--- Set number of CAP flights constantly carried out. --- Set number of CAP flights constantly carried out.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #number n Number of flights. Default 1. -- @param #number n (Optional) Number of flights. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetNumberCAP(n) function AIRWING:SetNumberCAP(n)
self.nflightsCAP=n or 1 self.nflightsCAP=n or 1
@@ -757,7 +757,7 @@ end
--- Set CAP close race track.We'll utilize the AUFTRAG PatrolRaceTrack instead of a standard race track orbit task. --- Set CAP close race track.We'll utilize the AUFTRAG PatrolRaceTrack instead of a standard race track orbit task.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #boolean OnOff If true, switch this on, else switch off. Off by default. -- @param #boolean OnOff (Optional) If true, switch this on, else switch off. Off by default.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetCapCloseRaceTrack(OnOff) function AIRWING:SetCapCloseRaceTrack(OnOff)
self.capOptionPatrolRaceTrack = OnOff self.capOptionPatrolRaceTrack = OnOff
@@ -777,7 +777,7 @@ end
--- Set number of TANKER flights with Boom constantly in the air. --- Set number of TANKER flights with Boom constantly in the air.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #number Nboom Number of flights. Default 1. -- @param #number Nboom (Optional) Number of flights. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetNumberTankerBoom(Nboom) function AIRWING:SetNumberTankerBoom(Nboom)
self.nflightsTANKERboom=Nboom or 1 self.nflightsTANKERboom=Nboom or 1
@@ -799,7 +799,7 @@ end
--- Set number of TANKER flights with Probe constantly in the air. --- Set number of TANKER flights with Probe constantly in the air.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #number Nprobe Number of flights. Default 1. -- @param #number Nprobe (Optional) Number of flights. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetNumberTankerProbe(Nprobe) function AIRWING:SetNumberTankerProbe(Nprobe)
self.nflightsTANKERprobe=Nprobe or 1 self.nflightsTANKERprobe=Nprobe or 1
@@ -808,7 +808,7 @@ end
--- Set number of AWACS flights constantly in the air. --- Set number of AWACS flights constantly in the air.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #number n Number of flights. Default 1. -- @param #number n (Optional) Number of flights. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetNumberAWACS(n) function AIRWING:SetNumberAWACS(n)
self.nflightsAWACS=n or 1 self.nflightsAWACS=n or 1
@@ -817,7 +817,7 @@ end
--- Set number of RECON flights constantly in the air. --- Set number of RECON flights constantly in the air.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #number n Number of flights. Default 1. -- @param #number n (Optional) Number of flights. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetNumberRecon(n) function AIRWING:SetNumberRecon(n)
self.nflightsRecon=n or 1 self.nflightsRecon=n or 1
@@ -826,7 +826,7 @@ end
--- Set number of Rescue helo flights constantly in the air. --- Set number of Rescue helo flights constantly in the air.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #number n Number of flights. Default 1. -- @param #number n (Optional) Number of flights. Default 1.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetNumberRescuehelo(n) function AIRWING:SetNumberRescuehelo(n)
self.nflightsRescueHelo=n or 1 self.nflightsRescueHelo=n or 1
@@ -868,13 +868,13 @@ end
--- Create a new generic patrol point. --- Create a new generic patrol point.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #string Type Patrol point type, e.g. "CAP" or "AWACS". Default "Unknown". -- @param #string Type (Optional) Patrol point type, e.g. "CAP" or "AWACS". Default "Unknown".
-- @param Core.Point#COORDINATE Coordinate Coordinate of the patrol point. Default 10-15 NM away from the location of the airwing. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone). -- @param Core.Point#COORDINATE Coordinate (Optional) Coordinate of the patrol point. Default 10-15 NM away from the location of the airwing. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone).
-- @param #number Altitude Orbit altitude in feet. Default random between Angels 10 and 20. -- @param #number Altitude (Optional) Orbit altitude in feet. Default random between Angels 10 and 20.
-- @param #number Heading Heading in degrees. Default random (0, 360] degrees. -- @param #number Heading (Optional) Heading in degrees. Default random (0, 360] degrees.
-- @param #number LegLength Length of race-track orbit in NM. Default 15 NM. -- @param #number LegLength (Optional) Length of race-track orbit in NM. Default 15 NM.
-- @param #number Speed Orbit speed in knots. Default 350 knots. -- @param #number Speed (Optional) Orbit speed in knots. Default 350 knots.
-- @param #number RefuelSystem Refueling system: 0=Boom, 1=Probe. Default nil=any. -- @param #number RefuelSystem (Optional) Refueling system: 0=Boom, 1=Probe. Default nil=any.
-- @return #AIRWING.PatrolData Patrol point table. -- @return #AIRWING.PatrolData Patrol point table.
function AIRWING:NewPatrolPoint(Type, Coordinate, Altitude, Speed, Heading, LegLength, RefuelSystem) function AIRWING:NewPatrolPoint(Type, Coordinate, Altitude, Speed, Heading, LegLength, RefuelSystem)
@@ -944,7 +944,7 @@ end
-- @param #number Speed Orbit speed in knots. -- @param #number Speed Orbit speed in knots.
-- @param #number Heading Heading in degrees. -- @param #number Heading Heading in degrees.
-- @param #number LegLength Length of race-track orbit in NM. -- @param #number LegLength Length of race-track orbit in NM.
-- @param #number RefuelSystem Set refueling system of tanker: 0=boom, 1=probe. Default any (=nil). -- @param #number RefuelSystem (Optional) Set refueling system of tanker: 0=boom, 1=probe. Default any (=nil).
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:AddPatrolPointTANKER(Coordinate, Altitude, Speed, Heading, LegLength, RefuelSystem) function AIRWING:AddPatrolPointTANKER(Coordinate, Altitude, Speed, Heading, LegLength, RefuelSystem)
@@ -984,7 +984,7 @@ end
--- Set takeoff type. All assets of this airwing will be spawned with this takeoff type. --- Set takeoff type. All assets of this airwing will be spawned with this takeoff type.
-- Spawning on runways is not supported. -- Spawning on runways is not supported.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #string TakeoffType Take off type: "Cold" (default) or "Hot" with engines on or "Air" for spawning in air. -- @param #string TakeoffType (Optional) Take off type: "Cold" (default) or "Hot" with engines on or "Air" for spawning in air.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetTakeoffType(TakeoffType) function AIRWING:SetTakeoffType(TakeoffType)
TakeoffType=TakeoffType or "Cold" TakeoffType=TakeoffType or "Cold"
@@ -1067,7 +1067,7 @@ end
--- Set despawn after landing. Aircraft will be despawned after the landing event. --- Set despawn after landing. Aircraft will be despawned after the landing event.
-- Can help to avoid DCS AI taxiing issues. -- Can help to avoid DCS AI taxiing issues.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #boolean Switch If `true` (default), activate despawn after landing. -- @param #boolean Switch (Optional) If `true` (default), activate despawn after landing.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetDespawnAfterLanding(Switch) function AIRWING:SetDespawnAfterLanding(Switch)
if Switch then if Switch then
@@ -1081,7 +1081,7 @@ end
--- Set despawn after holding. Aircraft will be despawned when they arrive at their holding position at the airbase. --- Set despawn after holding. Aircraft will be despawned when they arrive at their holding position at the airbase.
-- Can help to avoid DCS AI taxiing issues. -- Can help to avoid DCS AI taxiing issues.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #boolean Switch If `true` (default), activate despawn after landing. -- @param #boolean Switch (Optional) If `true` (default), activate despawn after landing.
-- @return #AIRWING self -- @return #AIRWING self
function AIRWING:SetDespawnAfterHolding(Switch) function AIRWING:SetDespawnAfterHolding(Switch)
if Switch then if Switch then
@@ -1581,9 +1581,9 @@ end
--- Count payloads in stock. --- Count payloads in stock.
-- @param #AIRWING self -- @param #AIRWING self
-- @param #table MissionTypes Types on mission to be checked. Default *all* possible types `AUFTRAG.Type`. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default *all* possible types `AUFTRAG.Type`.
-- @param #table UnitTypes Types of units. -- @param #table UnitTypes (Optional) Types of units.
-- @param #table Payloads Specific payloads to be counted only. -- @param #table Payloads (Optional) Specific payloads to be counted only.
-- @return #number Count of available payloads in stock. -- @return #number Count of available payloads in stock.
function AIRWING:CountPayloadsInStock(MissionTypes, UnitTypes, Payloads) function AIRWING:CountPayloadsInStock(MissionTypes, UnitTypes, Payloads)
+85 -85
View File
@@ -2456,7 +2456,7 @@ end
--- Set carrier controlled area (CCA). --- Set carrier controlled area (CCA).
-- This is a large zone around the carrier, which is constantly updated wrt the carrier position. -- This is a large zone around the carrier, which is constantly updated wrt the carrier position.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Radius Radius of zone in nautical miles (NM). Default 50 NM. -- @param #number Radius (Optional) Radius of zone in nautical miles (NM). Default 50 NM.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetCarrierControlledArea( Radius ) function AIRBOSS:SetCarrierControlledArea( Radius )
@@ -2470,7 +2470,7 @@ end
--- Set carrier controlled zone (CCZ). --- Set carrier controlled zone (CCZ).
-- This is a small zone (usually 5 NM radius) around the carrier, which is constantly updated wrt the carrier position. -- This is a small zone (usually 5 NM radius) around the carrier, which is constantly updated wrt the carrier position.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Radius Radius of zone in nautical miles (NM). Default 5 NM. -- @param #number Radius (Optional) Radius of zone in nautical miles (NM). Default 5 NM.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetCarrierControlledZone( Radius ) function AIRBOSS:SetCarrierControlledZone( Radius )
@@ -2483,7 +2483,7 @@ end
--- Set distance up to which water ahead is scanned for collisions. --- Set distance up to which water ahead is scanned for collisions.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Distance Distance in NM. Default 5 NM. -- @param #number Distance (Optional) Distance in NM. Default 5 NM.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetCollisionDistance( Distance ) function AIRBOSS:SetCollisionDistance( Distance )
self.collisiondist = UTILS.NMToMeters( Distance or 5 ) self.collisiondist = UTILS.NMToMeters( Distance or 5 )
@@ -2492,7 +2492,7 @@ end
--- Set the default recovery case. --- Set the default recovery case.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Case Case of recovery. Either 1, 2 or 3. Default 1. -- @param #number Case (Optional) Case of recovery. Either 1, 2 or 3. Default 1.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetRecoveryCase( Case ) function AIRBOSS:SetRecoveryCase( Case )
@@ -2509,7 +2509,7 @@ end
-- Usually, this is +-15 or +-30 degrees. You should not use and offset angle >= 90 degrees, because this will cause a devision by zero in some of the equations used to calculate the approach corridor. -- Usually, this is +-15 or +-30 degrees. You should not use and offset angle >= 90 degrees, because this will cause a devision by zero in some of the equations used to calculate the approach corridor.
-- So best stick to the defaults up to 30 degrees. -- So best stick to the defaults up to 30 degrees.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Offset Offset angle in degrees. Default 0. -- @param #number Offset (Optional) Offset angle in degrees. Default 0.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetHoldingOffsetAngle( Offset ) function AIRBOSS:SetHoldingOffsetAngle( Offset )
@@ -2524,10 +2524,10 @@ end
--- Enable F10 menu to manually start recoveries. --- Enable F10 menu to manually start recoveries.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Duration Default duration of the recovery in minutes. Default 30 min. -- @param #number Duration (Optional) Default duration of the recovery in minutes. Default 30 min.
-- @param #number WindOnDeck Default wind on deck in knots. Default 25 knots. -- @param #number WindOnDeck(Optional) Default wind on deck in knots. Default 25 knots.
-- @param #boolean Uturn U-turn after recovery window closes on=true or off=false/nil. Default off. -- @param #boolean Uturn (Optional) U-turn after recovery window closes on=true or off=false/nil. Default off.
-- @param #number Offset Relative Marshal radial in degrees for Case II/III recoveries. Default 30°. -- @param #number Offset (Optional) Relative Marshal radial in degrees for Case II/III recoveries. Default 30°.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMenuRecovery( Duration, WindOnDeck, Uturn, Offset ) function AIRBOSS:SetMenuRecovery( Duration, WindOnDeck, Uturn, Offset )
@@ -2547,13 +2547,13 @@ end
--- Add aircraft recovery time window and recovery case. --- Add aircraft recovery time window and recovery case.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string starttime Start time, e.g. "8:00" for eight o'clock. Default now. -- @param #string starttime (Optional) Start time, e.g. "8:00" for eight o'clock. Default now.
-- @param #string stoptime Stop time, e.g. "9:00" for nine o'clock. Default 90 minutes after start time. -- @param #string stoptime (Optional) Stop time, e.g. "9:00" for nine o'clock. Default 90 minutes after start time.
-- @param #number case Recovery case for that time slot. Number between one and three. -- @param #number case (Optional) Recovery case for that time slot. Number between one and three. Defaults to 1.
-- @param #number holdingoffset Only for CASE II/III: Angle in degrees the holding pattern is offset. -- @param #number holdingoffset (Optional) Only for CASE II/III: Angle in degrees the holding pattern is offset. Defaults to 0.
-- @param #boolean turnintowind If true, carrier will turn into the wind 5 minutes before the recovery window opens. -- @param #boolean turnintowind If true, carrier will turn into the wind 5 minutes before the recovery window opens.
-- @param #number speed Speed in knots during turn into wind leg. -- @param #number speed (Optional) Speed in knots during turn into wind leg. Default is 20.
-- @param #boolean uturn If true (or nil), carrier wil perform a U-turn and go back to where it came from before resuming its route to the next waypoint. If false, it will go directly to the next waypoint. -- @param #boolean uturn (Optional) If true (or nil), carrier wil perform a U-turn and go back to where it came from before resuming its route to the next waypoint. If false, it will go directly to the next waypoint.
-- @return #AIRBOSS.Recovery Recovery window. -- @return #AIRBOSS.Recovery Recovery window.
function AIRBOSS:AddRecoveryWindow( starttime, stoptime, case, holdingoffset, turnintowind, speed, uturn ) function AIRBOSS:AddRecoveryWindow( starttime, stoptime, case, holdingoffset, turnintowind, speed, uturn )
@@ -2735,7 +2735,7 @@ end
--- Set time before carrier turns and recovery window opens. --- Set time before carrier turns and recovery window opens.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Interval Time interval in seconds. Default 300 sec. -- @param #number Interval (Optional) Time interval in seconds. Default 300 sec.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetRecoveryTurnTime( Interval ) function AIRBOSS:SetRecoveryTurnTime( Interval )
self.dTturn = Interval or 300 self.dTturn = Interval or 300
@@ -2744,7 +2744,7 @@ end
--- Set multiplayer environment wire correction. --- Set multiplayer environment wire correction.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Dcorr Correction distance in meters. Default 12 m. -- @param #number Dcorr (Optional) Correction distance in meters. Default 12 m.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMPWireCorrection( Dcorr ) function AIRBOSS:SetMPWireCorrection( Dcorr )
self.mpWireCorrection = Dcorr or 12 self.mpWireCorrection = Dcorr or 12
@@ -2753,7 +2753,7 @@ end
--- Set time interval for updating queues and other stuff. --- Set time interval for updating queues and other stuff.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number TimeInterval Time interval in seconds. Default 30 sec. -- @param #number TimeInterval (Optional) Time interval in seconds. Default 30 sec.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetQueueUpdateTime( TimeInterval ) function AIRBOSS:SetQueueUpdateTime( TimeInterval )
self.dTqueue = TimeInterval or 30 self.dTqueue = TimeInterval or 30
@@ -2762,7 +2762,7 @@ end
--- Set time interval between LSO calls. Optimal time in the groove is ~16 seconds. So the default of 4 seconds gives around 3-4 correction calls in the groove. --- Set time interval between LSO calls. Optimal time in the groove is ~16 seconds. So the default of 4 seconds gives around 3-4 correction calls in the groove.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number TimeInterval Time interval in seconds between LSO calls. Default 4 sec. -- @param #number TimeInterval (Optional) Time interval in seconds between LSO calls. Default 4 sec.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetLSOCallInterval( TimeInterval ) function AIRBOSS:SetLSOCallInterval( TimeInterval )
self.LSOdT = TimeInterval or 4 self.LSOdT = TimeInterval or 4
@@ -2835,7 +2835,7 @@ end
--- Give AI aircraft the refueling task if a recovery tanker is present or send them to the nearest divert airfield. --- Give AI aircraft the refueling task if a recovery tanker is present or send them to the nearest divert airfield.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number LowFuelThreshold Low fuel threshold in percent. AI will go refueling if their fuel level drops below this value. Default 10 %. -- @param #number LowFuelThreshold (Optional) Low fuel threshold in percent. AI will go refueling if their fuel level drops below this value. Default 10 %.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetRefuelAI( LowFuelThreshold ) function AIRBOSS:SetRefuelAI( LowFuelThreshold )
self.lowfuelAI = LowFuelThreshold or 10 self.lowfuelAI = LowFuelThreshold or 10
@@ -2844,7 +2844,7 @@ end
--- Set max altitude to register flights in the initial zone. Aircraft above this altitude will not be registerered. --- Set max altitude to register flights in the initial zone. Aircraft above this altitude will not be registerered.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number MaxAltitude Max altitude in feet. Default 1300 ft. -- @param #number MaxAltitude (Optional) Max altitude in feet. Default 1300 ft.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetInitialMaxAlt( MaxAltitude ) function AIRBOSS:SetInitialMaxAlt( MaxAltitude )
self.initialmaxalt = UTILS.FeetToMeters( MaxAltitude or 1300 ) self.initialmaxalt = UTILS.FeetToMeters( MaxAltitude or 1300 )
@@ -2878,7 +2878,7 @@ end
--- Set time interval for updating player status and other things. --- Set time interval for updating player status and other things.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number TimeInterval Time interval in seconds. Default 0.5 sec. -- @param #number TimeInterval (Optional) Time interval in seconds. Default 0.5 sec.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetStatusUpdateTime( TimeInterval ) function AIRBOSS:SetStatusUpdateTime( TimeInterval )
self.dTstatus = TimeInterval or 0.5 self.dTstatus = TimeInterval or 0.5
@@ -2887,7 +2887,7 @@ end
--- Set duration how long messages are displayed to players. --- Set duration how long messages are displayed to players.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Duration Duration in seconds. Default 10 sec. -- @param #number Duration (Optional) Duration in seconds. Default 10 sec.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetDefaultMessageDuration( Duration ) function AIRBOSS:SetDefaultMessageDuration( Duration )
self.Tmessage = Duration or 10 self.Tmessage = Duration or 10
@@ -2978,7 +2978,7 @@ end
--- Set Case I Marshal radius. This is the radius of the valid zone around "the post" aircraft are supposed to be holding in the Case I Marshal stack. --- Set Case I Marshal radius. This is the radius of the valid zone around "the post" aircraft are supposed to be holding in the Case I Marshal stack.
-- The post is 2.5 NM port of the carrier. -- The post is 2.5 NM port of the carrier.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Radius Radius in NM. Default 2.8 NM, which gives a diameter of 5.6 NM. -- @param #number Radius (Optional) Radius in NM. Default 2.8 NM, which gives a diameter of 5.6 NM.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMarshalRadius( Radius ) function AIRBOSS:SetMarshalRadius( Radius )
self.marshalradius = UTILS.NMToMeters( Radius or 2.8 ) self.marshalradius = UTILS.NMToMeters( Radius or 2.8 )
@@ -3112,9 +3112,9 @@ end
--- Set up SRS for usage without sound files --- Set up SRS for usage without sound files
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string PathToSRS Path to SRS folder, e.g. "C:\\Program Files\\DCS-SimpleRadio\\ExternalAudio". -- @param #string PathToSRS Path to SRS folder, e.g. "C:\\Program Files\\DCS-SimpleRadio\\ExternalAudio".
-- @param #number Port Port of the SRS server, defaults to 5002. -- @param #number Port (Optional) Port of the SRS server, defaults to 5002.
-- @param #string Culture (Optional, Airboss Culture) Culture, defaults to "en-US". -- @param #string Culture (Optional) (Optional, Airboss Culture) Culture, defaults to "en-US".
-- @param #string Gender (Optional, Airboss Gender) Gender, e.g. "male" or "female". Defaults to "male". -- @param #string Gender (Optional) (Optional, Airboss Gender) Gender, e.g. "male" or "female". Defaults to "male".
-- @param #string Voice (Optional, Airboss Voice) Set to use a specific voice. Will **override gender and culture** settings. -- @param #string Voice (Optional, Airboss Voice) Set to use a specific voice. Will **override gender and culture** settings.
-- @param #string GoogleCreds (Optional) Path to Google credentials, e.g. "C:\\Program Files\\DCS-SimpleRadio-Standalone\\yourgooglekey.json". -- @param #string GoogleCreds (Optional) Path to Google credentials, e.g. "C:\\Program Files\\DCS-SimpleRadio-Standalone\\yourgooglekey.json".
-- @param #number Volume (Optional) E.g. 0.75. Defaults to 1.0 (loudest). -- @param #number Volume (Optional) E.g. 0.75. Defaults to 1.0 (loudest).
@@ -3365,7 +3365,7 @@ end
--- Set number of aircraft units, which can be in the landing pattern before the pattern is full. --- Set number of aircraft units, which can be in the landing pattern before the pattern is full.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number nmax Max number. Default 4. Minimum is 1, maximum is 6. -- @param #number nmax (Optional) Max number. Default 4. Minimum is 1, maximum is 6.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMaxLandingPattern( nmax ) function AIRBOSS:SetMaxLandingPattern( nmax )
nmax = nmax or 4 nmax = nmax or 4
@@ -3378,7 +3378,7 @@ end
--- Set number available Case I Marshal stacks. If Marshal stacks are full, flights requesting Marshal will be told to hold outside 10 NM zone until a stack becomes available again. --- Set number available Case I Marshal stacks. If Marshal stacks are full, flights requesting Marshal will be told to hold outside 10 NM zone until a stack becomes available again.
-- Marshal stacks for Case II/III are unlimited. -- Marshal stacks for Case II/III are unlimited.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number nmax Max number of stacks available to players and AI flights. Default 3, i.e. angels 2, 3, 4. Minimum is 1. -- @param #number nmax (Optional) Max number of stacks available to players and AI flights. Default 3, i.e. angels 2, 3, 4. Minimum is 1.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMaxMarshalStacks( nmax ) function AIRBOSS:SetMaxMarshalStacks( nmax )
self.Nmaxmarshal = nmax or 3 self.Nmaxmarshal = nmax or 3
@@ -3400,7 +3400,7 @@ end
--- Set maximum distance up to which section members are allowed (default: 100 meters). --- Set maximum distance up to which section members are allowed (default: 100 meters).
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number dmax Max distance in meters (default 100 m). Minimum is 10 m, maximum is 5000 m. -- @param #number dmax (Optional) Max distance in meters (default 100 m). Minimum is 10 m, maximum is 5000 m.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMaxSectionDistance( dmax ) function AIRBOSS:SetMaxSectionDistance( dmax )
if dmax then if dmax then
@@ -3416,7 +3416,7 @@ end
--- Set max number of flights per stack. All members of a section count as one "flight". --- Set max number of flights per stack. All members of a section count as one "flight".
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number nmax Number of max allowed flights per stack. Default is two. Minimum is one, maximum is 4. -- @param #number nmax (Optional) Number of max allowed flights per stack. Default is two. Minimum is one, maximum is 4.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMaxFlightsPerStack( nmax ) function AIRBOSS:SetMaxFlightsPerStack( nmax )
nmax = nmax or 2 nmax = nmax or 2
@@ -3436,7 +3436,7 @@ end
--- Will play the inbound calls, commencing, initial, etc. from the player when requesteing marshal --- Will play the inbound calls, commencing, initial, etc. from the player when requesteing marshal
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #AIRBOSS status Boolean to activate (true) / deactivate (false) the radio inbound calls (default is ON) -- @param #AIRBOSS status (Optional) Boolean to activate (true) / deactivate (false) the radio inbound calls (default is ON)
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetExtraVoiceOvers(status) function AIRBOSS:SetExtraVoiceOvers(status)
self.xtVoiceOvers=status self.xtVoiceOvers=status
@@ -3445,7 +3445,7 @@ end
--- Will simulate the inbound call, commencing, initial, etc from the AI when requested by Airboss --- Will simulate the inbound call, commencing, initial, etc from the AI when requested by Airboss
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #AIRBOSS status Boolean to activate (true) / deactivate (false) the radio inbound calls (default is ON) -- @param #AIRBOSS status (Optional) Boolean to activate (true) / deactivate (false) the radio inbound calls (default is ON)
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetExtraVoiceOversAI(status) function AIRBOSS:SetExtraVoiceOversAI(status)
self.xtVoiceOversAI=status self.xtVoiceOversAI=status
@@ -3484,7 +3484,7 @@ end
-- * "Naval Aviator" = @{#AIRBOSS.Difficulty.Normal} -- * "Naval Aviator" = @{#AIRBOSS.Difficulty.Normal}
-- * "TOPGUN Graduate" = @{#AIRBOSS.Difficulty.Hard} -- * "TOPGUN Graduate" = @{#AIRBOSS.Difficulty.Hard}
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string skill Player skill. Default "Naval Aviator". -- @param #string skill (Optional) Player skill. Default "Naval Aviator".
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetDefaultPlayerSkill( skill ) function AIRBOSS:SetDefaultPlayerSkill( skill )
@@ -3510,8 +3510,8 @@ end
--- Enable auto save of player results each time a player is *finally* graded. *Finally* means after the player landed on the carrier! After intermediate passes (bolter or waveoff) the stats are *not* saved. --- Enable auto save of player results each time a player is *finally* graded. *Finally* means after the player landed on the carrier! After intermediate passes (bolter or waveoff) the stats are *not* saved.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string path Path where to save the asset data file. Default is the DCS root installation directory or your "Saved Games\\DCS" folder if lfs was desanitized. -- @param #string path (Optional) Path where to save the asset data file. Default is the DCS root installation directory or your "Saved Games\\DCS" folder if lfs was desanitized.
-- @param #string filename File name. Default is generated automatically from airboss carrier name/alias. -- @param #string filename (Optional) File name. Default is generated automatically from airboss carrier name/alias.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetAutoSave( path, filename ) function AIRBOSS:SetAutoSave( path, filename )
self.autosave = true self.autosave = true
@@ -3543,7 +3543,7 @@ end
--- Set the magnetic declination (or variation). By default this is set to the standard declination of the map. --- Set the magnetic declination (or variation). By default this is set to the standard declination of the map.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number declination Declination in degrees or nil for default declination of the map. -- @param #number declination (Optional) Declination in degrees or nil for default declination of the map.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetMagneticDeclination( declination ) function AIRBOSS:SetMagneticDeclination( declination )
self.magvar = declination or UTILS.GetMagneticDeclination() self.magvar = declination or UTILS.GetMagneticDeclination()
@@ -3562,8 +3562,8 @@ end
--- Set FunkMan socket. LSO grades and trap sheets will be send to your Discord bot. --- Set FunkMan socket. LSO grades and trap sheets will be send to your Discord bot.
-- **Requires running FunkMan program**. -- **Requires running FunkMan program**.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number Port Port. Default `10042`. -- @param #number Port (Optional) Port. Default `10042`.
-- @param #string Host Host. Default `"127.0.0.1"`. -- @param #string Host (Optional) Host. Default `"127.0.0.1"`.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:SetFunkManOn(Port, Host) function AIRBOSS:SetFunkManOn(Port, Host)
@@ -3574,7 +3574,7 @@ end
--- Get next time the carrier will start recovering aircraft. --- Get next time the carrier will start recovering aircraft.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #boolean InSeconds If true, abs. mission time seconds is returned. Default is a clock #string. -- @param #boolean InSeconds (Optional) If true, abs. mission time seconds is returned. Default is a clock #string.
-- @return #string Clock start (or start time in abs. seconds). -- @return #string Clock start (or start time in abs. seconds).
-- @return #string Clock stop (or stop time in abs. seconds). -- @return #string Clock stop (or stop time in abs. seconds).
function AIRBOSS:GetNextRecoveryTime( InSeconds ) function AIRBOSS:GetNextRecoveryTime( InSeconds )
@@ -6737,7 +6737,7 @@ end
--- Get marshal altitude and two positions of a counter-clockwise race track pattern. --- Get marshal altitude and two positions of a counter-clockwise race track pattern.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number stack Assigned stack number. Counting starts at one, i.e. stack=1 is the first stack. -- @param #number stack Assigned stack number. Counting starts at one, i.e. stack=1 is the first stack.
-- @param #number case Recovery case. Default is self.case. -- @param #number case (Optional) Recovery case. Default is self.case.
-- @return #number Holding altitude in meters. -- @return #number Holding altitude in meters.
-- @return Core.Point#COORDINATE First race track coordinate. -- @return Core.Point#COORDINATE First race track coordinate.
-- @return Core.Point#COORDINATE Second race track coordinate. -- @return Core.Point#COORDINATE Second race track coordinate.
@@ -7098,8 +7098,8 @@ end
--- Get next free Marshal stack. Depending on AI/human and recovery case. --- Get next free Marshal stack. Depending on AI/human and recovery case.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #boolean ai If true, get a free stack for an AI flight group. -- @param #boolean ai If true, get a free stack for an AI flight group.
-- @param #number case Recovery case. Default current (self) case in progress. -- @param #number case (Optional) Recovery case. Default current (self) case in progress.
-- @param #boolean empty Return lowest stack that is completely empty. -- @param #boolean empty (Optional) Return lowest stack that is completely empty.
-- @return #number Lowest free stack available for the given case or nil if all Case I stacks are taken. -- @return #number Lowest free stack available for the given case or nil if all Case I stacks are taken.
function AIRBOSS:_GetFreeStack( ai, case, empty ) function AIRBOSS:_GetFreeStack( ai, case, empty )
@@ -7188,7 +7188,7 @@ end
--- Get next free Marshal stack. Depending on AI/human and recovery case. --- Get next free Marshal stack. Depending on AI/human and recovery case.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #boolean ai If true, get a free stack for an AI flight group. -- @param #boolean ai If true, get a free stack for an AI flight group.
-- @param #number case Recovery case. Default current (self) case in progress. -- @param #number case (Optional) Recovery case. Default current (self) case in progress.
-- @param #boolean empty Return lowest stack that is completely empty. -- @param #boolean empty Return lowest stack that is completely empty.
-- @return #number Lowest free stack available for the given case or nil if all Case I stacks are taken. -- @return #number Lowest free stack available for the given case or nil if all Case I stacks are taken.
function AIRBOSS:_GetFreeStack_Old( ai, case, empty ) function AIRBOSS:_GetFreeStack_Old( ai, case, empty )
@@ -7256,7 +7256,7 @@ end
--- Get number of (airborne) units in a flight. --- Get number of (airborne) units in a flight.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #AIRBOSS.FlightGroup flight The flight group. -- @param #AIRBOSS.FlightGroup flight The flight group.
-- @param #boolean onground If true, include units on the ground. By default only airborne units are counted. -- @param #boolean onground (Optional) If true, include units on the ground. By default only airborne units are counted.
-- @return #number Number of units in flight including section members. -- @return #number Number of units in flight including section members.
-- @return #number Number of units in flight excluding section members. -- @return #number Number of units in flight excluding section members.
-- @return #number Number of section members. -- @return #number Number of section members.
@@ -10961,9 +10961,9 @@ end
--- Get groove zone. --- Get groove zone.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number l Length of the groove in NM. Default 1.5 NM. -- @param #number l (Optional) Length of the groove in NM. Default 1.5 NM.
-- @param #number w Width of the groove in NM. Default 0.25 NM. -- @param #number w (Optional) Width of the groove in NM. Default 0.25 NM.
-- @param #number b Width of the beginning in NM. Default 0.10 NM. -- @param #number b (Optional) Width of the beginning in NM. Default 0.10 NM.
-- @return Core.Zone#ZONE_POLYGON_BASE Groove zone. -- @return Core.Zone#ZONE_POLYGON_BASE Groove zone.
function AIRBOSS:_GetZoneGroove( l, w, b ) function AIRBOSS:_GetZoneGroove( l, w, b )
@@ -11134,7 +11134,7 @@ end
--- Get approach corridor zone. Shape depends on recovery case. --- Get approach corridor zone. Shape depends on recovery case.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number case Recovery case. -- @param #number case Recovery case.
-- @param #number l Length of the zone in NM. Default 31 (=21+10) NM. -- @param #number l (Optional) Length of the zone in NM. Default 31 (=21+10) NM.
-- @return Core.Zone#ZONE_POLYGON_BASE Box zone. -- @return Core.Zone#ZONE_POLYGON_BASE Box zone.
function AIRBOSS:_GetZoneCorridor( case, l ) function AIRBOSS:_GetZoneCorridor( case, l )
@@ -11980,7 +11980,7 @@ end
--- Get true (or magnetic) heading of carrier. --- Get true (or magnetic) heading of carrier.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #boolean magnetic If true, calculate magnetic heading. By default true heading is returned. -- @param #boolean magnetic (Optional) If true, calculate magnetic heading. By default true heading is returned.
-- @return #number Carrier heading in degrees. -- @return #number Carrier heading in degrees.
function AIRBOSS:GetHeading( magnetic ) function AIRBOSS:GetHeading( magnetic )
self:F3( { magnetic = magnetic } ) self:F3( { magnetic = magnetic } )
@@ -12013,8 +12013,8 @@ end
--- Get wind direction and speed at carrier position. --- Get wind direction and speed at carrier position.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number alt Altitude ASL in meters. Default 18 m. -- @param #number alt (Optional) Altitude ASL in meters. Default 18 m.
-- @param #boolean magnetic Direction including magnetic declination. -- @param #boolean magnetic (Optional) Direction including magnetic declination.
-- @param Core.Point#COORDINATE coord (Optional) Coordinate at which to get the wind. Default is current carrier position. -- @param Core.Point#COORDINATE coord (Optional) Coordinate at which to get the wind. Default is current carrier position.
-- @return #number Direction the wind is blowing **from** in degrees. -- @return #number Direction the wind is blowing **from** in degrees.
-- @return #number Wind speed in m/s. -- @return #number Wind speed in m/s.
@@ -12040,7 +12040,7 @@ end
--- Get wind speed on carrier deck parallel and perpendicular to runway. --- Get wind speed on carrier deck parallel and perpendicular to runway.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number alt Altitude in meters. Default 18 m. -- @param #number alt (Optional) Altitude in meters. Default 18 m.
-- @return #number Wind component parallel to runway im m/s. -- @return #number Wind component parallel to runway im m/s.
-- @return #number Wind component perpendicular to runway in m/s. -- @return #number Wind component perpendicular to runway in m/s.
-- @return #number Total wind strength in m/s. -- @return #number Total wind strength in m/s.
@@ -12086,7 +12086,7 @@ end
--- Get true (or magnetic) heading of carrier into the wind. This accounts for the angled runway. --- Get true (or magnetic) heading of carrier into the wind. This accounts for the angled runway.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number vdeck Desired wind velocity over deck in knots. -- @param #number vdeck Desired wind velocity over deck in knots.
-- @param #boolean magnetic If true, calculate magnetic heading. By default true heading is returned. -- @param #boolean magnetic (Optional) If true, calculate magnetic heading. By default true heading is returned.
-- @param Core.Point#COORDINATE coord (Optional) Coordinate from which heading is calculated. Default is current carrier position. -- @param Core.Point#COORDINATE coord (Optional) Coordinate from which heading is calculated. Default is current carrier position.
-- @return #number Carrier heading in degrees. -- @return #number Carrier heading in degrees.
-- @return #number Carrier speed in knots to reach desired wind speed on deck. -- @return #number Carrier speed in knots to reach desired wind speed on deck.
@@ -12106,7 +12106,7 @@ end
--- Get true (or magnetic) heading of carrier into the wind. This accounts for the angled runway. --- Get true (or magnetic) heading of carrier into the wind. This accounts for the angled runway.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number vdeck Desired wind velocity over deck in knots. -- @param #number vdeck Desired wind velocity over deck in knots.
-- @param #boolean magnetic If true, calculate magnetic heading. By default true heading is returned. -- @param #boolean magnetic (Optional) If true, calculate magnetic heading. By default true heading is returned.
-- @param Core.Point#COORDINATE coord (Optional) Coordinate from which heading is calculated. Default is current carrier position. -- @param Core.Point#COORDINATE coord (Optional) Coordinate from which heading is calculated. Default is current carrier position.
-- @return #number Carrier heading in degrees. -- @return #number Carrier heading in degrees.
function AIRBOSS:GetHeadingIntoWind_old( vdeck, magnetic, coord ) function AIRBOSS:GetHeadingIntoWind_old( vdeck, magnetic, coord )
@@ -12179,7 +12179,7 @@ end
-- Implementation based on [Mags & Bambi](https://magwo.github.io/carrier-cruise/). -- Implementation based on [Mags & Bambi](https://magwo.github.io/carrier-cruise/).
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number vdeck Desired wind velocity over deck in knots. -- @param #number vdeck Desired wind velocity over deck in knots.
-- @param #boolean magnetic If true, calculate magnetic heading. By default true heading is returned. -- @param #boolean magnetic (Optional) If true, calculate magnetic heading. By default true heading is returned.
-- @param Core.Point#COORDINATE coord (Optional) Coordinate from which heading is calculated. Default is current carrier position. -- @param Core.Point#COORDINATE coord (Optional) Coordinate from which heading is calculated. Default is current carrier position.
-- @return #number Carrier heading in degrees. -- @return #number Carrier heading in degrees.
-- @return #number Carrier speed in knots to reach desired wind speed on deck. -- @return #number Carrier speed in knots to reach desired wind speed on deck.
@@ -12310,9 +12310,9 @@ end
-- --
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #number case Recovery case. -- @param #number case Recovery case.
-- @param #boolean magnetic If true, magnetic radial is returned. Default is true radial. -- @param #boolean magnetic (Optional) If true, magnetic radial is returned. Default is true radial.
-- @param #boolean offset If true, inlcude holding offset. -- @param #boolean offset (Optional) If true, inlcude holding offset.
-- @param #boolean inverse Return inverse, i.e. radial-180 degrees. -- @param #boolean inverse (Optional) Return inverse, i.e. radial-180 degrees.
-- @return #number Radial in degrees. -- @return #number Radial in degrees.
function AIRBOSS:GetRadial( case, magnetic, offset, inverse ) function AIRBOSS:GetRadial( case, magnetic, offset, inverse )
@@ -13258,7 +13258,7 @@ end
--- Get short name of the grove step. --- Get short name of the grove step.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string step Player step. -- @param #string step Player step.
-- @param #number n Use -1 for previous or +1 for next. Default 0. -- @param #number n (Optional) Use -1 for previous or +1 for next. Default 0.
-- @return #string Shortcut name "X", "RB", "IM", "AR", "IW". -- @return #string Shortcut name "X", "RB", "IM", "AR", "IW".
function AIRBOSS:_GS( step, n ) function AIRBOSS:_GS( step, n )
local gp local gp
@@ -13457,7 +13457,7 @@ end
--- Display hint to player. --- Display hint to player.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #AIRBOSS.PlayerData playerData Player data table. -- @param #AIRBOSS.PlayerData playerData Player data table.
-- @param #number delay Delay before playing sound messages. Default 0 sec. -- @param #number delay (Optional) Delay before playing sound messages. Default 0 sec.
-- @param #boolean soundoff If true, don't play and sound hint. -- @param #boolean soundoff If true, don't play and sound hint.
function AIRBOSS:_PlayerHint( playerData, delay, soundoff ) function AIRBOSS:_PlayerHint( playerData, delay, soundoff )
@@ -14279,7 +14279,7 @@ end
--- Check Collision. --- Check Collision.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param Core.Point#COORDINATE fromcoord Coordinate from which the path to the next WP is calculated. Default current carrier position. -- @param Core.Point#COORDINATE fromcoord (Optional) Coordinate from which the path to the next WP is calculated. Default current carrier position.
-- @return #boolean If true, surface type ahead is not deep water. -- @return #boolean If true, surface type ahead is not deep water.
function AIRBOSS:_CheckFreePathToNextWP( fromcoord ) function AIRBOSS:_CheckFreePathToNextWP( fromcoord )
@@ -14357,9 +14357,9 @@ end
--- Let the carrier make a detour to a given point. When it reaches the point, it will resume its normal route. --- Let the carrier make a detour to a given point. When it reaches the point, it will resume its normal route.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param Core.Point#COORDINATE coord Coordinate of the detour. -- @param Core.Point#COORDINATE coord Coordinate of the detour.
-- @param #number speed Speed in knots. Default is current carrier velocity. -- @param #number speed (Optional) Speed in knots. Default is current carrier velocity.
-- @param #boolean uturn (Optional) If true, carrier will go back to where it came from before it resumes its route to the next waypoint. -- @param #boolean uturn (Optional) If true, carrier will go back to where it came from before it resumes its route to the next waypoint.
-- @param #number uspeed Speed in knots after U-turn. Default is same as before. -- @param #number uspeed (Optional) Speed in knots after U-turn. Default is same as before.
-- @param Core.Point#COORDINATE tcoord Additional coordinate to make turn smoother. -- @param Core.Point#COORDINATE tcoord Additional coordinate to make turn smoother.
-- @return #AIRBOSS self -- @return #AIRBOSS self
function AIRBOSS:CarrierDetour( coord, speed, uturn, uspeed, tcoord ) function AIRBOSS:CarrierDetour( coord, speed, uturn, uspeed, tcoord )
@@ -16093,11 +16093,11 @@ end
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #AIRBOSS.PlayerData playerData Player data. -- @param #AIRBOSS.PlayerData playerData Player data.
-- @param #string message The message to send. -- @param #string message The message to send.
-- @param #string sender The person who sends the message or nil. -- @param #string sender (Optional) The person who sends the message or nil. Defaults to nil.
-- @param #string receiver The person who receives the message. Default player's onboard number. Set to "" for no receiver. -- @param #string receiver (Optional) The person who receives the message. Default player's onboard number. Set to "" for no receiver.
-- @param #number duration Display message duration. Default 10 seconds. -- @param #number duration (Optional) Display message duration. Default 10 seconds.
-- @param #boolean clear If true, clear screen from previous messages. -- @param #boolean clear I(Optional) f true, clear screen from previous messages. Defaults to false.
-- @param #number delay Delay in seconds, before the message is displayed. -- @param #number delay (Optional) Delay in seconds, before the message is displayed.
function AIRBOSS:MessageToPlayer( playerData, message, sender, receiver, duration, clear, delay ) function AIRBOSS:MessageToPlayer( playerData, message, sender, receiver, duration, clear, delay )
self:T({sender,receiver,message}) self:T({sender,receiver,message})
if playerData and message and message ~= "" then if playerData and message and message ~= "" then
@@ -16221,11 +16221,11 @@ end
-- Message format will be "SENDER: RECCEIVER, MESSAGE". -- Message format will be "SENDER: RECCEIVER, MESSAGE".
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string message The message to send. -- @param #string message The message to send.
-- @param #string sender The person who sends the message or nil. -- @param #string sender (Optional) The person who sends the message or nil. Defaults to "LSO".
-- @param #string receiver The person who receives the message. Default player's onboard number. Set to "" for no receiver. -- @param #string receiver (Optional) The person who receives the message. Default player's onboard number. Set to "" for no receiver.
-- @param #number duration Display message duration. Default 10 seconds. -- @param #number duration (Optional) Display message duration. Default 10 seconds.
-- @param #boolean clear If true, clear screen from previous messages. -- @param #boolean clear (Optional) If true, clear screen from previous messages.
-- @param #number delay Delay in seconds, before the message is displayed. -- @param #number delay (Optional) Delay in seconds, before the message is displayed.
function AIRBOSS:MessageToPattern( message, sender, receiver, duration, clear, delay ) function AIRBOSS:MessageToPattern( message, sender, receiver, duration, clear, delay )
-- Create new (fake) radio call to show the subtitile. -- Create new (fake) radio call to show the subtitile.
@@ -16240,11 +16240,11 @@ end
-- Message format will be "SENDER: RECCEIVER, MESSAGE". -- Message format will be "SENDER: RECCEIVER, MESSAGE".
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #string message The message to send. -- @param #string message The message to send.
-- @param #string sender The person who sends the message or nil. -- @param #string sender (Optional) The person who sends the message or nil. Defaults to "Marshal".
-- @param #string receiver The person who receives the message. Default player's onboard number. Set to "" for no receiver. -- @param #string receiver (Optional) The person who receives the message. Default player's onboard number. Set to "" for no receiver.
-- @param #number duration Display message duration. Default 10 seconds. -- @param #number duration (Optional) Display message duration. Default 10 seconds.
-- @param #boolean clear If true, clear screen from previous messages. -- @param #boolean clear (Optional) If true, clear screen from previous messages.
-- @param #number delay Delay in seconds, before the message is displayed. -- @param #number delay (Optional) Delay in seconds, before the message is displayed.
function AIRBOSS:MessageToMarshal( message, sender, receiver, duration, clear, delay ) function AIRBOSS:MessageToMarshal( message, sender, receiver, duration, clear, delay )
-- Create new (fake) radio call to show the subtitile. -- Create new (fake) radio call to show the subtitile.
@@ -16258,11 +16258,11 @@ end
--- Generate a new radio call (deepcopy) from an existing default call. --- Generate a new radio call (deepcopy) from an existing default call.
-- @param #AIRBOSS self -- @param #AIRBOSS self
-- @param #AIRBOSS.RadioCall call Radio call to be enhanced. -- @param #AIRBOSS.RadioCall call Radio call to be enhanced.
-- @param #string sender Sender of the message. Default is the radio alias. -- @param #string sender (Optional) Sender of the message. Default is the radio alias.
-- @param #string subtitle Subtitle of the message. Default from original radio call. Use "" for no subtitle. -- @param #string subtitle (Optional) Subtitle of the message. Default from original radio call. Use "" for no subtitle.
-- @param #number subduration Time in seconds the subtitle is displayed. Default 10 seconds. -- @param #number subduration (Optional) Time in seconds the subtitle is displayed. Default 10 seconds.
-- @param #string modexreceiver Onboard number of the receiver or nil. -- @param #string modexreceiver (Optional) Onboard number of the receiver or nil.
-- @param #string modexsender Onboard number of the sender or nil. -- @param #string modexsender (Optional) Onboard number of the sender or nil.
function AIRBOSS:_NewRadioCall( call, sender, subtitle, subduration, modexreceiver, modexsender ) function AIRBOSS:_NewRadioCall( call, sender, subtitle, subduration, modexreceiver, modexsender )
-- Create a new call -- Create a new call
@@ -19204,7 +19204,7 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #string path Path where the file is loaded from. Default is the DCS root installation folder or your "Saved Games\\DCS" folder if lfs was desanizied. -- @param #string path (Optional) Path where the file is loaded from. Default is the DCS root installation folder or your "Saved Games\\DCS" folder if lfs was desanizied.
-- @param #string filename (Optional) File name for saving the player grades. Default is "AIRBOSS-<ALIAS>_LSOgrades.csv". -- @param #string filename (Optional) File name for saving the player grades. Default is "AIRBOSS-<ALIAS>_LSOgrades.csv".
function AIRBOSS:onafterLoad( From, Event, To, path, filename ) function AIRBOSS:onafterLoad( From, Event, To, path, filename )
+40 -40
View File
@@ -463,10 +463,10 @@ end
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param Core.Point#COORDINATE Coordinate Coordinate of the target. -- @param Core.Point#COORDINATE Coordinate Coordinate of the target.
-- @param #string Clock Time when to start the attack. -- @param #string Clock Time when to start the attack.
-- @param #number Radius Radius in meters. Default 100 m. -- @param #number Radius (Optional) Radius in meters. Default 100 m.
-- @param #number Nshots Number of shots to fire. Default 3. -- @param #number Nshots (Optional) Number of shots to fire. Default 3.
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #number Prio Priority of the task. -- @param #number Prio (Optional) Priority of the task. Defaults to 50.
-- @return Ops.OpsGroup#OPSGROUP.Task The task table. -- @return Ops.OpsGroup#OPSGROUP.Task The task table.
function ARMYGROUP:AddTaskFireAtPoint(Coordinate, Clock, Radius, Nshots, WeaponType, Prio) function ARMYGROUP:AddTaskFireAtPoint(Coordinate, Clock, Radius, Nshots, WeaponType, Prio)
@@ -485,10 +485,10 @@ end
-- @param #number Heading Heading min in Degrees. -- @param #number Heading Heading min in Degrees.
-- @param #number Alpha Shooting angle in Degrees. -- @param #number Alpha Shooting angle in Degrees.
-- @param #number Altitude Altitude in meters. -- @param #number Altitude Altitude in meters.
-- @param #number Radius Radius in meters. Default 100 m. -- @param #number Radius (Optional) Radius in meters. Default 100 m.
-- @param #number Nshots Number of shots to fire. Default nil. -- @param #number Nshots (Optional) Number of shots to fire. Default nil.
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #number Prio Priority of the task. -- @param #number Prio (Optional) Priority of the task. Defaults to 50.
-- @return Ops.OpsGroup#OPSGROUP.Task The task table. -- @return Ops.OpsGroup#OPSGROUP.Task The task table.
function ARMYGROUP:AddTaskBarrage(Clock, Heading, Alpha, Altitude, Radius, Nshots, WeaponType, Prio) function ARMYGROUP:AddTaskBarrage(Clock, Heading, Alpha, Altitude, Radius, Nshots, WeaponType, Prio)
@@ -516,11 +516,11 @@ end
--- Add a *waypoint* task to fire at a given coordinate. --- Add a *waypoint* task to fire at a given coordinate.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param Core.Point#COORDINATE Coordinate Coordinate of the target. -- @param Core.Point#COORDINATE Coordinate Coordinate of the target.
-- @param Ops.OpsGroup#OPSGROUP.Waypoint Waypoint Where the task is executed. Default is next waypoint. -- @param Ops.OpsGroup#OPSGROUP.Waypoint Waypoint (Optional) Where the task is executed. Default is next waypoint.
-- @param #number Radius Radius in meters. Default 100 m. -- @param #number Radius (Optional) Radius in meters. Default 100 m.
-- @param #number Nshots Number of shots to fire. Default 3. -- @param #number Nshots (Optional) Number of shots to fire. Default 3.
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #number Prio Priority of the task. -- @param #number Prio (Optional) Priority of the task. Defaults to 50.
-- @return Ops.OpsGroup#OPSGROUP.Task The task table. -- @return Ops.OpsGroup#OPSGROUP.Task The task table.
function ARMYGROUP:AddTaskWaypointFireAtPoint(Coordinate, Waypoint, Radius, Nshots, WeaponType, Prio) function ARMYGROUP:AddTaskWaypointFireAtPoint(Coordinate, Waypoint, Radius, Nshots, WeaponType, Prio)
@@ -538,10 +538,10 @@ end
--- Add a *scheduled* task. --- Add a *scheduled* task.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param Wrapper.Group#GROUP TargetGroup Target group. -- @param Wrapper.Group#GROUP TargetGroup Target group.
-- @param #number WeaponExpend How much weapons does are used. -- @param #number WeaponExpend (Optional) How much weapons does are used. Defaults to "Auto".
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #string Clock Time when to start the attack. -- @param #string Clock (Optional) Time when to start the attack. Defaults to 5.
-- @param #number Prio Priority of the task. -- @param #number Prio (Optional) Priority of the task. Defaults to 50.
-- @return Ops.OpsGroup#OPSGROUP.Task The task table. -- @return Ops.OpsGroup#OPSGROUP.Task The task table.
function ARMYGROUP:AddTaskAttackGroup(TargetGroup, WeaponExpend, WeaponType, Clock, Prio) function ARMYGROUP:AddTaskAttackGroup(TargetGroup, WeaponExpend, WeaponType, Clock, Prio)
@@ -574,7 +574,7 @@ end
--- Define a set of possible retreat zones. --- Define a set of possible retreat zones.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param Core.Set#SET_ZONE RetreatZoneSet The retreat zone set. Default is an empty set. -- @param Core.Set#SET_ZONE RetreatZoneSet (Optional) The retreat zone set. Default is an empty set.
-- @return #ARMYGROUP self -- @return #ARMYGROUP self
function ARMYGROUP:SetRetreatZones(RetreatZoneSet) function ARMYGROUP:SetRetreatZones(RetreatZoneSet)
self.retreatZones=RetreatZoneSet or SET_ZONE:New() self.retreatZones=RetreatZoneSet or SET_ZONE:New()
@@ -592,7 +592,7 @@ end
--- Set suppression on. average, minimum and maximum time a unit is suppressed each time it gets hit. --- Set suppression on. average, minimum and maximum time a unit is suppressed each time it gets hit.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param #number Tave Average time [seconds] a group will be suppressed. Default is 15 seconds. -- @param #number Tave (Optional) Average time [seconds] a group will be suppressed. Default is 15 seconds.
-- @param #number Tmin (Optional) Minimum time [seconds] a group will be suppressed. Default is 5 seconds. -- @param #number Tmin (Optional) Minimum time [seconds] a group will be suppressed. Default is 5 seconds.
-- @param #number Tmax (Optional) Maximum time a group will be suppressed. Default is 25 seconds. -- @param #number Tmax (Optional) Maximum time a group will be suppressed. Default is 25 seconds.
-- @return #ARMYGROUP self -- @return #ARMYGROUP self
@@ -995,10 +995,10 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #number n Next waypoint index. Default is the one coming after that one that has been passed last. -- @param #number n (Optional) Next waypoint index. Default is the one coming after that one that has been passed last.
-- @param #number N Waypoint Max waypoint index to be included in the route. Default is the final waypoint. -- @param #number N (Optional) Waypoint Max waypoint index to be included in the route. Default is the final waypoint.
-- @param #number Speed Speed in knots. Default cruise speed. -- @param #number Speed (Optional) Speed in knots. Default cruise speed.
-- @param #number Formation Formation of the group. -- @param #number Formation (Optional) Formation of the group.
function ARMYGROUP:onbeforeUpdateRoute(From, Event, To, n, N, Speed, Formation) function ARMYGROUP:onbeforeUpdateRoute(From, Event, To, n, N, Speed, Formation)
-- Is transition allowed? We assume yes until proven otherwise. -- Is transition allowed? We assume yes until proven otherwise.
@@ -1082,10 +1082,10 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #number n Next waypoint index. Default is the one coming after that one that has been passed last. -- @param #number n (Optional) Next waypoint index. Default is the one coming after that one that has been passed last.
-- @param #number N Waypoint Max waypoint index to be included in the route. Default is the final waypoint. -- @param #number N (Optional) Waypoint Max waypoint index to be included in the route. Default is the final waypoint.
-- @param #number Speed Speed in knots. Default cruise speed. -- @param #number Speed (Optional) Speed in knots. Default cruise speed.
-- @param #number Formation Formation of the group. -- @param #number Formation (Optional) Formation of the group.
function ARMYGROUP:onafterUpdateRoute(From, Event, To, n, N, Speed, Formation) function ARMYGROUP:onafterUpdateRoute(From, Event, To, n, N, Speed, Formation)
-- Update route from this waypoint number onwards. -- Update route from this waypoint number onwards.
@@ -1358,7 +1358,7 @@ end
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param Core.Point#COORDINATE Coordinate Coordinate where to go. -- @param Core.Point#COORDINATE Coordinate Coordinate where to go.
-- @param #number Speed Speed in knots. Default cruise speed. -- @param #number Speed (Optional) Speed in knots. Default cruise speed.
-- @param #number Formation Formation of the group. -- @param #number Formation Formation of the group.
-- @param #number ResumeRoute If true, resume route after detour point was reached. If false, the group will stop at the detour point and wait for futher commands. -- @param #number ResumeRoute If true, resume route after detour point was reached. If false, the group will stop at the detour point and wait for futher commands.
function ARMYGROUP:onafterDetour(From, Event, To, Coordinate, Speed, Formation, ResumeRoute) function ARMYGROUP:onafterDetour(From, Event, To, Coordinate, Speed, Formation, ResumeRoute)
@@ -1738,7 +1738,7 @@ end
-- @param #string To To state. -- @param #string To To state.
-- @param Wrapper.Group#GROUP Group the group to be engaged. -- @param Wrapper.Group#GROUP Group the group to be engaged.
-- @param #number Speed Speed in knots. -- @param #number Speed Speed in knots.
-- @param #string Formation Formation used in the engagement. Default `ENUMS.Formation.Vehicle.Vee`. -- @param #string Formation (Optional) Formation used in the engagement. Default `ENUMS.Formation.Vehicle.Vee`.
function ARMYGROUP:onbeforeEngageTarget(From, Event, To, Target, Speed, Formation) function ARMYGROUP:onbeforeEngageTarget(From, Event, To, Target, Speed, Formation)
local dt=nil local dt=nil
@@ -1779,7 +1779,7 @@ end
-- @param #string To To state. -- @param #string To To state.
-- @param Ops.Target#TARGET Target The target to be engaged. Can also be a group or unit. -- @param Ops.Target#TARGET Target The target to be engaged. Can also be a group or unit.
-- @param #number Speed Attack speed in knots. -- @param #number Speed Attack speed in knots.
-- @param #string Formation Formation used in the engagement. Default `ENUMS.Formation.Vehicle.Vee`. -- @param #string Formation (Optional) Formation used in the engagement. Default `ENUMS.Formation.Vehicle.Vee`.
function ARMYGROUP:onafterEngageTarget(From, Event, To, Target, Speed, Formation) function ARMYGROUP:onafterEngageTarget(From, Event, To, Target, Speed, Formation)
self:T(self.lid.."Engaging Target") self:T(self.lid.."Engaging Target")
@@ -1983,10 +1983,10 @@ end
--- Add an a waypoint to the route. --- Add an a waypoint to the route.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param Core.Point#COORDINATE Coordinate The coordinate of the waypoint. -- @param Core.Point#COORDINATE Coordinate The coordinate of the waypoint.
-- @param #number Speed Speed in knots. Default is default cruise speed or 70% of max speed. -- @param #number Speed (Optional) Speed in knots. Default is default cruise speed or 70% of max speed.
-- @param #number AfterWaypointWithID Insert waypoint after waypoint given ID. Default is to insert as last waypoint. -- @param #number AfterWaypointWithID (Optional) Insert waypoint after waypoint given ID. Default is to insert as last waypoint.
-- @param #string Formation Formation the group will use. -- @param #string Formation (Optional) Formation the group will use.
-- @param #boolean Updateroute If true or nil, call UpdateRoute. If false, no call. -- @param #boolean Updateroute (Optional) If true or nil, call UpdateRoute. If false, no call.
-- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table. -- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table.
function ARMYGROUP:AddWaypoint(Coordinate, Speed, AfterWaypointWithID, Formation, Updateroute) function ARMYGROUP:AddWaypoint(Coordinate, Speed, AfterWaypointWithID, Formation, Updateroute)
@@ -2047,8 +2047,8 @@ end
--- Initialize group parameters. Also initializes waypoints if self.waypoints is nil. --- Initialize group parameters. Also initializes waypoints if self.waypoints is nil.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param #table Template Template used to init the group. Default is `self.template`. -- @param #table Template (Optional) Template used to init the group. Default is `self.template`.
-- @param #number Delay Delay in seconds before group is initialized. Default `nil`, *i.e.* instantaneous. -- @param #number Delay (Optional) Delay in seconds before group is initialized. Default `nil`, *i.e.* instantaneous.
-- @return #ARMYGROUP self -- @return #ARMYGROUP self
function ARMYGROUP:_InitGroup(Template, Delay) function ARMYGROUP:_InitGroup(Template, Delay)
@@ -2145,9 +2145,9 @@ end
--- Switch to a specific formation. --- Switch to a specific formation.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param #number Formation New formation the group will fly in. Default is the setting of `SetDefaultFormation()`. -- @param #number Formation (Optional) New formation the group will fly in. Default is the setting of `SetDefaultFormation()`.
-- @param #boolean Permanently If true, formation always used from now on. -- @param #boolean Permanently (Optional) If true, formation always used from now on. Defaults to false.
-- @param #boolean NoRouteUpdate If true, route is not updated. -- @param #boolean NoRouteUpdate (Optional) If true, route is not updated. Defaults to false.
-- @return #ARMYGROUP self -- @return #ARMYGROUP self
function ARMYGROUP:SwitchFormation(Formation, Permanently, NoRouteUpdate) function ARMYGROUP:SwitchFormation(Formation, Permanently, NoRouteUpdate)
@@ -2191,7 +2191,7 @@ end
--- Find the neares ammo supply group within a given radius. --- Find the neares ammo supply group within a given radius.
-- @param #ARMYGROUP self -- @param #ARMYGROUP self
-- @param #number Radius Search radius in NM. Default 30 NM. -- @param #number Radius (Optional) Search radius in NM. Default 30 NM.
-- @return Wrapper.Group#GROUP Closest ammo supplying group or `nil` if no group is in the given radius. -- @return Wrapper.Group#GROUP Closest ammo supplying group or `nil` if no group is in the given radius.
-- @return #number Distance to closest group in meters. -- @return #number Distance to closest group in meters.
function ARMYGROUP:FindNearestAmmoSupply(Radius) function ARMYGROUP:FindNearestAmmoSupply(Radius)
+187 -157
View File
@@ -676,7 +676,7 @@ AUFTRAG.Category={
--- AUFTRAG class version. --- AUFTRAG class version.
-- @field #string version -- @field #string version
AUFTRAG.version="1.4.0" AUFTRAG.version="1.4.1"
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- TODO list -- TODO list
@@ -1008,7 +1008,7 @@ end
--- **[AIR]** Create an ANTI-SHIP mission. --- **[AIR]** Create an ANTI-SHIP mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be passed as a @{Wrapper.Group#GROUP} or @{Wrapper.Unit#UNIT} object. -- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be passed as a @{Wrapper.Group#GROUP} or @{Wrapper.Unit#UNIT} object.
-- @param #number Altitude Engage altitude in feet. Default 2000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 2000 ft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewANTISHIP(Target, Altitude) function AUFTRAG:NewANTISHIP(Target, Altitude)
@@ -1038,10 +1038,10 @@ end
--- **[AIR ROTARY]** Create an HOVER mission. --- **[AIR ROTARY]** Create an HOVER mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Where to hover. -- @param Core.Point#COORDINATE Coordinate Where to hover.
-- @param #number Altitude Hover altitude in feet AGL. Default is 50 feet above ground. -- @param #number Altitude (Optional) Hover altitude in feet AGL. Default is 50 feet above ground.
-- @param #number Time Time in seconds to hold the hover. Default 300 seconds. -- @param #number Time (Optional) Time in seconds to hold the hover. Default 300 seconds.
-- @param #number Speed Speed in knots to fly to the target coordinate. Default 150kn. -- @param #number Speed (Optional) Speed in knots to fly to the target coordinate. Default 150kn.
-- @param #number MissionAlt Altitude to fly towards the mission in feet AGL. Default 1000ft. -- @param #number MissionAlt (Optional) Altitude to fly towards the mission in feet AGL. Default 1000ft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewHOVER(Coordinate, Altitude, Time, Speed, MissionAlt) function AUFTRAG:NewHOVER(Coordinate, Altitude, Time, Speed, MissionAlt)
@@ -1078,9 +1078,9 @@ end
-- @param Core.Point#COORDINATE Coordinate Where to land. -- @param Core.Point#COORDINATE Coordinate Where to land.
-- @param #number OuterRadius (Optional) Vary the coordinate by this many feet, e.g. get a new random coordinate between OuterRadius and (optionally) avoiding InnerRadius of the coordinate. -- @param #number OuterRadius (Optional) Vary the coordinate by this many feet, e.g. get a new random coordinate between OuterRadius and (optionally) avoiding InnerRadius of the coordinate.
-- @param #number InnerRadius (Optional) Vary the coordinate by this many feet, e.g. get a new random coordinate between OuterRadius and (optionally) avoiding InnerRadius of the coordinate. -- @param #number InnerRadius (Optional) Vary the coordinate by this many feet, e.g. get a new random coordinate between OuterRadius and (optionally) avoiding InnerRadius of the coordinate.
-- @param #number Time Time in seconds to stay. Default 300 seconds. -- @param #number Time (Optional) Time in seconds to stay. Default 300 seconds.
-- @param #number Speed Speed in knots to fly to the target coordinate. Default 150kn. -- @param #number Speed (Optional) Speed in knots to fly to the target coordinate. Default 150kn.
-- @param #number MissionAlt Altitude to fly towards the mission in feet AGL. Default 1000ft. -- @param #number MissionAlt A(Optional) ltitude to fly towards the mission in feet AGL. Default 1000ft.
-- @param #boolean CombatLanding (Optional) If true, set the Combat Landing option. -- @param #boolean CombatLanding (Optional) If true, set the Combat Landing option.
-- @param #number DirectionAfterLand (Optional) Heading after landing in degrees. -- @param #number DirectionAfterLand (Optional) Heading after landing in degrees.
-- @return #AUFTRAG self -- @return #AUFTRAG self
@@ -1168,10 +1168,10 @@ end
--- **[AIR]** Create an ORBIT mission, which can be either a circular orbit or a race-track pattern. --- **[AIR]** Create an ORBIT mission, which can be either a circular orbit or a race-track pattern.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Where to orbit. -- @param Core.Point#COORDINATE Coordinate Where to orbit.
-- @param #number Altitude Orbit altitude in feet above sea level. Default is y component of `Coordinate`. -- @param #number Altitude (Optional) Orbit altitude in feet above sea level. Default is y component of `Coordinate`.
-- @param #number Speed Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS. -- @param #number Speed (Optional) Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS.
-- @param #number Heading Heading of race-track pattern in degrees. If not specified, a circular orbit is performed. -- @param #number Heading (Optional) Heading of race-track pattern in degrees. If not specified, a circular orbit is performed.
-- @param #number Leg Length of race-track in NM. If not specified, a circular orbit is performed. -- @param #number Leg (Optional) Length of race-track in NM. If not specified, a circular orbit is performed.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewORBIT(Coordinate, Altitude, Speed, Heading, Leg) function AUFTRAG:NewORBIT(Coordinate, Altitude, Speed, Heading, Leg)
@@ -1222,8 +1222,8 @@ end
--- **[AIR]** Create an ORBIT mission, where the aircraft will go in a circle around the specified coordinate. --- **[AIR]** Create an ORBIT mission, where the aircraft will go in a circle around the specified coordinate.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Position where to orbit around. -- @param Core.Point#COORDINATE Coordinate Position where to orbit around.
-- @param #number Altitude Orbit altitude in feet. Default is y component of `Coordinate`. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is y component of `Coordinate`.
-- @param #number Speed Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS. -- @param #number Speed (Optional) Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewORBIT_CIRCLE(Coordinate, Altitude, Speed) function AUFTRAG:NewORBIT_CIRCLE(Coordinate, Altitude, Speed)
@@ -1235,10 +1235,10 @@ end
--- **[AIR]** Create an ORBIT mission, where the aircraft will fly a race-track pattern. --- **[AIR]** Create an ORBIT mission, where the aircraft will fly a race-track pattern.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Where to orbit. -- @param Core.Point#COORDINATE Coordinate Where to orbit.
-- @param #number Altitude Orbit altitude in feet. Default is y component of `Coordinate`. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is y component of `Coordinate`.
-- @param #number Speed Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS. -- @param #number Speed (Optional) Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS.
-- @param #number Heading Heading of race-track pattern in degrees. Default random in [0, 360) degrees. -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default random in [0, 360) degrees.
-- @param #number Leg Length of race-track in NM. Default 10 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 10 NM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewORBIT_RACETRACK(Coordinate, Altitude, Speed, Heading, Leg) function AUFTRAG:NewORBIT_RACETRACK(Coordinate, Altitude, Speed, Heading, Leg)
@@ -1253,12 +1253,12 @@ end
--- **[AIR]** Create an ORBIT mission, where the aircraft will fly a circular or race-track pattern over a given group or unit. --- **[AIR]** Create an ORBIT mission, where the aircraft will fly a circular or race-track pattern over a given group or unit.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Group#GROUP Group Group where to orbit around. Can also be a UNIT object. -- @param Wrapper.Group#GROUP Group Group where to orbit around. Can also be a UNIT object.
-- @param #number Altitude Orbit altitude in feet. Default is 6,000 ft. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 6,000 ft.
-- @param #number Speed Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS. -- @param #number Speed (Optional) Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS.
-- @param #number Leg Length of race-track in NM. Default nil. -- @param #number Leg (Optional) Length of race-track in NM. Default nil.
-- @param #number Heading Heading of race-track pattern in degrees. Default is heading of the group. -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default is heading of the group.
-- @param DCS#Vec2 OffsetVec2 Offset 2D-vector {x=0, y=0} in NM with respect to the group. Default directly overhead. Can also be given in polar coordinates `{r=5, phi=45}`. -- @param DCS#Vec2 OffsetVec2 (Optional) Offset 2D-vector {x=0, y=0} in NM with respect to the group. Default directly overhead. Can also be given in polar coordinates `{r=5, phi=45}`.
-- @param #number Distance Threshold distance in NM before orbit pattern is updated. Default 5 NM. -- @param #number Distance (Optional) Threshold distance in NM before orbit pattern is updated. Default 5 NM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewORBIT_GROUP(Group, Altitude, Speed, Leg, Heading, OffsetVec2, Distance) function AUFTRAG:NewORBIT_GROUP(Group, Altitude, Speed, Leg, Heading, OffsetVec2, Distance)
@@ -1301,10 +1301,10 @@ end
-- themselfs. They wait for the CHIEF to tell them whom to engage. -- themselfs. They wait for the CHIEF to tell them whom to engage.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Where to orbit. -- @param Core.Point#COORDINATE Coordinate Where to orbit.
-- @param #number Altitude Orbit altitude in feet. Default is y component of `Coordinate`. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is y component of `Coordinate`.
-- @param #number Speed Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS. -- @param #number Speed (Optional) Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS.
-- @param #number Heading Heading of race-track pattern in degrees. Default random in [0, 360) degrees. -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default random in [0, 360) degrees.
-- @param #number Leg Length of race-track in NM. Default 10 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 10 NM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewGCICAP(Coordinate, Altitude, Speed, Heading, Leg) function AUFTRAG:NewGCICAP(Coordinate, Altitude, Speed, Heading, Leg)
@@ -1328,10 +1328,10 @@ end
--- **[AIR]** Create a TANKER mission. --- **[AIR]** Create a TANKER mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Where to orbit. -- @param Core.Point#COORDINATE Coordinate Where to orbit.
-- @param #number Altitude Orbit altitude in feet. Default is y component of `Coordinate`. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is y component of `Coordinate`.
-- @param #number Speed Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS. -- @param #number Speed (Optional) Orbit indicated airspeed in knots at the set altitude ASL. Default 350 KIAS.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 10 NM. Set to 0 for a simple circular orbit. -- @param #number Leg (Optional) Length of race-track in NM. Default 10 NM. Set to 0 for a simple circular orbit.
-- @param #number RefuelSystem Refueling system (0=boom, 1=probe). This info is *only* for AIRWINGs so they launch the right tanker type. -- @param #number RefuelSystem Refueling system (0=boom, 1=probe). This info is *only* for AIRWINGs so they launch the right tanker type.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewTANKER(Coordinate, Altitude, Speed, Heading, Leg, RefuelSystem) function AUFTRAG:NewTANKER(Coordinate, Altitude, Speed, Heading, Leg, RefuelSystem)
@@ -1367,10 +1367,10 @@ end
--- **[AIR]** Create a AWACS mission. --- **[AIR]** Create a AWACS mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Coordinate Where to orbit. Altitude is also taken from the coordinate. -- @param Core.Point#COORDINATE Coordinate Where to orbit. Altitude is also taken from the coordinate.
-- @param #number Altitude Orbit altitude in feet. Default is y component of `Coordinate`. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is y component of `Coordinate`.
-- @param #number Speed Orbit speed in knots. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in knots. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 10 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 10 NM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewAWACS(Coordinate, Altitude, Speed, Heading, Leg) function AUFTRAG:NewAWACS(Coordinate, Altitude, Speed, Heading, Leg)
@@ -1422,12 +1422,12 @@ end
--- **[AIR]** Create a CAP mission. --- **[AIR]** Create a CAP mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE_RADIUS ZoneCAP Circular CAP zone. Detected targets in this zone will be engaged. -- @param Core.Zone#ZONE_RADIUS ZoneCAP Circular CAP zone. Detected targets in this zone will be engaged.
-- @param #number Altitude Altitude at which to orbit in feet. Default is 10,000 ft. -- @param #number Altitude (Optional) Altitude at which to orbit in feet. Default is 10,000 ft.
-- @param #number Speed Orbit speed in knots. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in knots. Default 350 kts.
-- @param Core.Point#COORDINATE Coordinate Where to orbit. Default is the center of the CAP zone. -- @param Core.Point#COORDINATE Coordinate (Optional) Where to orbit. Default is the center of the CAP zone.
-- @param #number Heading Heading of race-track pattern in degrees. If not specified, a simple circular orbit is performed. -- @param #number Heading (Optional) Heading of race-track pattern in degrees. If not specified, a simple circular orbit is performed.
-- @param #number Leg Length of race-track in NM. If not specified, a simple circular orbit is performed. -- @param #number Leg (Optional) Length of race-track in NM. If not specified, a simple circular orbit is performed.
-- @param #table TargetTypes Table of target types. Default {"Air"}. -- @param #table TargetTypes (Optional) Table of target types. Default {"Air"}.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewCAP(ZoneCAP, Altitude, Speed, Coordinate, Heading, Leg, TargetTypes) function AUFTRAG:NewCAP(ZoneCAP, Altitude, Speed, Coordinate, Heading, Leg, TargetTypes)
@@ -1464,15 +1464,15 @@ end
--- **[AIR]** Create a CAP mission over a (moving) group. --- **[AIR]** Create a CAP mission over a (moving) group.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Group#GROUP Grp The grp to perform the CAP over. -- @param Wrapper.Group#GROUP Grp The grp to perform the CAP over.
-- @param #number Altitude Orbit altitude in feet. Default is 6,000 ft. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 6,000 ft.
-- @param #number Speed Orbit speed in knots. Default 250 KIAS. -- @param #number Speed (Optional) Orbit speed in knots. Default 250 KIAS.
-- @param #number RelHeading Relative heading [0, 360) of race-track pattern in degrees wrt heading of the carrier. Default is heading of the carrier. -- @param #number RelHeading (Optional) Relative heading [0, 360) of race-track pattern in degrees wrt heading of the carrier. Default is heading of the carrier.
-- @param #number Leg Length of race-track in NM. Default 14 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 14 NM.
-- @param #number OffsetDist Relative distance of the first race-track point wrt to the carrier. Default 6 NM. -- @param #number OffsetDist (Optional) Relative distance of the first race-track point wrt to the carrier. Default 6 NM.
-- @param #number OffsetAngle Relative angle of the first race-track point wrt. to the carrier. Default 180 (behind the boat). -- @param #number OffsetAngle (Optional) Relative angle of the first race-track point wrt. to the carrier. Default 180 (behind the boat).
-- @param #number UpdateDistance Threshold distance in NM before orbit pattern is updated. Default 5 NM. -- @param #number UpdateDistance (Optional) Threshold distance in NM before orbit pattern is updated. Default 5 NM.
-- @param #table TargetTypes (Optional) Table of target types. Default `{"Air"}`. -- @param #table TargetTypes (Optional) Table of target types. Default `{"Air"}`.
-- @param #number EngageRange Max range in nautical miles that the escort group(s) will engage enemies. Default 32 NM (60 km). -- @param #number EngageRange (Optional) Max range in nautical miles that the escort group(s) will engage enemies. Default 32 NM (60 km).
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewCAPGROUP(Grp, Altitude, Speed, RelHeading, Leg, OffsetDist, OffsetAngle, UpdateDistance, TargetTypes, EngageRange) function AUFTRAG:NewCAPGROUP(Grp, Altitude, Speed, RelHeading, Leg, OffsetDist, OffsetAngle, UpdateDistance, TargetTypes, EngageRange)
@@ -1517,11 +1517,11 @@ end
--- **[AIR]** Create a CAS mission. --- **[AIR]** Create a CAS mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE_RADIUS ZoneCAS Circular CAS zone. Detected targets in this zone will be engaged. -- @param Core.Zone#ZONE_RADIUS ZoneCAS Circular CAS zone. Detected targets in this zone will be engaged.
-- @param #number Altitude Altitude at which to orbit. Default is 10,000 ft. -- @param #number Altitude (Optional) Altitude at which to orbit. Default is 10,000 ft.
-- @param #number Speed Orbit speed in knots. Default 350 KIAS. -- @param #number Speed (Optional) Orbit speed in knots. Default 350 KIAS.
-- @param Core.Point#COORDINATE Coordinate Where to orbit. Default is the center of the CAS zone. -- @param Core.Point#COORDINATE Coordinate (Optional) Where to orbit. Default is the center of the CAS zone.
-- @param #number Heading Heading of race-track pattern in degrees. If not specified, a simple circular orbit is performed. -- @param #number Heading (Optional) Heading of race-track pattern in degrees. If not specified, a simple circular orbit is performed.
-- @param #number Leg Length of race-track in NM. If not specified, a simple circular orbit is performed. -- @param #number Leg (Optional) Length of race-track in NM. If not specified, a simple circular orbit is performed.
-- @param #table TargetTypes (Optional) Table of target types. Default `{"Helicopters", "Ground Units", "Light armed ships"}`. -- @param #table TargetTypes (Optional) Table of target types. Default `{"Helicopters", "Ground Units", "Light armed ships"}`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewCAS(ZoneCAS, Altitude, Speed, Coordinate, Heading, Leg, TargetTypes) function AUFTRAG:NewCAS(ZoneCAS, Altitude, Speed, Coordinate, Heading, Leg, TargetTypes)
@@ -1555,11 +1555,11 @@ end
--- **[AIR]** Create a CASENHANCED mission. Group(s) will go to the zone and patrol it randomly. --- **[AIR]** Create a CASENHANCED mission. Group(s) will go to the zone and patrol it randomly.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE CasZone The CAS zone. -- @param Core.Zone#ZONE CasZone The CAS zone.
-- @param #number Altitude Altitude in feet. Only for airborne units. Default 2000 feet ASL. -- @param #number Altitude (Optional) Altitude in feet. Only for airborne units. Default 2000 feet ASL.
-- @param #number Speed Speed in knots. -- @param #number Speed (Optional) Speed in knots.
-- @param #number RangeMax Max range in NM. Only detected targets within this radius from the group will be engaged. Default is 25 NM. -- @param #number RangeMax (Optional) Max range in NM. Only detected targets within this radius from the group will be engaged. Default is 25 NM.
-- @param Core.Set#SET_ZONE NoEngageZoneSet Set of zones in which targets are *not* engaged. Default is nowhere. -- @param Core.Set#SET_ZONE NoEngageZoneSet (Optional) Set of zones in which targets are *not* engaged. Default is nowhere.
-- @param #table TargetTypes Types of target attributes that will be engaged. See [DCS enum attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes). Default `{"Helicopters", "Ground Units", "Light armed ships"}`. -- @param #table TargetTypes (Optional) Types of target attributes that will be engaged. See [DCS enum attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes). Default `{"Helicopters", "Ground Units", "Light armed ships"}`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewCASENHANCED(CasZone, Altitude, Speed, RangeMax, NoEngageZoneSet, TargetTypes) function AUFTRAG:NewCASENHANCED(CasZone, Altitude, Speed, RangeMax, NoEngageZoneSet, TargetTypes)
@@ -1597,11 +1597,10 @@ end
--- **[AIR, GROUND]** Create a FAC mission. Group(s) will go to the zone and patrol it randomly and act as FAC for detected units. --- **[AIR, GROUND]** Create a FAC mission. Group(s) will go to the zone and patrol it randomly and act as FAC for detected units.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE FacZone The FAC zone (or name of zone) where to patrol. -- @param Core.Zone#ZONE FacZone The FAC zone (or name of zone) where to patrol.
-- @param #number Speed Speed in knots. -- @param #number Speed (Optional) Speed in knots.
-- @param #number Altitude Altitude in feet. Only for airborne units. Default 2000 feet ASL. -- @param #number Altitude (Optional) Altitude in feet. Only for airborne units. Default 2000 feet ASL.
-- @param #number Frequency Frequency in MHz. -- @param #number Frequency (Optional) Frequency in MHz. Defaults to 133Mhz.
-- @param #number Modulation Modulation. -- @param #number Modulation (Optional) Modulation. Defaults to radio.modulation.AM
-- @return #AUFTRAG self
function AUFTRAG:NewFAC(FacZone, Speed, Altitude, Frequency, Modulation) function AUFTRAG:NewFAC(FacZone, Speed, Altitude, Frequency, Modulation)
local mission=AUFTRAG:New(AUFTRAG.Type.FAC) local mission=AUFTRAG:New(AUFTRAG.Type.FAC)
@@ -1638,10 +1637,10 @@ end
--- **[AIR]** Create a FACA mission. --- **[AIR]** Create a FACA mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Group#GROUP Target Target group. Must be a GROUP object. -- @param Wrapper.Group#GROUP Target Target group. Must be a GROUP object.
-- @param #string Designation Designation of target. See `AI.Task.Designation`. Default `AI.Task.Designation.AUTO`. -- @param #string Designation (Optional) Designation of target. See `AI.Task.Designation`. Default `AI.Task.Designation.AUTO`.
-- @param #boolean DataLink Enable data link. Default `true`. -- @param #boolean DataLink (Optional) Enable data link. Default `true`.
-- @param #number Frequency Radio frequency in MHz the FAC uses for communication. Default is 133 MHz. -- @param #number Frequency (Optional) Radio frequency in MHz the FAC uses for communication. Default is 133 MHz.
-- @param #number Modulation Radio modulation band. Default 0=AM. Use 1 for FM. See radio.modulation.AM or radio.modulaton.FM. -- @param #number Modulation (Optional) Radio modulation band. Default 0=AM. Use 1 for FM. See radio.modulation.AM or radio.modulaton.FM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewFACA(Target, Designation, DataLink, Frequency, Modulation) function AUFTRAG:NewFACA(Target, Designation, DataLink, Frequency, Modulation)
@@ -1675,7 +1674,7 @@ end
--- **[AIR]** Create a BAI mission. --- **[AIR]** Create a BAI mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP, UNIT or STATIC object. -- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP, UNIT or STATIC object.
-- @param #number Altitude Engage altitude in feet. Default 5000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 5000 ft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewBAI(Target, Altitude) function AUFTRAG:NewBAI(Target, Altitude)
@@ -1705,7 +1704,7 @@ end
--- **[AIR]** Create a SEAD mission. --- **[AIR]** Create a SEAD mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP or UNIT object. -- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP or UNIT object.
-- @param #number Altitude Engage altitude in feet. Default 25000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 25000 ft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewSEAD(Target, Altitude) function AUFTRAG:NewSEAD(Target, Altitude)
@@ -1735,9 +1734,9 @@ end
--- **[AIR]** Create a SEAD in Zone mission. --- **[AIR]** Create a SEAD in Zone mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE TargetZone The target zone to attack. -- @param Core.Zone#ZONE TargetZone The target zone to attack.
-- @param #number Altitude Engage altitude in feet. Default 25000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 25000 ft.
-- @param #table TargetTypes Table of string of DCS known target types, defaults to {"Air Defence"}. See [DCS Target Attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes) -- @param #table TargetTypes (Optional) Table of string of DCS known target types, defaults to {"Air Defence"}. See [DCS Target Attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes)
-- @param #number Duration Engage this much time when the AUFTRAG starts executing. -- @param #number Duration (Optional) Engage this much time when the AUFTRAG starts executing. Default is 1800.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewSEADInZone(TargetZone, Altitude, TargetTypes, Duration) function AUFTRAG:NewSEADInZone(TargetZone, Altitude, TargetTypes, Duration)
@@ -1771,8 +1770,8 @@ end
--- **[AIR]** Create a STRIKE mission. Flight will attack the closest map object to the specified coordinate. --- **[AIR]** Create a STRIKE mission. Flight will attack the closest map object to the specified coordinate.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Target The target coordinate. Can also be given as a GROUP, UNIT, STATIC, SET_GROUP, SET_UNIT, SET_STATIC or TARGET object. -- @param Core.Point#COORDINATE Target The target coordinate. Can also be given as a GROUP, UNIT, STATIC, SET_GROUP, SET_UNIT, SET_STATIC or TARGET object.
-- @param #number Altitude Engage altitude in feet. Default 2000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 2000 ft.
-- @param #number EngageWeaponType Which weapon to use. Defaults to auto, ie ENUMS.WeaponFlag.Auto. See ENUMS.WeaponFlag for options. -- @param #number EngageWeaponType (Optional) Which weapon to use. Defaults to auto, ie ENUMS.WeaponFlag.Auto. See ENUMS.WeaponFlag for options.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewSTRIKE(Target, Altitude, EngageWeaponType) function AUFTRAG:NewSTRIKE(Target, Altitude, EngageWeaponType)
@@ -1803,9 +1802,9 @@ end
-- See [DCS task bombing](https://wiki.hoggitworld.com/view/DCS_task_bombing). -- See [DCS task bombing](https://wiki.hoggitworld.com/view/DCS_task_bombing).
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Target Target coordinate. Can also be specified as a GROUP, UNIT, STATIC, SET_GROUP, SET_UNIT, SET_STATIC or TARGET object. -- @param Core.Point#COORDINATE Target Target coordinate. Can also be specified as a GROUP, UNIT, STATIC, SET_GROUP, SET_UNIT, SET_STATIC or TARGET object.
-- @param #number Altitude Engage altitude in feet. Default 25000 ft. -- @param #number Altitude Engage (Optional) altitude in feet. Default 25000 ft.
-- @param #number EngageWeaponType Which weapon to use. Defaults to auto, ie ENUMS.WeaponFlag.Auto. See ENUMS.WeaponFlag for options. -- @param #number EngageWeaponType (Optional) Which weapon to use. Defaults to auto, ie ENUMS.WeaponFlag.Auto. See ENUMS.WeaponFlag for options.
-- @param #boolean Divebomb If true, use a dive bombing attack approach. -- @param #boolean Divebomb (Optional) If true, use a dive bombing attack approach.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewBOMBING(Target, Altitude, EngageWeaponType, Divebomb) function AUFTRAG:NewBOMBING(Target, Altitude, EngageWeaponType, Divebomb)
@@ -1841,8 +1840,8 @@ end
-- See [DCS task strafing](https://wiki.hoggitworld.com/view/DCS_task_strafing). -- See [DCS task strafing](https://wiki.hoggitworld.com/view/DCS_task_strafing).
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Target Target coordinate. Can also be specified as a GROUP, UNIT, STATIC or TARGET object. -- @param Core.Point#COORDINATE Target Target coordinate. Can also be specified as a GROUP, UNIT, STATIC or TARGET object.
-- @param #number Altitude Engage altitude in feet. Default 1000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 1000 ft.
-- @param #number Length The total length of the strafing target in meters. Default `nil`. -- @param #number Length (Optional) The total length of the strafing target in meters. Default `nil`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewSTRAFING(Target, Altitude, Length) function AUFTRAG:NewSTRAFING(Target, Altitude, Length)
@@ -1878,7 +1877,7 @@ end
--- **[AIR]** Create a BOMBRUNWAY mission. --- **[AIR]** Create a BOMBRUNWAY mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Airbase#AIRBASE Airdrome The airbase to bomb. This must be an airdrome (not a FARP or ship) as these do not have a runway. -- @param Wrapper.Airbase#AIRBASE Airdrome The airbase to bomb. This must be an airdrome (not a FARP or ship) as these do not have a runway.
-- @param #number Altitude Engage altitude in feet. Default 25000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 25000 ft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewBOMBRUNWAY(Airdrome, Altitude) function AUFTRAG:NewBOMBRUNWAY(Airdrome, Altitude)
@@ -1916,8 +1915,8 @@ end
--- **[AIR]** Create a CARPET BOMBING mission. --- **[AIR]** Create a CARPET BOMBING mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Target Target coordinate. Can also be specified as a GROUP, UNIT or STATIC object. -- @param Core.Point#COORDINATE Target Target coordinate. Can also be specified as a GROUP, UNIT or STATIC object.
-- @param #number Altitude Engage altitude in feet. Default 25000 ft. -- @param #number Altitude (Optional) Engage altitude in feet. Default 25000 ft.
-- @param #number CarpetLength Length of bombing carpet in meters. Default 500 m. -- @param #number CarpetLength (Optional) Length of bombing carpet in meters. Default 500 m.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewBOMBCARPET(Target, Altitude, CarpetLength) function AUFTRAG:NewBOMBCARPET(Target, Altitude, CarpetLength)
@@ -1954,8 +1953,8 @@ end
--- **[AIR/HELO]** Create a GROUNDESCORT (or FOLLOW) mission. Helo will escort a **ground** group and automatically engage certain target types. --- **[AIR/HELO]** Create a GROUNDESCORT (or FOLLOW) mission. Helo will escort a **ground** group and automatically engage certain target types.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Group#GROUP EscortGroup The ground group to escort. -- @param Wrapper.Group#GROUP EscortGroup The ground group to escort.
-- @param #number OrbitDistance Orbit to/from the lead unit this many NM. Defaults to 1.5 NM. -- @param #number OrbitDistance(Optional) Orbit to/from the lead unit this many NM. Defaults to 1.5 NM.
-- @param #table TargetTypes Types of targets to engage automatically. Default is {"Ground vehicles"}, i.e. all enemy ground units. Use an empty set {} for a simple "FOLLOW" mission. -- @param #table TargetTypes (Optional) Types of targets to engage automatically. Default is {"Ground vehicles"}, i.e. all enemy ground units. Use an empty set {} for a simple "FOLLOW" mission.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewGROUNDESCORT(EscortGroup, OrbitDistance, TargetTypes) function AUFTRAG:NewGROUNDESCORT(EscortGroup, OrbitDistance, TargetTypes)
@@ -1992,9 +1991,9 @@ end
--- **[AIR]** Create an ESCORT (or FOLLOW) mission. Flight will escort another group and automatically engage certain target types. --- **[AIR]** Create an ESCORT (or FOLLOW) mission. Flight will escort another group and automatically engage certain target types.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Group#GROUP EscortGroup The group to escort. -- @param Wrapper.Group#GROUP EscortGroup The group to escort.
-- @param DCS#Vec3 OffsetVector A table with x, y and z components specifying the offset of the flight to the escorted group. Default {x=-100, y=0, z=200} for z=200 meters to the right, same alitude (y=0), x=-100 meters behind. -- @param DCS#Vec3 OffsetVector (Optional) A table with x, y and z components specifying the offset of the flight to the escorted group. Default {x=-100, y=0, z=200} for z=200 meters to the right, same alitude (y=0), x=-100 meters behind.
-- @param #number EngageMaxDistance Max engage distance of targets in nautical miles. Default auto 32 NM. -- @param #number EngageMaxDistance (Optional) Max engage distance of targets in nautical miles. Default auto 32 NM.
-- @param #table TargetTypes Types of targets to engage automatically. Default is {"Air"}, i.e. all enemy airborne units. Use an empty set {} for a simple "FOLLOW" mission. -- @param #table TargetTypes (Optional) Types of targets to engage automatically. Default is {"Air"}, i.e. all enemy airborne units. Use an empty set {} for a simple "FOLLOW" mission.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewESCORT(EscortGroup, OffsetVector, EngageMaxDistance, TargetTypes) function AUFTRAG:NewESCORT(EscortGroup, OffsetVector, EngageMaxDistance, TargetTypes)
@@ -2053,13 +2052,13 @@ end
--- **[AIRPANE]** Create a RECOVERY TANKER mission. --- **[AIRPANE]** Create a RECOVERY TANKER mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Unit#UNIT Carrier The carrier unit. -- @param Wrapper.Unit#UNIT Carrier The carrier unit.
-- @param #number Altitude Orbit altitude in feet. Default is 6,000 ft. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 6,000 ft.
-- @param #number Speed Orbit speed in knots. Default 250 KIAS. -- @param #number Speed (Optional) Orbit speed in knots. Default 250 KIAS.
-- @param #number Leg Length of race-track in NM. Default 14 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 14 NM.
-- @param #number RelHeading Relative heading [0, 360) of race-track pattern in degrees wrt heading of the carrier. Default is heading of the carrier. -- @param #number RelHeading (Optional) Relative heading [0, 360) of race-track pattern in degrees wrt heading of the carrier. Default is heading of the carrier.
-- @param #number OffsetDist Relative distance of the first race-track point wrt to the carrier. Default 6 NM. -- @param #number OffsetDist (Optional) Relative distance of the first race-track point wrt to the carrier. Default 6 NM.
-- @param #number OffsetAngle Relative angle of the first race-track point wrt. to the carrier. Default 180 (behind the boat). -- @param #number OffsetAngle (Optional) Relative angle of the first race-track point wrt. to the carrier. Default 180 (behind the boat).
-- @param #number UpdateDistance Threshold distance in NM before orbit pattern is updated. Default 5 NM. -- @param #number UpdateDistance (Optional) Threshold distance in NM before orbit pattern is updated. Default 5 NM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewRECOVERYTANKER(Carrier, Altitude, Speed, Leg, RelHeading, OffsetDist, OffsetAngle, UpdateDistance) function AUFTRAG:NewRECOVERYTANKER(Carrier, Altitude, Speed, Leg, RelHeading, OffsetDist, OffsetAngle, UpdateDistance)
@@ -2101,8 +2100,8 @@ end
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Set#SET_GROUP TransportGroupSet The set group(s) to be transported. -- @param Core.Set#SET_GROUP TransportGroupSet The set group(s) to be transported.
-- @param Core.Point#COORDINATE DropoffCoordinate Coordinate where the helo will land drop off the the troops. -- @param Core.Point#COORDINATE DropoffCoordinate Coordinate where the helo will land drop off the the troops.
-- @param Core.Point#COORDINATE PickupCoordinate Coordinate where the helo will land to pick up the the cargo. Default is the first transport group. -- @param Core.Point#COORDINATE PickupCoordinate(Optional) Coordinate where the helo will land to pick up the the cargo. Default is the first transport group.
-- @param #number PickupRadius Radius around the pickup coordinate in meters. Default 100 m. -- @param #number PickupRadius (Optional) Radius around the pickup coordinate in meters. Default 100 m.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewTROOPTRANSPORT(TransportGroupSet, DropoffCoordinate, PickupCoordinate, PickupRadius) function AUFTRAG:NewTROOPTRANSPORT(TransportGroupSet, DropoffCoordinate, PickupCoordinate, PickupRadius)
@@ -2143,6 +2142,7 @@ function AUFTRAG:NewTROOPTRANSPORT(TransportGroupSet, DropoffCoordinate, PickupC
end end
--- **[AIR ROTARY]** Create a CARGO TRANSPORT mission. --- **[AIR ROTARY]** Create a CARGO TRANSPORT mission.
-- This mission is for helicopters only, which transport cargo externally via slingload.
-- **Important Note:** -- **Important Note:**
-- The dropoff zone has to be a zone defined in the Mission Editor. This is due to a restriction in the used DCS task, which takes the zone ID as input. -- The dropoff zone has to be a zone defined in the Mission Editor. This is due to a restriction in the used DCS task, which takes the zone ID as input.
-- Only ME zones have an ID that can be referenced. -- Only ME zones have an ID that can be referenced.
@@ -2190,7 +2190,7 @@ function AUFTRAG:NewFREIGHTTRANSPORT(StaticCargo, Destination)
-- Check if Destination is given -- Check if Destination is given
if Destination==nil then if Destination==nil then
self:E(self.lid..string.format("ERROR: Destination is nil for AUFTRAG:NewFREIGHTTRANSPORT! You must specify the destination airbase")) BASE:E(self.lid..string.format("ERROR: Destination is nil for AUFTRAG:NewFREIGHTTRANSPORT! You must specify the destination airbase"))
return nil return nil
elseif type(Destination)=="string" then elseif type(Destination)=="string" then
Destination=AIRBASE:FindByName(Destination) Destination=AIRBASE:FindByName(Destination)
@@ -2198,7 +2198,7 @@ function AUFTRAG:NewFREIGHTTRANSPORT(StaticCargo, Destination)
-- Check if Cargo is given -- Check if Cargo is given
if StaticCargo==nil then if StaticCargo==nil then
self:E(self.lid..string.format("ERROR: StaticCargo is nil for AUFTRAG:NewFREIGHTTRANSPORT! You must specify the static object that represents the cargo")) BASE:E(self.lid..string.format("ERROR: StaticCargo is nil for AUFTRAG:NewFREIGHTTRANSPORT! You must specify the static object that represents the cargo"))
return nil return nil
elseif type(StaticCargo)=="string" then elseif type(StaticCargo)=="string" then
StaticCargo=STATIC:FindByName(StaticCargo) StaticCargo=STATIC:FindByName(StaticCargo)
@@ -2213,6 +2213,15 @@ function AUFTRAG:NewFREIGHTTRANSPORT(StaticCargo, Destination)
local mission=AUFTRAG:New(AUFTRAG.Type.FREIGHTTRANSPORT) local mission=AUFTRAG:New(AUFTRAG.Type.FREIGHTTRANSPORT)
-- Check that the set is not empty
local Ncargo=StaticCargo:Count()
if Ncargo==0 then
mission:E(mission.lid..string.format("ERROR: No cargo items in set!"))
return nil
else
mission:T(mission.lid..string.format("FREIGHTTRANSPORT with N=%d cargo items in set", Ncargo))
end
mission:_TargetFromObject(StaticCargo) mission:_TargetFromObject(StaticCargo)
mission.missionTask=mission:GetMissionTaskforMissionType(AUFTRAG.Type.FREIGHTTRANSPORT) mission.missionTask=mission:GetMissionTaskforMissionType(AUFTRAG.Type.FREIGHTTRANSPORT)
@@ -2277,9 +2286,9 @@ end
-- **Note** that it is recommended to set the weapon range via the `OPSGROUP:AddWeaponRange()` function as this cannot be retrieved from the DCS API. -- **Note** that it is recommended to set the weapon range via the `OPSGROUP:AddWeaponRange()` function as this cannot be retrieved from the DCS API.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Point#COORDINATE Target Center of the firing solution. -- @param Core.Point#COORDINATE Target Center of the firing solution.
-- @param #number Nshots Number of shots to be fired. Default `#nil`. If value is in (0,1), it is interpreted as per cent of available ammo. -- @param #number Nshots (Optional) Number of shots to be fired. Default `#nil`. If value is in (0,1), it is interpreted as per cent of available ammo.
-- @param #number Radius Radius of the shells in meters. Default 100 meters. -- @param #number Radius (Optional) Radius of the shells in meters. Default 100 meters.
-- @param #number Altitude Altitude in meters. Can be used to setup a Barrage. Default `#nil`. -- @param #number Altitude (Optional) Altitude in meters. Can be used to setup a Barrage. Default `#nil`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewARTY(Target, Nshots, Radius, Altitude) function AUFTRAG:NewARTY(Target, Nshots, Radius, Altitude)
@@ -2312,11 +2321,11 @@ end
--- **[GROUND, NAVAL]** Create an BARRAGE mission. Assigned groups will move to a random coordinate within a given zone and start firing into the air. --- **[GROUND, NAVAL]** Create an BARRAGE mission. Assigned groups will move to a random coordinate within a given zone and start firing into the air.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE Zone The zone where the unit will go. -- @param Core.Zone#ZONE Zone The zone where the unit will go.
-- @param #number Heading Heading in degrees. Default random heading [0, 360). -- @param #number Heading (Optional) Heading in degrees. Default random heading [0, 360).
-- @param #number Angle Shooting angle in degrees. Default random [45, 85]. -- @param #number Angle (Optional) Shooting angle in degrees. Default random [45, 85].
-- @param #number Radius Radius of the shells in meters. Default 100 meters. -- @param #number Radius (Optional) Radius of the shells in meters. Default 100 meters.
-- @param #number Altitude Altitude in meters. Default 500 m. -- @param #number Altitude (Optional) Altitude in meters. Default 500 m.
-- @param #number Nshots Number of shots to be fired. Default is until ammo is empty (`#nil`). -- @param #number Nshots (Optional) Number of shots to be fired. Default is until ammo is empty (`#nil`).
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewBARRAGE(Zone, Heading, Angle, Radius, Altitude, Nshots) function AUFTRAG:NewBARRAGE(Zone, Heading, Angle, Radius, Altitude, Nshots)
@@ -2351,8 +2360,8 @@ end
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE Zone The patrol zone. -- @param Core.Zone#ZONE Zone The patrol zone.
-- @param #number Speed Speed in knots. -- @param #number Speed Speed in knots.
-- @param #number Altitude Altitude in feet. Only for airborne units. Default 2000 feet ASL. -- @param #number Altitude (Optional) Altitude in feet. Only for airborne units. Default 2000 feet ASL.
-- @param #string Formation Formation used by ground units during patrol. Default "Off Road". -- @param #string Formation (Optional) Formation used by ground units during patrol. Default "Off Road".
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewPATROLZONE(Zone, Speed, Altitude, Formation) function AUFTRAG:NewPATROLZONE(Zone, Speed, Altitude, Formation)
@@ -2389,8 +2398,8 @@ end
-- @param Ops.OpsZone#OPSZONE OpsZone The OPS zone to capture. -- @param Ops.OpsZone#OPSZONE OpsZone The OPS zone to capture.
-- @param #number Coalition The coalition which should capture the zone for the mission to be successful. -- @param #number Coalition The coalition which should capture the zone for the mission to be successful.
-- @param #number Speed Speed in knots. -- @param #number Speed Speed in knots.
-- @param #number Altitude Altitude in feet. Only for airborne units. Default 2000 feet ASL. -- @param #number Altitude (Optional) Altitude in feet. Only for airborne units. Default 2000 feet ASL.
-- @param #string Formation Formation used by ground units during patrol. Default "Off Road". -- @param #string Formation (Optional) Formation used by ground units during patrol. Default "Off Road".
-- @param #number StayInZoneTime Stay this many seconds in the zone when done, only then drive back. -- @param #number StayInZoneTime Stay this many seconds in the zone when done, only then drive back.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewCAPTUREZONE(OpsZone, Coalition, Speed, Altitude, Formation, StayInZoneTime) function AUFTRAG:NewCAPTUREZONE(OpsZone, Coalition, Speed, Altitude, Formation, StayInZoneTime)
@@ -2454,8 +2463,8 @@ end
-- Therefore, we resort to this workaround, which guides the attacking group to the vicinity of the target. Then they start shooting on their own, once they detect the target. -- Therefore, we resort to this workaround, which guides the attacking group to the vicinity of the target. Then they start shooting on their own, once they detect the target.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP, UNIT or STATIC object. -- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP, UNIT or STATIC object.
-- @param #number Speed Speed in knots. Default max. -- @param #number Speed (Optional) Speed in knots. Default max.
-- @param #string Formation The attack formation, e.g. "Wedge", "Vee" etc. Default `ENUMS.Formation.Vehicle.Vee`. Only working for ground, not naval! -- @param #string Formation (Optional) The attack formation, e.g. "Wedge", "Vee" etc. Default `ENUMS.Formation.Vehicle.Vee`. Only working for ground, not naval!
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewGROUNDATTACK(Target, Speed, Formation) function AUFTRAG:NewGROUNDATTACK(Target, Speed, Formation)
@@ -2487,8 +2496,8 @@ end
-- Therefore, we resort to this workaround, which guides the attacking group to the vicinity of the target. Then they start shooting on their own, once they detect the target. -- Therefore, we resort to this workaround, which guides the attacking group to the vicinity of the target. Then they start shooting on their own, once they detect the target.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP, UNIT or STATIC object. -- @param Wrapper.Positionable#POSITIONABLE Target The target to attack. Can be a GROUP, UNIT or STATIC object.
-- @param #number Speed Speed in knots. Default max. -- @param #number Speed (Optional) Speed in knots. Default max.
-- @param #number Depth The attack depth in meters. Only for submarines! -- @param #number Depth (Optional) The attack depth in meters. Only for submarines! Defaults to 0.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:NewNAVALENGAGEMENT(Target, Speed, Depth) function AUFTRAG:NewNAVALENGAGEMENT(Target, Speed, Depth)
@@ -2517,8 +2526,8 @@ end
--- **[AIR, GROUND, NAVAL]** Create a RECON mission. --- **[AIR, GROUND, NAVAL]** Create a RECON mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Set#SET_ZONE ZoneSet The recon zones. -- @param Core.Set#SET_ZONE ZoneSet The recon zones.
-- @param #number Speed Speed in knots. -- @param #number Speed (Optional) Speed in knots.
-- @param #number Altitude Altitude in feet. Only for airborne units. Default 2000 feet ASL. -- @param #number Altitude (Optional) Altitude in feet. Only for airborne units. Default 2000 feet ASL.
-- @param #boolean Adinfinitum If `true`, the group will start over again after reaching the final zone. -- @param #boolean Adinfinitum If `true`, the group will start over again after reaching the final zone.
-- @param #boolean Randomly If `true`, the group will select a random zone. -- @param #boolean Randomly If `true`, the group will select a random zone.
-- @param #string Formation Formation used during recon route. -- @param #string Formation Formation used during recon route.
@@ -3010,7 +3019,7 @@ end
--- Set mission start and stop time. --- Set mission start and stop time.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #string ClockStart Time the mission is started, e.g. "05:00" for 5 am. If specified as a #number, it will be relative (in seconds) to the current mission time. Default is 5 seconds after mission was added. -- @param #string ClockStart (Optional) Time the mission is started, e.g. "05:00" for 5 am. If specified as a #number, it will be relative (in seconds) to the current mission time. Default is 5 seconds after mission was added.
-- @param #string ClockStop (Optional) Time the mission is stopped, e.g. "13:00" for 1 pm. If mission could not be started at that time, it will be removed from the queue. If specified as a #number it will be relative (in seconds) to the current mission time. -- @param #string ClockStop (Optional) Time the mission is stopped, e.g. "13:00" for 1 pm. If mission could not be started at that time, it will be removed from the queue. If specified as a #number it will be relative (in seconds) to the current mission time.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetTime(ClockStart, ClockStop) function AUFTRAG:SetTime(ClockStart, ClockStop)
@@ -3096,9 +3105,9 @@ end
--- Set mission priority and (optional) urgency. Urgent missions can cancel other running missions. --- Set mission priority and (optional) urgency. Urgent missions can cancel other running missions.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Prio Priority 1=high, 100=low. Default 50. -- @param #number Prio (Optional) Priority 1=high, 100=low. Default 50.
-- @param #boolean Urgent If *true*, another running mission might be cancelled if it has a lower priority. -- @param #boolean Urgent If *true*, another running mission might be cancelled if it has a lower priority.
-- @param #number Importance Number 1-10. If missions with lower value are in the queue, these have to be finished first. Default is `nil`. -- @param #number Importance (Optional) Number 1-10. If missions with lower value are in the queue, these have to be finished first. Default is `nil`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetPriority(Prio, Urgent, Importance) function AUFTRAG:SetPriority(Prio, Urgent, Importance)
self.prio=Prio or 50 self.prio=Prio or 50
@@ -3109,7 +3118,7 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Set how many times the mission is repeated. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level. --- **[LEGION, COMMANDER, CHIEF]** Set how many times the mission is repeated. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Nrepeat Number of repeats. Default 0. -- @param #number Nrepeat (Optional) Number of repeats. Default 0.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRepeat(Nrepeat) function AUFTRAG:SetRepeat(Nrepeat)
self.Nrepeat=Nrepeat or 0 self.Nrepeat=Nrepeat or 0
@@ -3119,7 +3128,7 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Set the repeat delay in seconds after a mission is successful/failed. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level. --- **[LEGION, COMMANDER, CHIEF]** Set the repeat delay in seconds after a mission is successful/failed. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number RepeatDelay Repeat delay in seconds. Default 1. -- @param #number RepeatDelay (Optional) Repeat delay in seconds. Default 1.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRepeatDelay(RepeatDelay) function AUFTRAG:SetRepeatDelay(RepeatDelay)
self.repeatDelay = RepeatDelay self.repeatDelay = RepeatDelay
@@ -3128,7 +3137,7 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Set how many times the mission is repeated if it fails. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level. --- **[LEGION, COMMANDER, CHIEF]** Set how many times the mission is repeated if it fails. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Nrepeat Number of repeats. Default 0. -- @param #number Nrepeat (Optional) Number of repeats. Default 0.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRepeatOnFailure(Nrepeat) function AUFTRAG:SetRepeatOnFailure(Nrepeat)
self.NrepeatFailure=Nrepeat or 0 self.NrepeatFailure=Nrepeat or 0
@@ -3137,7 +3146,7 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Set how many times the mission is repeated if it was successful. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level. --- **[LEGION, COMMANDER, CHIEF]** Set how many times the mission is repeated if it was successful. Only valid if the mission is handled by a LEGION (AIRWING, BRIGADE, FLEET) or higher level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Nrepeat Number of repeats. Default 0. -- @param #number Nrepeat (Optional) Number of repeats. Default 0.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRepeatOnSuccess(Nrepeat) function AUFTRAG:SetRepeatOnSuccess(Nrepeat)
self.NrepeatSuccess=Nrepeat or 0 self.NrepeatSuccess=Nrepeat or 0
@@ -3158,8 +3167,8 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Define how many assets are required to do the job. Only used if the mission is handled by a **LEGION** (AIRWING, BRIGADE, ...) or higher level. --- **[LEGION, COMMANDER, CHIEF]** Define how many assets are required to do the job. Only used if the mission is handled by a **LEGION** (AIRWING, BRIGADE, ...) or higher level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number NassetsMin Minimum number of asset groups. Default 1. -- @param #number NassetsMin (Optional) Minimum number of asset groups. Default 1.
-- @param #number NassetsMax Maximum Number of asset groups. Default is same as `NassetsMin`. -- @param #number NassetsMax (Optional) Maximum Number of asset groups. Default is same as `NassetsMin`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRequiredAssets(NassetsMin, NassetsMax) function AUFTRAG:SetRequiredAssets(NassetsMin, NassetsMax)
@@ -3226,11 +3235,11 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Define how many assets are required that escort the mission assets. --- **[LEGION, COMMANDER, CHIEF]** Define how many assets are required that escort the mission assets.
-- Only used if the mission is handled by a **LEGION** (AIRWING, BRIGADE, FLEET) or higher level. -- Only used if the mission is handled by a **LEGION** (AIRWING, BRIGADE, FLEET) or higher level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number NescortMin Minimum number of asset groups. Default 1. -- @param #number NescortMin (Optional) Minimum number of asset groups. Default 1.
-- @param #number NescortMax Maximum Number of asset groups. Default is same as `NassetsMin`. -- @param #number NescortMax (Optional) Maximum Number of asset groups. Default is same as `NassetsMin`.
-- @param #string MissionType Mission type assets will be optimized for and payload selected, *e.g.* `AUFTRAG.Type.SEAD`. Default nil. -- @param #string MissionType (Optional) Mission type assets will be optimized for and payload selected, *e.g.* `AUFTRAG.Type.SEAD`. Default nil.
-- @param #table TargetTypes Target Types that will be engaged by the escort group(s). Default `{"Air"}` for aircraft and `{"Ground Units"}` for helos. Set, *e.g.*, `{"Air Defence"}` for SEAD. -- @param #table TargetTypes (Optional) Target Types that will be engaged by the escort group(s). Default `{"Air"}` for aircraft and `{"Ground Units"}` for helos. Set, *e.g.*, `{"Air Defence"}` for SEAD.
-- @param #number EngageRange Max range in nautical miles that the escort group(s) will engage enemies. Default 32 NM (60 km). -- @param #number EngageRange (Optional) Max range in nautical miles that the escort group(s) will engage enemies. Default 32 NM (60 km).
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRequiredEscorts(NescortMin, NescortMax, MissionType, TargetTypes, EngageRange) function AUFTRAG:SetRequiredEscorts(NescortMin, NescortMax, MissionType, TargetTypes, EngageRange)
@@ -3256,7 +3265,7 @@ end
--- Set mission name. --- Set mission name.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #string Name Name of the mission. Default is "Auftrag Nr. X", where X is a running number, which is automatically increased. -- @param #string Name (Optional) Name of the mission. Default is "Auftrag Nr. X", where X is a running number, which is automatically increased.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetName(Name) function AUFTRAG:SetName(Name)
self.name=Name or string.format("Auftrag Nr. %d", self.auftragsnummer) self.name=Name or string.format("Auftrag Nr. %d", self.auftragsnummer)
@@ -3265,7 +3274,7 @@ end
--- Enable markers, which dispay the mission status on the F10 map. --- Enable markers, which dispay the mission status on the F10 map.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Coalition The coaliton side to which the markers are dispayed. Default is to all. -- @param #number Coalition (Optional) The coaliton side to which the markers are dispayed. Default is to all.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetEnableMarkers(Coalition) function AUFTRAG:SetEnableMarkers(Coalition)
self.markerOn=true self.markerOn=true
@@ -3275,7 +3284,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetVerbosity(VerbosityLevel) function AUFTRAG:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -3284,7 +3293,7 @@ end
--- Set weapon type used for the engagement. --- Set weapon type used for the engagement.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number WeaponType Weapon type. Default is `ENUMS.WeaponFlag.Auto`. -- @param #number WeaponType (Optional) Weapon type. Default is `ENUMS.WeaponFlag.Auto`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetWeaponType(WeaponType) function AUFTRAG:SetWeaponType(WeaponType)
@@ -3298,7 +3307,7 @@ end
--- Set number of weapons to expend. --- Set number of weapons to expend.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number WeaponExpend How much of the weapon load is expended during the attack, e.g. `AI.Task.WeaponExpend.ALL`. Default "Auto". -- @param #number WeaponExpend (Optional) How much of the weapon load is expended during the attack, e.g. `AI.Task.WeaponExpend.ALL`. Default "Auto".
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetWeaponExpend(WeaponExpend) function AUFTRAG:SetWeaponExpend(WeaponExpend)
@@ -3330,7 +3339,7 @@ end
--- Set engage altitude. This is the altitude passed to the DCS task. In the ME it is the tickbox ALTITUDE ABOVE. --- Set engage altitude. This is the altitude passed to the DCS task. In the ME it is the tickbox ALTITUDE ABOVE.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #string Altitude Altitude in feet. Default 6000 ft. -- @param #string Altitude (Optional) Altitude in feet. Default 6000 ft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetEngageAltitude(Altitude) function AUFTRAG:SetEngageAltitude(Altitude)
@@ -3344,10 +3353,10 @@ end
--- Enable to automatically engage detected targets. --- Enable to automatically engage detected targets.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number RangeMax Max range in NM. Only detected targets within this radius from the group will be engaged. Default is 25 NM. -- @param #number RangeMax (Optional) Max range in NM. Only detected targets within this radius from the group will be engaged. Default is 25 NM.
-- @param #table TargetTypes Types of target attributes that will be engaged. See [DCS enum attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes). Default "All". -- @param #table TargetTypes (Optional) Types of target attributes that will be engaged. See [DCS enum attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes). Default "All".
-- @param Core.Set#SET_ZONE EngageZoneSet Set of zones in which targets are engaged. Default is anywhere. -- @param Core.Set#SET_ZONE EngageZoneSet (Optional) Set of zones in which targets are engaged. Default is anywhere.
-- @param Core.Set#SET_ZONE NoEngageZoneSet Set of zones in which targets are *not* engaged. Default is nowhere. -- @param Core.Set#SET_ZONE NoEngageZoneSet (Optional) Set of zones in which targets are *not* engaged. Default is nowhere.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetEngageDetected(RangeMax, TargetTypes, EngageZoneSet, NoEngageZoneSet) function AUFTRAG:SetEngageDetected(RangeMax, TargetTypes, EngageZoneSet, NoEngageZoneSet)
@@ -3400,7 +3409,7 @@ end
--- Set max mission range. Only applies if the AUFTRAG is handled by an AIRWING or CHIEF. This is the max allowed distance from the airbase to the target. --- Set max mission range. Only applies if the AUFTRAG is handled by an AIRWING or CHIEF. This is the max allowed distance from the airbase to the target.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Range Max range in NM. Default 100 NM. -- @param #number Range (Optional) Max range in NM. Default 100 NM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetMissionRange(Range) function AUFTRAG:SetMissionRange(Range)
self.engageRange=UTILS.NMToMeters(Range or 100) self.engageRange=UTILS.NMToMeters(Range or 100)
@@ -3426,8 +3435,8 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Attach OPS transport to the mission. Mission assets will be transported before the mission is started at the OPSGROUP level. --- **[LEGION, COMMANDER, CHIEF]** Attach OPS transport to the mission. Mission assets will be transported before the mission is started at the OPSGROUP level.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param Core.Zone#ZONE DeployZone Zone where assets are deployed. -- @param Core.Zone#ZONE DeployZone Zone where assets are deployed.
-- @param #number NcarriersMin Number of carriers *at least* required. Default 1. -- @param #number NcarriersMin (Optional) Number of carriers *at least* required. Default 1.
-- @param #number NcarriersMax Number of carriers *at most* used for transportation. Default is same as `NcarriersMin`. -- @param #number NcarriersMax (Optional) Number of carriers *at most* used for transportation. Default is same as `NcarriersMin`.
-- @param Core.Zone#ZONE DisembarkZone Zone where assets are disembarked to. -- @param Core.Zone#ZONE DisembarkZone Zone where assets are disembarked to.
-- @param #table Categories Group categories. -- @param #table Categories Group categories.
-- @param #table Attributes Generalizes group attributes. -- @param #table Attributes Generalizes group attributes.
@@ -3489,8 +3498,8 @@ end
--- **[LEGION, COMMANDER, CHIEF]** Set number of required carrier groups if an OPSTRANSPORT assignment is required. --- **[LEGION, COMMANDER, CHIEF]** Set number of required carrier groups if an OPSTRANSPORT assignment is required.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number NcarriersMin Number of carriers *at least* required. Default 1. -- @param #number NcarriersMin (Optional) Number of carriers *at least* required. Default 1.
-- @param #number NcarriersMax Number of carriers *at most* used for transportation. Default is same as `NcarriersMin`. -- @param #number NcarriersMax (Optional) Number of carriers *at most* used for transportation. Default is same as `NcarriersMin`.
-- @param #table Categories Group categories. -- @param #table Categories Group categories.
-- @param #table Attributes Group attributes. See `GROUP.Attribute.` -- @param #table Attributes Group attributes. See `GROUP.Attribute.`
-- @param #table Properties DCS attributes. -- @param #table Properties DCS attributes.
@@ -3755,7 +3764,7 @@ end
--- Set radio frequency and modulation for this mission. --- Set radio frequency and modulation for this mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Frequency Frequency in MHz. -- @param #number Frequency Frequency in MHz.
-- @param #number Modulation Radio modulation. Default 0=AM. -- @param #number Modulation (Optional) Radio modulation. Default 0=AM.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetRadio(Frequency, Modulation) function AUFTRAG:SetRadio(Frequency, Modulation)
@@ -3769,9 +3778,9 @@ end
--- Set TACAN beacon channel and Morse code for this mission. --- Set TACAN beacon channel and Morse code for this mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Channel TACAN channel. -- @param #number Channel TACAN channel.
-- @param #string Morse Morse code. Default "XXX". -- @param #string Morse (Optional) Morse code. Default "XXX".
-- @param #string UnitName Name of the unit in the group for which acts as TACAN beacon. Default is the first unit in the group. -- @param #string UnitName (Optional) Name of the unit in the group for which acts as TACAN beacon. Default is the first unit in the group.
-- @param #string Band Tacan channel mode ("X" or "Y"). Default is "X" for ground/naval and "Y" for aircraft. -- @param #string Band (Optional) Tacan channel mode ("X" or "Y"). Default is "X" for ground/naval and "Y" for aircraft.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetTACAN(Channel, Morse, UnitName, Band) function AUFTRAG:SetTACAN(Channel, Morse, UnitName, Band)
@@ -3787,8 +3796,8 @@ end
--- Set ICLS beacon channel and Morse code for this mission. --- Set ICLS beacon channel and Morse code for this mission.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Channel ICLS channel. -- @param #number Channel ICLS channel.
-- @param #string Morse Morse code. Default "XXX". -- @param #string Morse (Optional) Morse code. Default "XXX".
-- @param #string UnitName Name of the unit in the group for which acts as ICLS beacon. Default is the first unit in the group. -- @param #string UnitName (Optional) Name of the unit in the group for which acts as ICLS beacon. Default is the first unit in the group.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetICLS(Channel, Morse, UnitName) function AUFTRAG:SetICLS(Channel, Morse, UnitName)
@@ -3802,7 +3811,7 @@ end
--- Set time interval between mission done and success/failure evaluation. --- Set time interval between mission done and success/failure evaluation.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Teval Time in seconds before the mission result is evaluated. Default depends on mission type. -- @param #number Teval (Optional) Time in seconds before the mission result is evaluated. Default depends on mission type.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetEvaluationTime(Teval) function AUFTRAG:SetEvaluationTime(Teval)
@@ -5710,6 +5719,27 @@ function AUFTRAG:GetTargetLife()
end end
end end
--- Get cargo items as set SET object.
-- This returns the cargo item(s) as set `SET` object for mission types `CARGOTRANSPORT`, `TROOPTRANSPORT` and `FREIGHTTRANSPORT`.
-- @param #AUFTRAG self
-- @return Core.Set#SET_BASE The cargo set.
function AUFTRAG:GetCargoSet()
if self.type==AUFTRAG.Type.CARGOTRANSPORT then
local set=SET_STATIC:New()
set:AddObject(self.DCStask.params.cargo)
return set
elseif self.type==AUFTRAG.Type.TROOPTRANSPORT then
return self.transportGroupSet
elseif self.type==AUFTRAG.Type.FREIGHTTRANSPORT then
return self.DCStask.params.cargo
else
self:E(self.lid.."ERROR: GetCargoSet() is only for transport types!")
return nil
end
end
--- Get target. --- Get target.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @return Ops.Target#TARGET The target object. Could be many things. -- @return Ops.Target#TARGET The target object. Could be many things.
@@ -5979,7 +6009,7 @@ end
--- Set randomization of the mission waypoint coordinate. Each assigned group will get a random ingress coordinate, where the mission is executed. --- Set randomization of the mission waypoint coordinate. Each assigned group will get a random ingress coordinate, where the mission is executed.
-- @param #AUFTRAG self -- @param #AUFTRAG self
-- @param #number Radius Distance in meters. Default `#nil`. -- @param #number Radius (Optional) Distance in meters. Default `#nil`.
-- @return #AUFTRAG self -- @return #AUFTRAG self
function AUFTRAG:SetMissionWaypointRandomization(Radius) function AUFTRAG:SetMissionWaypointRandomization(Radius)
self.missionWaypointRadius=Radius self.missionWaypointRadius=Radius
@@ -7170,7 +7200,7 @@ function AUFTRAG:_GetDCSAttackTask(Target, DCStasks)
elseif target.Type==TARGET.ObjectType.UNIT or target.Type==TARGET.ObjectType.STATIC then elseif target.Type==TARGET.ObjectType.UNIT or target.Type==TARGET.ObjectType.STATIC then
local DCStask=CONTROLLABLE.TaskAttackUnit(nil, target.Object, self.engageAsGroup, self.WeaponExpend, self.engageQuantity, self.engageDirection, self.engageAltitude, self.engageWeaponType) local DCStask=CONTROLLABLE.TaskAttackUnit(nil, target.Object, self.engageAsGroup, self.engageWeaponExpend, self.engageQuantity, self.engageDirection, self.engageAltitude, self.engageWeaponType)
table.insert(DCStasks, DCStask) table.insert(DCStasks, DCStask)
+27 -27
View File
@@ -1410,9 +1410,9 @@ end
--- [User] Set the tactical information option, create 10 radio channels groups can subscribe and get Bogey Dope on a specific frequency automatically. You **need** to set up SRS first before using this! --- [User] Set the tactical information option, create 10 radio channels groups can subscribe and get Bogey Dope on a specific frequency automatically. You **need** to set up SRS first before using this!
-- @param #AWACS self -- @param #AWACS self
-- @param #number BaseFreq Base Frequency to use, defaults to 130. -- @param #number BaseFreq (Optional) Base Frequency to use, defaults to 130.
-- @param #number Increase Increase to use, defaults to 0.5, thus channels created are 130, 130.5, 131 .. etc. -- @param #number Increase (Optional) Increase to use, defaults to 0.5, thus channels created are 130, 130.5, 131 .. etc.
-- @param #number Modulation Modulation to use, defaults to radio.modulation.AM. -- @param #number Modulation (Optional) Modulation to use, defaults to radio.modulation.AM.
-- @param #number Interval Seconds between each update call. -- @param #number Interval Seconds between each update call.
-- @param #number Number Number of Frequencies to create, can be 1..10. -- @param #number Number Number of Frequencies to create, can be 1..10.
-- @return #AWACS self -- @return #AWACS self
@@ -1694,8 +1694,8 @@ end
--- [User] Set TOS Time-on-Station in Hours --- [User] Set TOS Time-on-Station in Hours
-- @param #AWACS self -- @param #AWACS self
-- @param #number AICHours AWACS stays this number of hours on station before shift change, default is 4. -- @param #number AICHours (Optional) AWACS stays this number of hours on station before shift change, default is 4.
-- @param #number CapHours (optional) CAP stays this number of hours on station before shift change, default is 4. -- @param #number CapHours (Optional) CAP stays this number of hours on station before shift change, default is 4.
-- @return #AWACS self -- @return #AWACS self
function AWACS:SetTOS(AICHours,CapHours) function AWACS:SetTOS(AICHours,CapHours)
self:T(self.lid.."SetTOS") self:T(self.lid.."SetTOS")
@@ -1990,7 +1990,7 @@ end
--- [User] Set AWACS Player Guidance - influences missile callout and the "New" label in group callouts. --- [User] Set AWACS Player Guidance - influences missile callout and the "New" label in group callouts.
-- @param #AWACS self -- @param #AWACS self
-- @param #boolean Switch If true (default) it is on, if false, it is off. -- @param #boolean Switch (Optional) If true (default) it is on, if false, it is off.
-- @return #AWACS self -- @return #AWACS self
function AWACS:SetPlayerGuidance(Switch) function AWACS:SetPlayerGuidance(Switch)
if (Switch == nil) or (Switch == true) then if (Switch == nil) or (Switch == true) then
@@ -2010,9 +2010,9 @@ end
--- [User] Set AWACS intercept timeline support distance. --- [User] Set AWACS intercept timeline support distance.
-- @param #AWACS self -- @param #AWACS self
-- @param #number TacDistance Distance for TAC call, default 45nm -- @param #number TacDistance (Optional) Distance for TAC call, default 45nm
-- @param #number MeldDistance Distance for Meld call, default 35nm -- @param #number MeldDistance (Optional) Distance for Meld call, default 35nm
-- @param #number ThreatDistance Distance for Threat call, default 25nm -- @param #number ThreatDistance (Optional) Distance for Threat call, default 25nm
-- @return #AWACS self -- @return #AWACS self
function AWACS:SetInterceptTimeline(TacDistance, MeldDistance, ThreatDistance) function AWACS:SetInterceptTimeline(TacDistance, MeldDistance, ThreatDistance)
self.TacDistance = TacDistance or 45 self.TacDistance = TacDistance or 45
@@ -2119,12 +2119,12 @@ end
--- [User] Set AWACS flight details --- [User] Set AWACS flight details
-- @param #AWACS self -- @param #AWACS self
-- @param #number CallSign Defaults to CALLSIGN.AWACS.Magic -- @param #number CallSign (Optional) Defaults to CALLSIGN.AWACS.Magic
-- @param #number CallSignNo Defaults to 1 -- @param #number CallSignNo (Optional) Defaults to 1
-- @param #number Angels Defaults to 25 (i.e. 25000 ft) -- @param #number Angels (Optional) Defaults to 25 (i.e. 25000 ft)
-- @param #number Speed Defaults to 250kn -- @param #number Speed (Optional) Defaults to 250kn
-- @param #number Heading Defaults to 0 (North) -- @param #number Heading (Optional) Defaults to 0 (North)
-- @param #number Leg Defaults to 25nm -- @param #number Leg (Optional) Defaults to 25nm
-- @return #AWACS self -- @return #AWACS self
function AWACS:SetAwacsDetails(CallSign,CallSignNo,Angels,Speed,Heading,Leg) function AWACS:SetAwacsDetails(CallSign,CallSignNo,Angels,Speed,Heading,Leg)
self:T(self.lid.."SetAwacsDetails") self:T(self.lid.."SetAwacsDetails")
@@ -2176,13 +2176,13 @@ end
--- [User] Set AWACS SRS TTS details - see @{Sound.SRS} for details. `SetSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible. --- [User] Set AWACS SRS TTS details - see @{Sound.SRS} for details. `SetSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible.
-- @param #AWACS self -- @param #AWACS self
-- @param #string PathToSRS Defaults to "C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio" -- @param #string PathToSRS (Optional) Defaults to "C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio"
-- @param #string Gender Defaults to "male" -- @param #string Gender (Optional) Defaults to "male"
-- @param #string Culture Defaults to "en-US" -- @param #string Culture (Optional) Defaults to "en-US"
-- @param #number Port Defaults to 5002 -- @param #number Port (Optional) Defaults to 5002
-- @param #string Voice (Optional) Use a specifc voice with the @{Sound.SRS#SetVoice} function, e.g, `:SetVoice("Microsoft Hedda Desktop")`. -- @param #string Voice (Optional) Use a specifc voice with the @{Sound.SRS#SetVoice} function, e.g, `:SetVoice("Microsoft Hedda Desktop")`.
-- Note that this must be installed on your windows system. Can also be Google voice types, if you are using Google TTS. -- Note that this must be installed on your windows system. Can also be Google voice types, if you are using Google TTS.
-- @param #number Volume Volume - between 0.0 (silent) and 1.0 (loudest) -- @param #number Volume (Optional) Volume - between 0.0 (silent) and 1.0 (loudest) Defaults to 1.0.
-- @param #string PathToGoogleKey (Optional) Path to your google key if you want to use google TTS; if you use a config file for MSRS, hand in nil here. -- @param #string PathToGoogleKey (Optional) Path to your google key if you want to use google TTS; if you use a config file for MSRS, hand in nil here.
-- @param #string AccessKey (Optional) Your Google API access key. This is necessary if DCS-gRPC is used as backend; if you use a config file for MSRS, hand in nil here. -- @param #string AccessKey (Optional) Your Google API access key. This is necessary if DCS-gRPC is used as backend; if you use a config file for MSRS, hand in nil here.
-- @param #string Backend (Optional) Your MSRS Backend if different from your config file settings, e.g. MSRS.Backend.SRSEXE or MSRS.Backend.GRPC -- @param #string Backend (Optional) Your MSRS Backend if different from your config file settings, e.g. MSRS.Backend.SRSEXE or MSRS.Backend.GRPC
@@ -2223,8 +2223,8 @@ end
--- [User] Set AWACS Voice Details for AI CAP Planes - SRS TTS - see @{Sound.SRS} for details --- [User] Set AWACS Voice Details for AI CAP Planes - SRS TTS - see @{Sound.SRS} for details
-- @param #AWACS self -- @param #AWACS self
-- @param #string Gender Defaults to "male" -- @param #string Gender (Optional) Defaults to "male"
-- @param #string Culture Defaults to "en-US" -- @param #string Culture (Optional) Defaults to "en-US"
-- @param #string Voice (Optional) Use a specifc voice with the @{#MSRS.SetVoice} function, e.g, `:SetVoice("Microsoft Hedda Desktop")`. -- @param #string Voice (Optional) Use a specifc voice with the @{#MSRS.SetVoice} function, e.g, `:SetVoice("Microsoft Hedda Desktop")`.
-- Note that this must be installed on your windows system. Can also be Google voice types, if you are using Google TTS. -- Note that this must be installed on your windows system. Can also be Google voice types, if you are using Google TTS.
-- @return #AWACS self -- @return #AWACS self
@@ -2238,10 +2238,10 @@ end
--- [User] Set AI CAP Plane Details --- [User] Set AI CAP Plane Details
-- @param #AWACS self -- @param #AWACS self
-- @param #number Callsign Callsign name of AI CAP, e.g. CALLSIGN.Aircraft.Dodge. Defaults to CALLSIGN.Aircraft.Colt. Note that not all available callsigns work for all plane types. -- @param #number Callsign (Optional) Callsign name of AI CAP, e.g. CALLSIGN.Aircraft.Dodge. Defaults to CALLSIGN.Aircraft.Colt. Note that not all available callsigns work for all plane types.
-- @param #number MaxAICap Maximum number of AI CAP planes on station that AWACS will set up automatically. Default to 4. -- @param #number MaxAICap (Optional) Maximum number of AI CAP planes on station that AWACS will set up automatically. Default to 4.
-- @param #number TOS Time on station, in hours. AI planes might go back to base earlier if they run out of fuel or missiles. -- @param #number TOS (Optional) Time on station, in hours. AI planes might go back to base earlier if they run out of fuel or missiles. Defaults to 4.
-- @param #number Speed Airspeed to be used in knots. Will be adjusted to flight height automatically. Defaults to 270. -- @param #number Speed (Optional) Airspeed to be used in knots. Will be adjusted to flight height automatically. Defaults to 270.
-- @return #AWACS self -- @return #AWACS self
function AWACS:SetAICAPDetails(Callsign,MaxAICap,TOS,Speed) function AWACS:SetAICAPDetails(Callsign,MaxAICap,TOS,Speed)
self:T(self.lid.."SetAICAPDetails") self:T(self.lid.."SetAICAPDetails")
@@ -2257,7 +2257,7 @@ end
-- @param #number EscortNumber Number of fighther plane GROUPs to accompany this AWACS. 0 or nil means no escorts. If you want >1 plane in an escort group, you can either set the respective squadron grouping to the desired number, or use a template for escorts with >1 unit. -- @param #number EscortNumber Number of fighther plane GROUPs to accompany this AWACS. 0 or nil means no escorts. If you want >1 plane in an escort group, you can either set the respective squadron grouping to the desired number, or use a template for escorts with >1 unit.
-- @param #number Formation Formation the escort should take (if more than one plane), e.g. `ENUMS.Formation.FixedWing.FingerFour.Group`. Formation is used on GROUP level, multiple groups of one unit will NOT conform to this formation. -- @param #number Formation Formation the escort should take (if more than one plane), e.g. `ENUMS.Formation.FixedWing.FingerFour.Group`. Formation is used on GROUP level, multiple groups of one unit will NOT conform to this formation.
-- @param #table OffsetVector Offset the escorts should fly behind the AWACS, given as table, distance in meters, e.g. `{x=-500,y=0,z=500}` - 500m behind (negative value) and to the right (negative for left), no vertical separation (positive over, negative under the AWACS flight). For multiple groups, the vectors will be slightly changed to avoid collisions. -- @param #table OffsetVector Offset the escorts should fly behind the AWACS, given as table, distance in meters, e.g. `{x=-500,y=0,z=500}` - 500m behind (negative value) and to the right (negative for left), no vertical separation (positive over, negative under the AWACS flight). For multiple groups, the vectors will be slightly changed to avoid collisions.
-- @param #number EscortEngageMaxDistance Escorts engage air targets max this NM away, defaults to 45NM. -- @param #number EscortEngageMaxDistance (Optional) Escorts engage air targets max this NM away, defaults to 45NM.
-- @return #AWACS self -- @return #AWACS self
function AWACS:SetEscort(EscortNumber,Formation,OffsetVector,EscortEngageMaxDistance) function AWACS:SetEscort(EscortNumber,Formation,OffsetVector,EscortEngageMaxDistance)
self:T(self.lid.."SetEscort") self:T(self.lid.."SetEscort")
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -88,8 +88,8 @@ CTLD_CARGO = {
-- @param #number PerCrateMass Mass in kg -- @param #number PerCrateMass Mass in kg
-- @param #number Stock Number of builds available, nil for unlimited -- @param #number Stock Number of builds available, nil for unlimited
-- @param #string Subcategory Name of subcategory, handy if using > 10 types to load. -- @param #string Subcategory Name of subcategory, handy if using > 10 types to load.
-- @param #boolean DontShowInMenu Show this item in menu or not (default: false == show it). -- @param #boolean DontShowInMenu (Optional) Show this item in menu or not (default: false == show it).
-- @param Core.Zone#ZONE Location (optional) Where the cargo is available (one location only). -- @param Core.Zone#ZONE Location (Optional) Where the cargo is available (one location only).
-- @return #CTLD_CARGO self -- @return #CTLD_CARGO self
function CTLD_CARGO:New(ID, Name, Templates, Sorte, HasBeenMoved, LoadDirectly, CratesNeeded, Positionable, Dropped, PerCrateMass, Stock, Subcategory, DontShowInMenu, Location) function CTLD_CARGO:New(ID, Name, Templates, Sorte, HasBeenMoved, LoadDirectly, CratesNeeded, Positionable, Dropped, PerCrateMass, Stock, Subcategory, DontShowInMenu, Location)
-- Inherit everything from BASE class. -- Inherit everything from BASE class.
+38 -38
View File
@@ -362,8 +362,8 @@ CHIEF.version="0.7.1"
--- Create a new CHIEF object and start the FSM. --- Create a new CHIEF object and start the FSM.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #number Coalition Coalition side, e.g. `coaliton.side.BLUE`. Can also be passed as a string "red", "blue" or "neutral". -- @param #number Coalition Coalition side, e.g. `coaliton.side.BLUE`. Can also be passed as a string "red", "blue" or "neutral".
-- @param Core.Set#SET_GROUP AgentSet Set of agents (groups) providing intel. Default is an empty set. -- @param Core.Set#SET_GROUP AgentSet (Optional) Set of agents (groups) providing intel. Default is an empty set.
-- @param #string Alias An *optional* alias how this object is called in the logs etc. -- @param #string Alias (Optional) An *optional* alias how this object is called in the logs etc.
-- @return #CHIEF self -- @return #CHIEF self
function CHIEF:New(Coalition, AgentSet, Alias) function CHIEF:New(Coalition, AgentSet, Alias)
@@ -741,8 +741,8 @@ end
--- Set a threat level range that will be engaged. Threat level is a number between 0 and 10, where 10 is a very dangerous threat. --- Set a threat level range that will be engaged. Threat level is a number between 0 and 10, where 10 is a very dangerous threat.
-- Targets with threat level 0 are usually harmless. -- Targets with threat level 0 are usually harmless.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #number ThreatLevelMin Min threat level. Default 1. -- @param #number ThreatLevelMin (Optional) Min threat level. Default 1.
-- @param #number ThreatLevelMax Max threat level. Default 10. -- @param #number ThreatLevelMax (Optional) Max threat level. Default 10.
-- @return #CHIEF self -- @return #CHIEF self
function CHIEF:SetThreatLevelRange(ThreatLevelMin, ThreatLevelMax) function CHIEF:SetThreatLevelRange(ThreatLevelMin, ThreatLevelMax)
@@ -784,10 +784,10 @@ end
--- Create a new resource list of required assets. --- Create a new resource list of required assets.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #string MissionType The mission type. -- @param #string MissionType The mission type.
-- @param #number Nmin Min number of required assets. Default 1. -- @param #number Nmin (Optional) Min number of required assets. Default 1.
-- @param #number Nmax Max number of requried assets. Default 1. -- @param #number Nmax (Optional) Max number of requried assets. Default 1.
-- @param #table Attributes Generalized attribute(s). Default `nil`. -- @param #table Attributes (Optional) Generalized attribute(s). Default `nil`.
-- @param #table Properties DCS attribute(s). Default `nil`. -- @param #table Properties (Optional) DCS attribute(s). Default `nil`.
-- @param #table Categories Group categories. -- @param #table Categories Group categories.
-- @return #CHIEF.Resources The newly created resource list table. -- @return #CHIEF.Resources The newly created resource list table.
-- @return #CHIEF.Resource The resource object that was added. -- @return #CHIEF.Resource The resource object that was added.
@@ -804,8 +804,8 @@ end
-- @param #CHIEF self -- @param #CHIEF self
-- @param #CHIEF.Resources Resource List of resources. -- @param #CHIEF.Resources Resource List of resources.
-- @param #string MissionType Mission Type. -- @param #string MissionType Mission Type.
-- @param #number Nmin Min number of required assets. Default 1. -- @param #number Nmin (Optional) Min number of required assets. Default 1.
-- @param #number Nmax Max number of requried assets. Default equal `Nmin`. -- @param #number Nmax (Optional) Max number of requried assets. Default equal `Nmin`.
-- @param #table Attributes Generalized attribute(s). -- @param #table Attributes Generalized attribute(s).
-- @param #table Properties DCS attribute(s). Default `nil`. -- @param #table Properties DCS attribute(s). Default `nil`.
-- @param #table Categories Group categories. -- @param #table Categories Group categories.
@@ -847,8 +847,8 @@ end
--- Define which assets will be transported and define the number and attributes/properties of the cargo carrier assets. --- Define which assets will be transported and define the number and attributes/properties of the cargo carrier assets.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #CHIEF.Resource Resource Resource table. -- @param #CHIEF.Resource Resource Resource table.
-- @param #number Nmin Min number of required assets. Default 1. -- @param #number Nmin (Optional) Min number of required assets. Default 1.
-- @param #number Nmax Max number of requried assets. Default is equal to `Nmin`. -- @param #number Nmax (Optional) Max number of requried assets. Default is equal to `Nmin`.
-- @param #table CarrierAttributes Generalized attribute(s) of the carrier assets. -- @param #table CarrierAttributes Generalized attribute(s) of the carrier assets.
-- @param #table CarrierProperties DCS attribute(s) of the carrier assets. -- @param #table CarrierProperties DCS attribute(s) of the carrier assets.
-- @param #table CarrierCategories Group categories of the carrier assets. -- @param #table CarrierCategories Group categories of the carrier assets.
@@ -886,12 +886,12 @@ end
--- Set number of assets requested for detected targets. --- Set number of assets requested for detected targets.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #number NassetsMin Min number of assets. Should be at least 1. Default 1. -- @param #number NassetsMin (Optional) Min number of assets. Should be at least 1. Default 1.
-- @param #number NassetsMax Max number of assets. Default is same as `NassetsMin`. -- @param #number NassetsMax (Optional) Max number of assets. Default is same as `NassetsMin`.
-- @param #number ThreatLevel Only apply this setting if the target threat level is greater or equal this number. Default 0. -- @param #number ThreatLevel (Optional) Only apply this setting if the target threat level is greater or equal this number. Default 0.
-- @param #string TargetCategory Only apply this setting if the target is of this category, e.g. `TARGET.Category.AIRCRAFT`. -- @param #string TargetCategory Only apply this setting if the target is of this category, e.g. `TARGET.Category.AIRCRAFT`.
-- @param #string MissionType Only apply this setting for this mission type, e.g. `AUFTRAG.Type.INTERCEPT`. -- @param #string MissionType Only apply this setting for this mission type, e.g. `AUFTRAG.Type.INTERCEPT`.
-- @param #string Nunits Only apply this setting if the number of enemy units is greater or equal this number. -- @param #string Nunits (Optional) Only apply this setting if the number of enemy units is greater or equal this number. Defaults to 1.
-- @param #string Defcon Only apply this setting if this defense condition is in place. -- @param #string Defcon Only apply this setting if this defense condition is in place.
-- @param #string Strategy Only apply this setting if this strategy is in currently. place. -- @param #string Strategy Only apply this setting if this strategy is in currently. place.
-- @return #CHIEF self -- @return #CHIEF self
@@ -1040,8 +1040,8 @@ end
--- Set limit for number of total or specific missions to be executed simultaniously. --- Set limit for number of total or specific missions to be executed simultaniously.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #number Limit Number of max. mission of this type. Default 10. -- @param #number Limit (Optional) Number of max. mission of this type. Default 10.
-- @param #string MissionType Type of mission, e.g. `AUFTRAG.Type.BAI`. Default `"Total"` for total number of missions. -- @param #string MissionType (Optional) Type of mission, e.g. `AUFTRAG.Type.BAI`. Default `"Total"` for total number of missions.
-- @return #CHIEF self -- @return #CHIEF self
function CHIEF:SetLimitMission(Limit, MissionType) function CHIEF:SetLimitMission(Limit, MissionType)
self.commander:SetLimitMission(Limit, MissionType) self.commander:SetLimitMission(Limit, MissionType)
@@ -1067,7 +1067,7 @@ end
--- Set strategy. --- Set strategy.
-- @param #CHIEF self -- @param #CHIEF self
-- @param #string Strategy Strategy. See @{#CHIEF.strategy}, e.g. `CHIEF.Strategy.DEFENSIVE` (default). -- @param #string Strategy (Optional) Strategy. See @{#CHIEF.strategy}, e.g. `CHIEF.Strategy.DEFENSIVE` (default).
-- @return #CHIEF self -- @return #CHIEF self
function CHIEF:SetStrategy(Strategy) function CHIEF:SetStrategy(Strategy)
@@ -1297,8 +1297,8 @@ end
-- --
-- @param #CHIEF self -- @param #CHIEF self
-- @param Ops.OpsZone#OPSZONE OpsZone OPS zone object. -- @param Ops.OpsZone#OPSZONE OpsZone OPS zone object.
-- @param #number Priority Priority. Default 50. -- @param #number Priority (Optional) Priority. Default 50.
-- @param #number Importance Importance. Default `#nil`. -- @param #number Importance (Optional) Importance. Default `#nil`.
-- @param #CHIEF.Resources ResourceOccupied (Optional) Resources used then zone is occupied by the enemy. -- @param #CHIEF.Resources ResourceOccupied (Optional) Resources used then zone is occupied by the enemy.
-- @param #CHIEF.Resources ResourceEmpty (Optional) Resources used then zone is empty. -- @param #CHIEF.Resources ResourceEmpty (Optional) Resources used then zone is empty.
-- @return #CHIEF.StrategicZone The strategic zone. -- @return #CHIEF.StrategicZone The strategic zone.
@@ -1395,7 +1395,7 @@ end
--- Remove strategically important zone. All runing missions are cancelled. --- Remove strategically important zone. All runing missions are cancelled.
-- @param #CHIEF self -- @param #CHIEF self
-- @param Ops.OpsZone#OPSZONE OpsZone OPS zone object. -- @param Ops.OpsZone#OPSZONE OpsZone OPS zone object.
-- @param #number Delay Delay in seconds before the zone is removed. Default immidiately. -- @param #number Delay (Optional) Delay in seconds before the zone is removed. Default immidiately.
-- @return #CHIEF self -- @return #CHIEF self
function CHIEF:RemoveStrategicZone(OpsZone, Delay) function CHIEF:RemoveStrategicZone(OpsZone, Delay)
@@ -1469,10 +1469,10 @@ end
--- Add a CAP zone. Flights will engage detected targets inside this zone. --- Add a CAP zone. Flights will engage detected targets inside this zone.
-- @param #CHIEF self -- @param #CHIEF self
-- @param Core.Zone#ZONE Zone CAP Zone. Has to be a circular zone. -- @param Core.Zone#ZONE Zone CAP Zone. Has to be a circular zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading(Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data. -- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data.
function CHIEF:AddCapZone(Zone, Altitude, Speed, Heading, Leg) function CHIEF:AddCapZone(Zone, Altitude, Speed, Heading, Leg)
@@ -1485,10 +1485,10 @@ end
--- Add a GCI CAP. --- Add a GCI CAP.
-- @param #CHIEF self -- @param #CHIEF self
-- @param Core.Zone#ZONE Zone Zone, where the flight orbits. -- @param Core.Zone#ZONE Zone Zone, where the flight orbits.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data. -- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data.
function CHIEF:AddGciCapZone(Zone, Altitude, Speed, Heading, Leg) function CHIEF:AddGciCapZone(Zone, Altitude, Speed, Heading, Leg)
@@ -1512,10 +1512,10 @@ end
--- Add an AWACS zone. --- Add an AWACS zone.
-- @param #CHIEF self -- @param #CHIEF self
-- @param Core.Zone#ZONE Zone Zone. -- @param Core.Zone#ZONE Zone Zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @return Ops.Airwing#AIRWING.PatrolZone The AWACS zone data. -- @return Ops.Airwing#AIRWING.PatrolZone The AWACS zone data.
function CHIEF:AddAwacsZone(Zone, Altitude, Speed, Heading, Leg) function CHIEF:AddAwacsZone(Zone, Altitude, Speed, Heading, Leg)
@@ -1539,10 +1539,10 @@ end
--- Add a refuelling tanker zone. --- Add a refuelling tanker zone.
-- @param #CHIEF self -- @param #CHIEF self
-- @param Core.Zone#ZONE Zone Zone. -- @param Core.Zone#ZONE Zone Zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @param #number RefuelSystem Refuelling system. -- @param #number RefuelSystem Refuelling system.
-- @return Ops.Airwing#AIRWING.TankerZone The tanker zone data. -- @return Ops.Airwing#AIRWING.TankerZone The tanker zone data.
function CHIEF:AddTankerZone(Zone, Altitude, Speed, Heading, Leg, RefuelSystem) function CHIEF:AddTankerZone(Zone, Altitude, Speed, Heading, Leg, RefuelSystem)
+15 -15
View File
@@ -109,8 +109,8 @@ _COHORTNAMES={}
--- Create a new COHORT object and start the FSM. --- Create a new COHORT object and start the FSM.
-- @param #COHORT self -- @param #COHORT self
-- @param #string TemplateGroupName Name of the template group. -- @param #string TemplateGroupName Name of the template group.
-- @param #number Ngroups Number of asset groups of this Cohort. Default 3. -- @param #number Ngroups (Optional) Number of asset groups of this Cohort. Default 3.
-- @param #string CohortName Name of the cohort. -- @param #string CohortName (Optional) Name of the cohort. Defaults to TemplateGroupName.
-- @return #COHORT self -- @return #COHORT self
function COHORT:New(TemplateGroupName, Ngroups, CohortName) function COHORT:New(TemplateGroupName, Ngroups, CohortName)
@@ -357,7 +357,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #COHORT self -- @param #COHORT self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #COHORT self -- @return #COHORT self
function COHORT:SetVerbosity(VerbosityLevel) function COHORT:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -366,8 +366,8 @@ end
--- Set turnover and repair time. If an asset returns from a mission, it will need some time until the asset is available for further missions. --- Set turnover and repair time. If an asset returns from a mission, it will need some time until the asset is available for further missions.
-- @param #COHORT self -- @param #COHORT self
-- @param #number MaintenanceTime Time in minutes it takes until a flight is combat ready again. Default is 0 min. -- @param #number MaintenanceTime (Optional) Time in minutes it takes until a flight is combat ready again. Default is 0 min.
-- @param #number RepairTime Time in minutes it takes to repair a flight for each life point taken. Default is 0 min. -- @param #number RepairTime (Optional) Time in minutes it takes to repair a flight for each life point taken. Default is 0 min.
-- @return #COHORT self -- @return #COHORT self
function COHORT:SetTurnoverTime(MaintenanceTime, RepairTime) function COHORT:SetTurnoverTime(MaintenanceTime, RepairTime)
self.maintenancetime=MaintenanceTime and MaintenanceTime*60 or 0 self.maintenancetime=MaintenanceTime and MaintenanceTime*60 or 0
@@ -377,8 +377,8 @@ end
--- Set radio frequency and modulation the cohort uses. --- Set radio frequency and modulation the cohort uses.
-- @param #COHORT self -- @param #COHORT self
-- @param #number Frequency Radio frequency in MHz. Default 251 MHz. -- @param #number Frequency (Optional) Radio frequency in MHz. Default 251 MHz.
-- @param #number Modulation Radio modulation. Default 0=AM. -- @param #number Modulation (Optional) Radio modulation. Default 0=AM.
-- @return #COHORT self -- @return #COHORT self
function COHORT:SetRadio(Frequency, Modulation) function COHORT:SetRadio(Frequency, Modulation)
self.radioFreq=Frequency or 251 self.radioFreq=Frequency or 251
@@ -388,7 +388,7 @@ end
--- Set number of units in groups. --- Set number of units in groups.
-- @param #COHORT self -- @param #COHORT self
-- @param #number nunits Number of units. Default 2. -- @param #number nunits (Optional) Number of units. Default 2.
-- @return #COHORT self -- @return #COHORT self
function COHORT:SetGrouping(nunits) function COHORT:SetGrouping(nunits)
self.ngrouping=nunits or 2 self.ngrouping=nunits or 2
@@ -398,7 +398,7 @@ end
--- Set mission types this cohort is able to perform. --- Set mission types this cohort is able to perform.
-- @param #COHORT self -- @param #COHORT self
-- @param #table MissionTypes Table of mission types. Can also be passed as a #string if only one type. -- @param #table MissionTypes Table of mission types. Can also be passed as a #string if only one type.
-- @param #number Performance Performance describing how good this mission can be performed. Higher is better. Default 50. Max 100. -- @param #number Performance (Optional) Performance describing how good this mission can be performed. Higher is better. Default 50. Max 100.
-- @return #COHORT self -- @return #COHORT self
function COHORT:AddMissionCapability(MissionTypes, Performance) function COHORT:AddMissionCapability(MissionTypes, Performance)
@@ -505,7 +505,7 @@ end
--- Set max mission range. Only missions in a circle of this radius around the cohort base are executed. --- Set max mission range. Only missions in a circle of this radius around the cohort base are executed.
-- @param #COHORT self -- @param #COHORT self
-- @param #number Range Range in NM. Default 150 NM. -- @param #number Range (Optional) Range in NM. Default 150 NM.
-- @return #COHORT self -- @return #COHORT self
function COHORT:SetMissionRange(Range) function COHORT:SetMissionRange(Range)
self.engageRange=UTILS.NMToMeters(Range or 150) self.engageRange=UTILS.NMToMeters(Range or 150)
@@ -628,8 +628,8 @@ end
--- Remove assets from pool. Not that assets must not be spawned or already reserved or requested. --- Remove assets from pool. Not that assets must not be spawned or already reserved or requested.
-- @param #COHORT self -- @param #COHORT self
-- @param #number N Number of assets to be removed. Default 1. -- @param #number N (Optional) Number of assets to be removed. Default 1.
-- @param #number Delay Delay in seconds before assets are removed. -- @param #number Delay (Optional) Delay in seconds before assets are removed. Defaults to 0.
-- @return #COHORT self -- @return #COHORT self
function COHORT:RemoveAssets(N, Delay) function COHORT:RemoveAssets(N, Delay)
self:T2(self.lid..string.format("Remove %d assets of Cohort", N)) self:T2(self.lid..string.format("Remove %d assets of Cohort", N))
@@ -818,9 +818,9 @@ end
--- Add a weapon range for ARTY missions (@{Ops.Auftrag#AUFTRAG}). --- Add a weapon range for ARTY missions (@{Ops.Auftrag#AUFTRAG}).
-- @param #COHORT self -- @param #COHORT self
-- @param #number RangeMin Minimum range in nautical miles. Default 0 NM. -- @param #number RangeMin (Optional) Minimum range in nautical miles. Default 0 NM.
-- @param #number RangeMax Maximum range in nautical miles. Default 10 NM. -- @param #number RangeMax (Optional) Maximum range in nautical miles. Default 10 NM.
-- @param #number BitType Bit mask of weapon type for which the given min/max ranges apply. Default is `ENUMS.WeaponFlag.Auto`, i.e. for all weapon types. -- @param #number BitType (Optional) Bit mask of weapon type for which the given min/max ranges apply. Default is `ENUMS.WeaponFlag.Auto`, i.e. for all weapon types.
-- @return #COHORT self -- @return #COHORT self
function COHORT:AddWeaponRange(RangeMin, RangeMax, BitType) function COHORT:AddWeaponRange(RangeMin, RangeMax, BitType)
+24 -24
View File
@@ -389,7 +389,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #COMMANDER self -- @return #COMMANDER self
function COMMANDER:SetVerbosity(VerbosityLevel) function COMMANDER:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -398,8 +398,8 @@ end
--- Set limit for number of total or specific missions to be executed simultaniously. --- Set limit for number of total or specific missions to be executed simultaniously.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param #number Limit Number of max. mission of this type. Default 10. -- @param #number Limit (Optional) Number of max. mission of this type. Default 10.
-- @param #string MissionType Type of mission, e.g. `AUFTRAG.Type.BAI`. Default `"Total"` for total number of missions. -- @param #string MissionType (Optional) Type of mission, e.g. `AUFTRAG.Type.BAI`. Default `"Total"` for total number of missions.
-- @return #COMMANDER self -- @return #COMMANDER self
function COMMANDER:SetLimitMission(Limit, MissionType) function COMMANDER:SetLimitMission(Limit, MissionType)
MissionType=MissionType or "Total" MissionType=MissionType or "Total"
@@ -664,10 +664,10 @@ end
--- Add a CAP zone. --- Add a CAP zone.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param Core.Zone#ZONE Zone CapZone Zone. -- @param Core.Zone#ZONE Zone CapZone Zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data. -- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data.
function COMMANDER:AddCapZone(Zone, Altitude, Speed, Heading, Leg) function COMMANDER:AddCapZone(Zone, Altitude, Speed, Heading, Leg)
@@ -690,10 +690,10 @@ end
--- Add a GCICAP zone. --- Add a GCICAP zone.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param Core.Zone#ZONE Zone CapZone Zone. -- @param Core.Zone#ZONE Zone CapZone Zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data. -- @return Ops.Airwing#AIRWING.PatrolZone The CAP zone data.
function COMMANDER:AddGciCapZone(Zone, Altitude, Speed, Heading, Leg) function COMMANDER:AddGciCapZone(Zone, Altitude, Speed, Heading, Leg)
@@ -736,10 +736,10 @@ end
--- Add an AWACS zone. --- Add an AWACS zone.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param Core.Zone#ZONE Zone Zone. -- @param Core.Zone#ZONE Zone Zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @return Ops.Airwing#AIRWING.PatrolZone The AWACS zone data. -- @return Ops.Airwing#AIRWING.PatrolZone The AWACS zone data.
function COMMANDER:AddAwacsZone(Zone, Altitude, Speed, Heading, Leg) function COMMANDER:AddAwacsZone(Zone, Altitude, Speed, Heading, Leg)
@@ -783,10 +783,10 @@ end
--- Add a refuelling tanker zone. --- Add a refuelling tanker zone.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param Core.Zone#ZONE Zone Zone. -- @param Core.Zone#ZONE Zone Zone.
-- @param #number Altitude Orbit altitude in feet. Default is 12,000 feet. -- @param #number Altitude (Optional) Orbit altitude in feet. Default is 12,000 feet.
-- @param #number Speed Orbit speed in KIAS. Default 350 kts. -- @param #number Speed (Optional) Orbit speed in KIAS. Default 350 kts.
-- @param #number Heading Heading of race-track pattern in degrees. Default 270 (East to West). -- @param #number Heading (Optional) Heading of race-track pattern in degrees. Default 270 (East to West).
-- @param #number Leg Length of race-track in NM. Default 30 NM. -- @param #number Leg (Optional) Length of race-track in NM. Default 30 NM.
-- @param #number RefuelSystem Refuelling system. -- @param #number RefuelSystem Refuelling system.
-- @return Ops.Airwing#AIRWING.TankerZone The tanker zone data. -- @return Ops.Airwing#AIRWING.TankerZone The tanker zone data.
function COMMANDER:AddTankerZone(Zone, Altitude, Speed, Heading, Leg, RefuelSystem) function COMMANDER:AddTankerZone(Zone, Altitude, Speed, Heading, Leg, RefuelSystem)
@@ -851,10 +851,10 @@ end
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param Ops.Cohort#COHORT Cohort The cohort to be relocated. -- @param Ops.Cohort#COHORT Cohort The cohort to be relocated.
-- @param Ops.Legion#LEGION Legion The legion where the cohort is relocated to. -- @param Ops.Legion#LEGION Legion The legion where the cohort is relocated to.
-- @param #number Delay Delay in seconds before relocation takes place. Default `nil`, *i.e.* ASAP. -- @param #number Delay (Optional) Delay in seconds before relocation takes place. Default `nil`, *i.e.* ASAP.
-- @param #number NcarriersMin Min number of transport carriers in case the troops should be transported. Default `nil` for no transport. -- @param #number NcarriersMin (Optional) Min number of transport carriers in case the troops should be transported. Default `nil` for no transport.
-- @param #number NcarriersMax Max number of transport carriers. -- @param #number NcarriersMax Max number of transport carriers.
-- @param #table TransportLegions Legion(s) assigned for transportation. Default is all legions of the commander. -- @param #table TransportLegions (Optional) Legion(s) assigned for transportation. Default is all legions of the commander.
-- @return #COMMANDER self -- @return #COMMANDER self
function COMMANDER:RelocateCohort(Cohort, Legion, Delay, NcarriersMin, NcarriersMax, TransportLegions) function COMMANDER:RelocateCohort(Cohort, Legion, Delay, NcarriersMin, NcarriersMax, TransportLegions)
@@ -1620,7 +1620,7 @@ end
--- Set how many missions can be assigned in a single status iteration. (eg. This is useful for persistent missions where you need to load all AUFTRAGs on mission start and then change it back to default) --- Set how many missions can be assigned in a single status iteration. (eg. This is useful for persistent missions where you need to load all AUFTRAGs on mission start and then change it back to default)
--- Warning: Increasing this value will increase the number of missions started per iteration and thus may lead to performance issues if too many missions are started at once. --- Warning: Increasing this value will increase the number of missions started per iteration and thus may lead to performance issues if too many missions are started at once.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param #number Number of missions assigned per status iteration. Default is 1. -- @param #number MaxMissionsAssignPerCycle (Optional) Number of missions assigned per status iteration. Default is 1.
-- @return #COMMANDER self. -- @return #COMMANDER self.
function COMMANDER:SetMaxMissionsAssignPerCycle(MaxMissionsAssignPerCycle) function COMMANDER:SetMaxMissionsAssignPerCycle(MaxMissionsAssignPerCycle)
self.maxMissionsAssignPerCycle = MaxMissionsAssignPerCycle or 1 self.maxMissionsAssignPerCycle = MaxMissionsAssignPerCycle or 1
@@ -2229,7 +2229,7 @@ end
--- Get assets on given mission or missions. --- Get assets on given mission or missions.
-- @param #COMMANDER self -- @param #COMMANDER self
-- @param #table MissionTypes Types on mission to be checked. Default all. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default all.
-- @return #table Assets on pending requests. -- @return #table Assets on pending requests.
function COMMANDER:GetAssetsOnMission(MissionTypes) function COMMANDER:GetAssetsOnMission(MissionTypes)
+12 -12
View File
@@ -408,7 +408,7 @@ end
--- Set Tanker and Scouts to be invisible to enemy AI eyes --- Set Tanker and Scouts to be invisible to enemy AI eyes
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #boolean Switch Set to true or false, by default this is set to true already -- @param #boolean Switch (Optional) Set to true or false, by default this is set to true already
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetTankerAndScoutsInvisible(Switch) function EASYA2G:SetTankerAndScoutsInvisible(Switch)
self:T(self.lid.."SetTankerAndScoutsInvisible") self:T(self.lid.."SetTankerAndScoutsInvisible")
@@ -418,7 +418,7 @@ end
--- Set default A2G Speed in knots --- Set default A2G Speed in knots
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #number Speed Speed defaults to 300 -- @param #number Speed (Optional) Speed defaults to 300
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetDefaultA2GSpeed(Speed) function EASYA2G:SetDefaultA2GSpeed(Speed)
self:T(self.lid.."SetDefaultSpeed") self:T(self.lid.."SetDefaultSpeed")
@@ -428,7 +428,7 @@ end
--- Set A2G Flight formation. --- Set A2G Flight formation.
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #number Formation Formation to fly, defaults to ENUMS.Formation.FixedWing.FingerFour.Group -- @param #number Formation (Optional) Formation to fly, defaults to ENUMS.Formation.FixedWing.FingerFour.Group
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetA2GFormation(Formation) function EASYA2G:SetA2GFormation(Formation)
self:T(self.lid.."SetA2GFormation") self:T(self.lid.."SetA2GFormation")
@@ -438,7 +438,7 @@ end
--- Set default A2G Altitude in feet --- Set default A2G Altitude in feet
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #number Altitude Altitude defaults to 25000 -- @param #number Altitude (Optional) Altitude defaults to 25000
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetDefaultA2GAlt(Altitude) function EASYA2G:SetDefaultA2GAlt(Altitude)
self:T(self.lid.."SetDefaultAltitude") self:T(self.lid.."SetDefaultAltitude")
@@ -448,7 +448,7 @@ end
--- Set default A2G lieg initial direction in degrees --- Set default A2G lieg initial direction in degrees
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #number Direction Direction defaults to 90 (East) -- @param #number Direction (Optional) Direction defaults to 90 (East)
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetDefaultA2GDirection(Direction) function EASYA2G:SetDefaultA2GDirection(Direction)
self:T(self.lid.."SetDefaultDirection") self:T(self.lid.."SetDefaultDirection")
@@ -458,7 +458,7 @@ end
--- Set default leg length in NM --- Set default leg length in NM
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #number Leg Leg defaults to 5 -- @param #number Leg (Optional) Leg defaults to 5
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetDefaultA2GLeg(Leg) function EASYA2G:SetDefaultA2GLeg(Leg)
self:T(self.lid.."SetDefaultLeg") self:T(self.lid.."SetDefaultLeg")
@@ -468,7 +468,7 @@ end
--- Set default grouping, i.e. how many airplanes per A2G point --- Set default grouping, i.e. how many airplanes per A2G point
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #number Grouping Grouping defaults to 2 -- @param #number Grouping (Optional) Grouping defaults to 2
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetDefaultA2GGrouping(Grouping) function EASYA2G:SetDefaultA2GGrouping(Grouping)
self:T(self.lid.."SetDefaultA2GGrouping") self:T(self.lid.."SetDefaultA2GGrouping")
@@ -489,7 +489,7 @@ end
--- Set which target types A2G flights will prefer to engage, defaults to {"Ground"} --- Set which target types A2G flights will prefer to engage, defaults to {"Ground"}
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #table types Table of comma separated #string entries, defaults to {"Ground"} (everything that is ground and is not a weapon). Useful other options are e.g. {"Armored vehicles"}, {"Tanks"}, -- @param #table types (Optional) Table of comma separated #string entries, defaults to {"Ground"} (everything that is ground and is not a weapon). Useful other options are e.g. {"Armored vehicles"}, {"Tanks"},
-- or {"APC"} or combinations like {"APC", "Tanks", "Artillery"}. See [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes). -- or {"APC"} or combinations like {"APC", "Tanks", "Artillery"}. See [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes).
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:SetA2GEngageTargetTypes(types) function EASYA2G:SetA2GEngageTargetTypes(types)
@@ -501,10 +501,10 @@ end
-- @param #EASYA2G self -- @param #EASYA2G self
-- @param #string AirbaseName Name of the Wing's airbase -- @param #string AirbaseName Name of the Wing's airbase
-- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone). -- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone).
-- @param #number Altitude Defaults to 25000 feet ASL. -- @param #number Altitude (Optional) Defaults to 25000 feet ASL.
-- @param #number Speed Defaults to 300 knots TAS. -- @param #number Speed (Optional) Defaults to 300 knots TAS.
-- @param #number Heading Defaults to 90 degrees (East). -- @param #number Heading (Optional) Defaults to 90 degrees (East).
-- @param #number LegLength Defaults to 15 NM. -- @param #number LegLength (Optional) Defaults to 15 NM.
-- @return #EASYA2G self -- @return #EASYA2G self
function EASYA2G:AddHoldingPointA2G(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength) function EASYA2G:AddHoldingPointA2G(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength)
self:T(self.lid.."AddHoldingPointA2G")--..Coordinate:ToStringLLDDM()) self:T(self.lid.."AddHoldingPointA2G")--..Coordinate:ToStringLLDDM())
+34 -34
View File
@@ -447,7 +447,7 @@ end
--- Set "fuel low" threshold for CAP and INTERCEPT flights. --- Set "fuel low" threshold for CAP and INTERCEPT flights.
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Percent RTB if fuel at this percent. Values: 1..100, defaults to 25. -- @param #number Percent (Optional) RTB if fuel at this percent. Values: 1..100, defaults to 25.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetFuelLow(Percent) function EASYGCICAP:SetFuelLow(Percent)
self:T(self.lid.."SetFuelLow") self:T(self.lid.."SetFuelLow")
@@ -470,7 +470,7 @@ end
--- Set "fuel critical" threshold for CAP and INTERCEPT flights. --- Set "fuel critical" threshold for CAP and INTERCEPT flights.
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Percent RTB if fuel at this percent. Values: 1..100, defaults to 10. -- @param #number Percent (Optional) RTB if fuel at this percent. Values: 1..100, defaults to 10.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetFuelCritical(Percent) function EASYGCICAP:SetFuelCritical(Percent)
self:T(self.lid.."SetFuelCritical") self:T(self.lid.."SetFuelCritical")
@@ -480,7 +480,7 @@ end
--- Set CAP formation. --- Set CAP formation.
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Formation Formation to fly, defaults to ENUMS.Formation.FixedWing.FingerFour.Group -- @param #number Formation (Optional) Formation to fly, defaults to ENUMS.Formation.FixedWing.FingerFour.Group
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetCAPFormation(Formation) function EASYGCICAP:SetCAPFormation(Formation)
self:T(self.lid.."SetCAPFormation") self:T(self.lid.."SetCAPFormation")
@@ -514,7 +514,7 @@ end
--- Set Maximum of alive missions created by this instance to stop airplanes spamming the map --- Set Maximum of alive missions created by this instance to stop airplanes spamming the map
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Maxiumum Maxmimum number of parallel missions allowed. Count is Intercept-Missions + Alert5-Missions, default is 8 -- @param #number Maxiumum (Optional) Maxmimum number of parallel missions allowed. Count is Intercept-Missions + Alert5-Missions, default is 8
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetMaxAliveMissions(Maxiumum) function EASYGCICAP:SetMaxAliveMissions(Maxiumum)
self:T(self.lid.."SetMaxAliveMissions") self:T(self.lid.."SetMaxAliveMissions")
@@ -524,7 +524,7 @@ end
--- Add default time to resurrect Airwing building if destroyed --- Add default time to resurrect Airwing building if destroyed
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Seconds Seconds, defaults to 900 -- @param #number Seconds (Optional) Seconds, defaults to 900
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultResurrection(Seconds) function EASYGCICAP:SetDefaultResurrection(Seconds)
self:T(self.lid.."SetDefaultResurrection") self:T(self.lid.."SetDefaultResurrection")
@@ -534,7 +534,7 @@ end
--- Add default repeat attempts if an Intruder intercepts fails. --- Add default repeat attempts if an Intruder intercepts fails.
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Retries Retries, defaults to 3 -- @param #number Retries (Optional) Retries, defaults to 3
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultRepeatOnFailure(Retries) function EASYGCICAP:SetDefaultRepeatOnFailure(Retries)
self:T(self.lid.."SetDefaultRepeatOnFailure") self:T(self.lid.."SetDefaultRepeatOnFailure")
@@ -544,7 +544,7 @@ end
--- Add default take off type for the airwings. --- Add default take off type for the airwings.
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #string Takeoff Can be "hot", "cold", or "air" - default is "hot". -- @param #string Takeoff (Optional) Can be "hot", "cold", or "air" - default is "hot".
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultTakeOffType(Takeoff) function EASYGCICAP:SetDefaultTakeOffType(Takeoff)
self:T(self.lid.."SetDefaultTakeOffType") self:T(self.lid.."SetDefaultTakeOffType")
@@ -554,7 +554,7 @@ end
--- Set default CAP Speed in knots --- Set default CAP Speed in knots
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Speed Speed defaults to 300 -- @param #number Speed (Optional) Speed defaults to 300
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultCAPSpeed(Speed) function EASYGCICAP:SetDefaultCAPSpeed(Speed)
self:T(self.lid.."SetDefaultSpeed") self:T(self.lid.."SetDefaultSpeed")
@@ -564,7 +564,7 @@ end
--- Set default CAP Altitude in feet --- Set default CAP Altitude in feet
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Altitude Altitude defaults to 25000 -- @param #number Altitude (Optional) Altitude defaults to 25000
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultCAPAlt(Altitude) function EASYGCICAP:SetDefaultCAPAlt(Altitude)
self:T(self.lid.."SetDefaultAltitude") self:T(self.lid.."SetDefaultAltitude")
@@ -574,7 +574,7 @@ end
--- Set default CAP lieg initial direction in degrees --- Set default CAP lieg initial direction in degrees
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Direction Direction defaults to 90 (East) -- @param #number Direction (Optional) Direction defaults to 90 (East)
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultCAPDirection(Direction) function EASYGCICAP:SetDefaultCAPDirection(Direction)
self:T(self.lid.."SetDefaultDirection") self:T(self.lid.."SetDefaultDirection")
@@ -584,7 +584,7 @@ end
--- Set default leg length in NM --- Set default leg length in NM
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Leg Leg defaults to 15 -- @param #number Leg (Optional) Leg defaults to 15
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultCAPLeg(Leg) function EASYGCICAP:SetDefaultCAPLeg(Leg)
self:T(self.lid.."SetDefaultLeg") self:T(self.lid.."SetDefaultLeg")
@@ -594,7 +594,7 @@ end
--- Set default grouping, i.e. how many airplanes per CAP point --- Set default grouping, i.e. how many airplanes per CAP point
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Grouping Grouping defaults to 2 -- @param #number Grouping (Optional) Grouping defaults to 2
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultCAPGrouping(Grouping) function EASYGCICAP:SetDefaultCAPGrouping(Grouping)
self:T(self.lid.."SetDefaultCAPGrouping") self:T(self.lid.."SetDefaultCAPGrouping")
@@ -604,7 +604,7 @@ end
--- Set default range planes can fly from their homebase in NM --- Set default range planes can fly from their homebase in NM
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Range Range defaults to 100 NM -- @param #number Range (Optional) Range defaults to 100 NM
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultMissionRange(Range) function EASYGCICAP:SetDefaultMissionRange(Range)
self:T(self.lid.."SetDefaultMissionRange") self:T(self.lid.."SetDefaultMissionRange")
@@ -614,8 +614,8 @@ end
--- Set default turnover times for squadrons in minutes --- Set default turnover times for squadrons in minutes
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number MaintenanceTime Time in minutes it takes until a flight is combat ready again. Default is 5 min. -- @param #number MaintenanceTime (Optional) Time in minutes it takes until a flight is combat ready again. Default is 5 min.
-- @param #number RepairTime Time in minutes it takes to repair a flight for each life point taken. Default is 10 min. -- @param #number RepairTime (Optional) Time in minutes it takes to repair a flight for each life point taken. Default is 10 min.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultTurnoverTime(MaintenanceTime,RepairTime) function EASYGCICAP:SetDefaultTurnoverTime(MaintenanceTime,RepairTime)
self:T(self.lid.."SetDefaultTurnoverTime") self:T(self.lid.."SetDefaultTurnoverTime")
@@ -626,7 +626,7 @@ end
--- Set default number of airframes standing by for intercept tasks (visible on the airfield) --- Set default number of airframes standing by for intercept tasks (visible on the airfield)
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Airframes defaults to 2 -- @param #number Airframes (Optional) defaults to 2
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultNumberAlert5Standby(Airframes) function EASYGCICAP:SetDefaultNumberAlert5Standby(Airframes)
self:T(self.lid.."SetDefaultNumberAlert5Standby") self:T(self.lid.."SetDefaultNumberAlert5Standby")
@@ -636,7 +636,7 @@ end
--- Set default engage range for intruders detected by CAP flights in NM. --- Set default engage range for intruders detected by CAP flights in NM.
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #number Range defaults to 50NM -- @param #number Range (Optional) defaults to 50NM
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetDefaultEngageRange(Range) function EASYGCICAP:SetDefaultEngageRange(Range)
self:T(self.lid.."SetDefaultEngageRange") self:T(self.lid.."SetDefaultEngageRange")
@@ -689,7 +689,7 @@ end
--- Set which target types CAP flights will prefer to engage, defaults to {"Air"} --- Set which target types CAP flights will prefer to engage, defaults to {"Air"}
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #table types Table of comma separated #string entries, defaults to {"Air"} (everything that flies and is not a weapon). Useful other options are e.g. {"Bombers"}, {"Fighters"}, -- @param #table types (Optional) Table of comma separated #string entries, defaults to {"Air"} (everything that flies and is not a weapon). Useful other options are e.g. {"Bombers"}, {"Fighters"},
-- or {"Helicopters"} or combinations like {"Bombers", "Fighters", "UAVs"}. See [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes). -- or {"Helicopters"} or combinations like {"Bombers", "Fighters", "UAVs"}. See [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes).
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:SetCAPEngageTargetTypes(types) function EASYGCICAP:SetCAPEngageTargetTypes(types)
@@ -860,10 +860,10 @@ end
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #string AirbaseName Name of the Wing's airbase -- @param #string AirbaseName Name of the Wing's airbase
-- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone). -- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone).
-- @param #number Altitude Defaults to 25000 feet ASL. -- @param #number Altitude (Optional) Defaults to 25000 feet ASL.
-- @param #number Speed Defaults to 300 knots TAS. -- @param #number Speed (Optional) Defaults to 300 knots TAS.
-- @param #number Heading Defaults to 90 degrees (East). -- @param #number Heading (Optional) Defaults to 90 degrees (East).
-- @param #number LegLength Defaults to 15 NM. -- @param #number LegLength(Optional) Defaults to 15 NM.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:AddPatrolPointCAP(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength) function EASYGCICAP:AddPatrolPointCAP(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength)
self:T(self.lid.."AddPatrolPointCAP")--..Coordinate:ToStringLLDDM()) self:T(self.lid.."AddPatrolPointCAP")--..Coordinate:ToStringLLDDM())
@@ -891,10 +891,10 @@ end
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #string AirbaseName Name of the Wing's airbase -- @param #string AirbaseName Name of the Wing's airbase
-- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone). -- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone).
-- @param #number Altitude Defaults to 25000 feet. -- @param #number Altitude (Optional) Defaults to 25000 feet.
-- @param #number Speed Defaults to 300 knots. -- @param #number Speed (Optional) Defaults to 300 knots.
-- @param #number Heading Defaults to 90 degrees (East). -- @param #number Heading (Optional) Defaults to 90 degrees (East).
-- @param #number LegLength Defaults to 15 NM. -- @param #number LegLength (Optional) Defaults to 15 NM.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:AddPatrolPointRecon(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength) function EASYGCICAP:AddPatrolPointRecon(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength)
self:T(self.lid.."AddPatrolPointRecon "..Coordinate:ToStringLLDDM()) self:T(self.lid.."AddPatrolPointRecon "..Coordinate:ToStringLLDDM())
@@ -916,10 +916,10 @@ end
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #string AirbaseName Name of the Wing's airbase -- @param #string AirbaseName Name of the Wing's airbase
-- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone). -- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone).
-- @param #number Altitude Defaults to 25000 feet. -- @param #number Altitude (Optional) Defaults to 25000 feet.
-- @param #number Speed Defaults to 300 knots. -- @param #number Speed (Optional) Defaults to 300 knots.
-- @param #number Heading Defaults to 90 degrees (East). -- @param #number Heading (Optional) Defaults to 90 degrees (East).
-- @param #number LegLength Defaults to 15 NM. -- @param #number LegLength (Optional) Defaults to 15 NM.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:AddPatrolPointTanker(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength) function EASYGCICAP:AddPatrolPointTanker(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength)
self:T(self.lid.."AddPatrolPointTanker "..Coordinate:ToStringLLDDM()) self:T(self.lid.."AddPatrolPointTanker "..Coordinate:ToStringLLDDM())
@@ -941,10 +941,10 @@ end
-- @param #EASYGCICAP self -- @param #EASYGCICAP self
-- @param #string AirbaseName Name of the Wing's airbase -- @param #string AirbaseName Name of the Wing's airbase
-- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone). -- @param Core.Point#COORDINATE Coordinate. Can be handed as a Core.Zone#ZONE object (e.g. in case you want the point to align with a moving zone).
-- @param #number Altitude Defaults to 25000 feet. -- @param #number Altitude (Optional) Defaults to 25000 feet.
-- @param #number Speed Defaults to 300 knots. -- @param #number Speed (Optional) Defaults to 300 knots.
-- @param #number Heading Defaults to 90 degrees (East). -- @param #number Heading (Optional) Defaults to 90 degrees (East).
-- @param #number LegLength Defaults to 15 NM. -- @param #number LegLength (Optional) Defaults to 15 NM.
-- @return #EASYGCICAP self -- @return #EASYGCICAP self
function EASYGCICAP:AddPatrolPointAwacs(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength) function EASYGCICAP:AddPatrolPointAwacs(AirbaseName,Coordinate,Altitude,Speed,Heading,LegLength)
self:T(self.lid.."AddPatrolPointAwacs "..Coordinate:ToStringLLDDM()) self:T(self.lid.."AddPatrolPointAwacs "..Coordinate:ToStringLLDDM())
+43 -43
View File
@@ -359,11 +359,11 @@ FLIGHTCONTROL.version="0.7.7"
--- Create a new FLIGHTCONTROL class object for an associated airbase. --- Create a new FLIGHTCONTROL class object for an associated airbase.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string AirbaseName Name of the airbase. -- @param #string AirbaseName Name of the airbase.
-- @param #number Frequency Radio frequency in MHz. Default 143.00 MHz. Can also be given as a `#table` of multiple frequencies. -- @param #number Frequency (Optional) Radio frequency in MHz. Default 143.00 MHz. Can also be given as a `#table` of multiple frequencies.
-- @param #number Modulation Radio modulation: 0=AM (default), 1=FM. See `radio.modulation.AM` and `radio.modulation.FM` enumerators. Can also be given as a `#table` of multiple modulations. -- @param #number Modulation (Optional) Radio modulation: 0=AM (default), 1=FM. See `radio.modulation.AM` and `radio.modulation.FM` enumerators. Can also be given as a `#table` of multiple modulations.
-- @param #string PathToSRS Path to the directory, where SRS is located. -- @param #string PathToSRS (Optional) Path to the directory, where SRS is located.
-- @param #number Port Port of SRS Server, defaults to 5002 -- @param #number Port (Optional) Port of SRS Server, defaults to 5002
-- @param #string GoogleKey Path to the Google JSON-Key. -- @param #string GoogleKey (Optional) Path to the Google JSON-Key.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:New(AirbaseName, Frequency, Modulation, PathToSRS, Port, GoogleKey) function FLIGHTCONTROL:New(AirbaseName, Frequency, Modulation, PathToSRS, Port, GoogleKey)
@@ -570,7 +570,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetVerbosity(VerbosityLevel) function FLIGHTCONTROL:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -620,8 +620,8 @@ end
--- Set the tower frequency. --- Set the tower frequency.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number Frequency Frequency in MHz. Default 305 MHz. -- @param #number Frequency (Optional) Frequency in MHz. Default 305 MHz.
-- @param #number Modulation Modulation `radio.modulation.AM`=0, `radio.modulation.FM`=1. Default `radio.modulation.AM`. -- @param #number Modulation (Optional) Modulation `radio.modulation.AM`=0, `radio.modulation.FM`=1. Default `radio.modulation.AM`.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetFrequency(Frequency, Modulation) function FLIGHTCONTROL:SetFrequency(Frequency, Modulation)
@@ -643,7 +643,7 @@ end
--- Set the SRS server port. --- Set the SRS server port.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number Port Port to be used. Defaults to 5002. -- @param #number Port (Optional) Port to be used. Defaults to 5002.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetSRSPort(Port) function FLIGHTCONTROL:SetSRSPort(Port)
self.Port = Port or 5002 self.Port = Port or 5002
@@ -653,13 +653,13 @@ end
--- Set SRS options for a given MSRS object. --- Set SRS options for a given MSRS object.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param Sound.SRS#MSRS msrs Moose SRS object. -- @param Sound.SRS#MSRS msrs Moose SRS object.
-- @param #string Gender Gender: "male" or "female" (default). -- @param #string Gender (Optional) Gender: "male" or "female" (default).
-- @param #string Culture Culture, e.g. "en-GB" (default). -- @param #string Culture (Optional) Culture, e.g. "en-GB" (default).
-- @param #string Voice Specific voice. Overrides `Gender` and `Culture`. -- @param #string Voice Specific voice. Overrides `Gender` and `Culture`.
-- @param #number Volume Volume. Default 1.0. -- @param #number Volume (Optional) Volume. Default 1.0.
-- @param #string Label Name under which SRS transmits. -- @param #string Label Name under which SRS transmits.
-- @param #string PathToGoogleCredentials Path to google credentials json file. -- @param #string PathToGoogleCredentials (Optional) Path to google credentials json file.
-- @param #number Port Server port for SRS -- @param #number Port (Optional) Server port for SRS. Defaults to 5002.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:_SetSRSOptions(msrs, Gender, Culture, Voice, Volume, Label, PathToGoogleCredentials, Port) function FLIGHTCONTROL:_SetSRSOptions(msrs, Gender, Culture, Voice, Volume, Label, PathToGoogleCredentials, Port)
@@ -683,11 +683,11 @@ end
--- Set SRS options for tower voice. --- Set SRS options for tower voice.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Gender Gender: "male" or "female" (default). -- @param #string Gender (Optional) Gender: "male" or "female" (default).
-- @param #string Culture Culture, e.g. "en-GB" (default). -- @param #string Culture (Optional) Culture, e.g. "en-GB" (default).
-- @param #string Voice Specific voice. Overrides `Gender` and `Culture`. See [Google Voices](https://cloud.google.com/text-to-speech/docs/voices). -- @param #string Voice Specific voice. Overrides `Gender` and `Culture`. See [Google Voices](https://cloud.google.com/text-to-speech/docs/voices).
-- @param #number Volume Volume. Default 1.0. -- @param #number Volume (Optional) Volume. Default 1.0.
-- @param #string Label Name under which SRS transmits. Default `self.alias`. -- @param #string Label (Optional) Name under which SRS transmits. Default `self.alias`.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetSRSTower(Gender, Culture, Voice, Volume, Label) function FLIGHTCONTROL:SetSRSTower(Gender, Culture, Voice, Volume, Label)
@@ -700,11 +700,11 @@ end
--- Set SRS options for pilot voice. --- Set SRS options for pilot voice.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Gender Gender: "male" (default) or "female". -- @param #string Gender (Optional) Gender: "male" (default) or "female".
-- @param #string Culture Culture, e.g. "en-US" (default). -- @param #string Culture (Optional) Culture, e.g. "en-US" (default).
-- @param #string Voice Specific voice. Overrides `Gender` and `Culture`. -- @param #string Voice Specific voice. Overrides `Gender` and `Culture`.
-- @param #number Volume Volume. Default 1.0. -- @param #number Volume (Optional) Volume. Default 1.0.
-- @param #string Label Name under which SRS transmits. Default "Pilot". -- @param #string Label (Optional) Name under which SRS transmits. Default "Pilot".
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetSRSPilot(Gender, Culture, Voice, Volume, Label) function FLIGHTCONTROL:SetSRSPilot(Gender, Culture, Voice, Volume, Label)
@@ -726,8 +726,8 @@ end
-- in cases where simultaneous takeoffs and landings are unproblematic. Note that only because there are multiple runways, it does not mean the AI uses them. -- in cases where simultaneous takeoffs and landings are unproblematic. Note that only because there are multiple runways, it does not mean the AI uses them.
-- --
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number Nlanding Max number of aircraft landing simultaneously. Default 2. -- @param #number Nlanding (Optional) Max number of aircraft landing simultaneously. Default 2.
-- @param #number Ntakeoff Allowed number of aircraft taking off for groups to get landing clearance. Default 0. -- @param #number Ntakeoff (Optional) Allowed number of aircraft taking off for groups to get landing clearance. Default 0.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetLimitLanding(Nlanding, Ntakeoff) function FLIGHTCONTROL:SetLimitLanding(Nlanding, Ntakeoff)
@@ -740,7 +740,7 @@ end
--- Set time interval between landing clearance of groups. --- Set time interval between landing clearance of groups.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number dt Time interval in seconds. Default 180 sec (3 min). -- @param #number dt (Optional) Time interval in seconds. Default 180 sec (3 min).
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetLandingInterval(dt) function FLIGHTCONTROL:SetLandingInterval(dt)
@@ -763,9 +763,9 @@ end
-- NOTE that human players are *not* restricted as they should behave better (hopefully) than the AI. -- NOTE that human players are *not* restricted as they should behave better (hopefully) than the AI.
-- --
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number Ntaxi Max number of groups allowed to taxi. Default 2. -- @param #number Ntaxi (Optional) Max number of groups allowed to taxi. Default 2.
-- @param #boolean IncludeInbound If `true`, the above -- @param #boolean IncludeInbound If `true`, the above
-- @param #number Nlanding Max number of landing flights. Default 0. -- @param #number Nlanding (Optional) Max number of landing flights. Default 0.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetLimitTaxi(Ntaxi, IncludeInbound, Nlanding) function FLIGHTCONTROL:SetLimitTaxi(Ntaxi, IncludeInbound, Nlanding)
@@ -783,10 +783,10 @@ end
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param Core.Zone#ZONE ArrivalZone Zone where planes arrive. -- @param Core.Zone#ZONE ArrivalZone Zone where planes arrive.
-- @param #number Heading Heading in degrees. -- @param #number Heading Heading in degrees.
-- @param #number Length Length in nautical miles. Default 15 NM. -- @param #number Length (Optional) Length in nautical miles. Default 15 NM.
-- @param #number FlightlevelMin Min flight level. Default 5. -- @param #number FlightlevelMin (Optional) Min flight level. Default 5.
-- @param #number FlightlevelMax Max flight level. Default 15. -- @param #number FlightlevelMax (Optional) Max flight level. Default 15.
-- @param #number Prio Priority. Lower is higher. Default 50. -- @param #number Prio (Optional) Priority. Lower is higher. Default 50.
-- @return #FLIGHTCONTROL.HoldingPattern Holding pattern table. -- @return #FLIGHTCONTROL.HoldingPattern Holding pattern table.
function FLIGHTCONTROL:AddHoldingPattern(ArrivalZone, Heading, Length, FlightlevelMin, FlightlevelMax, Prio) function FLIGHTCONTROL:AddHoldingPattern(ArrivalZone, Heading, Length, FlightlevelMin, FlightlevelMax, Prio)
@@ -946,7 +946,7 @@ end
-- Note that this is the time, the DCS engine uses not something we can control on a user level or we could get via scripting. -- Note that this is the time, the DCS engine uses not something we can control on a user level or we could get via scripting.
-- You need to input the value. On the DCS forum it was stated that this is currently one hour. Hence this is the default value. -- You need to input the value. On the DCS forum it was stated that this is currently one hour. Hence this is the default value.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #number RepairTime Time in seconds until the runway is repaired. Default 3600sec (one hour). -- @param #number RepairTime (Optional) Time in seconds until the runway is repaired. Default 3600sec (one hour).
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
function FLIGHTCONTROL:SetRunwayRepairtime(RepairTime) function FLIGHTCONTROL:SetRunwayRepairtime(RepairTime)
self.runwayrepairtime=RepairTime or 3600 self.runwayrepairtime=RepairTime or 3600
@@ -2020,7 +2020,7 @@ end
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Status Return only flights in this flightcontrol status, e.g. `FLIGHTCONTROL.Status.XXX`. -- @param #string Status Return only flights in this flightcontrol status, e.g. `FLIGHTCONTROL.Status.XXX`.
-- @param #string GroupStatus Return only flights in this FSM status, e.g. `OPSGROUP.GroupStatus.TAXIING`. -- @param #string GroupStatus Return only flights in this FSM status, e.g. `OPSGROUP.GroupStatus.TAXIING`.
-- @param #boolean AI If `true` only AI flights are returned. If `false`, only flights with clients are returned. If `nil` (default), all flights are returned. -- @param #boolean AI (Optional) If `true` only AI flights are returned. If `false`, only flights with clients are returned. If `nil` (default), all flights are returned.
-- @return #table Table of flights. -- @return #table Table of flights.
function FLIGHTCONTROL:GetFlights(Status, GroupStatus, AI) function FLIGHTCONTROL:GetFlights(Status, GroupStatus, AI)
@@ -2054,7 +2054,7 @@ end
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Status Return only flights in this status. -- @param #string Status Return only flights in this status.
-- @param #string GroupStatus Count only flights in this FSM status, e.g. `OPSGROUP.GroupStatus.TAXIING`. -- @param #string GroupStatus Count only flights in this FSM status, e.g. `OPSGROUP.GroupStatus.TAXIING`.
-- @param #boolean AI If `true` only AI flights are counted. If `false`, only flights with clients are counted. If `nil` (default), all flights are counted. -- @param #boolean AI (Optional) If `true` only AI flights are counted. If `false`, only flights with clients are counted. If `nil` (default), all flights are counted.
-- @return #number Number of flights. -- @return #number Number of flights.
function FLIGHTCONTROL:CountFlights(Status, GroupStatus, AI) function FLIGHTCONTROL:CountFlights(Status, GroupStatus, AI)
@@ -2101,7 +2101,7 @@ end
--- Get the name of the active runway. --- Get the name of the active runway.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #boolean Takeoff If true, return takeoff runway name. Default is landing. -- @param #boolean Takeoff (Optional) If true, return takeoff runway name. Default is landing.
-- @return #string Runway text, e.g. "31L" or "09". -- @return #string Runway text, e.g. "31L" or "09".
function FLIGHTCONTROL:GetActiveRunwayText(Takeoff) function FLIGHTCONTROL:GetActiveRunwayText(Takeoff)
@@ -2243,7 +2243,7 @@ end
--- Set parking spot to RESERVED and update F10 marker. --- Set parking spot to RESERVED and update F10 marker.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param Wrapper.Airbase#AIRBASE.ParkingSpot spot The parking spot data table. -- @param Wrapper.Airbase#AIRBASE.ParkingSpot spot The parking spot data table.
-- @param #string unitname Name of the unit occupying the spot. Default "unknown". -- @param #string unitname (Optional) Name of the unit occupying the spot. Default "unknown".
function FLIGHTCONTROL:SetParkingReserved(spot, unitname) function FLIGHTCONTROL:SetParkingReserved(spot, unitname)
-- Get spot. -- Get spot.
@@ -2263,7 +2263,7 @@ end
--- Set parking spot to OCCUPIED and update F10 marker. --- Set parking spot to OCCUPIED and update F10 marker.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param Wrapper.Airbase#AIRBASE.ParkingSpot spot The parking spot data table. -- @param Wrapper.Airbase#AIRBASE.ParkingSpot spot The parking spot data table.
-- @param #string unitname Name of the unit occupying the spot. Default "unknown". -- @param #string unitname (Optional) Name of the unit occupying the spot. Default "unknown".
function FLIGHTCONTROL:SetParkingOccupied(spot, unitname) function FLIGHTCONTROL:SetParkingOccupied(spot, unitname)
-- Get spot. -- Get spot.
@@ -4351,7 +4351,7 @@ end
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Text The text to transmit. -- @param #string Text The text to transmit.
-- @param Ops.FlightGroup#FLIGHTGROUP Flight The flight. -- @param Ops.FlightGroup#FLIGHTGROUP Flight The flight.
-- @param #number Delay Delay in seconds before the text is transmitted. Default 0 sec. -- @param #number Delay (Optional) Delay in seconds before the text is transmitted. Default 0 sec.
function FLIGHTCONTROL:TransmissionTower(Text, Flight, Delay) function FLIGHTCONTROL:TransmissionTower(Text, Flight, Delay)
if self.radioOnlyIfPlayers==true and self.Nplayers==0 then if self.radioOnlyIfPlayers==true and self.Nplayers==0 then
@@ -4387,7 +4387,7 @@ end
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Text The text to transmit. -- @param #string Text The text to transmit.
-- @param Ops.FlightGroup#FLIGHTGROUP Flight The flight. -- @param Ops.FlightGroup#FLIGHTGROUP Flight The flight.
-- @param #number Delay Delay in seconds before the text is transmitted. Default 0 sec. -- @param #number Delay (Optional) Delay in seconds before the text is transmitted. Default 0 sec.
function FLIGHTCONTROL:TransmissionPilot(Text, Flight, Delay) function FLIGHTCONTROL:TransmissionPilot(Text, Flight, Delay)
if self.radioOnlyIfPlayers==true and self.Nplayers==0 then if self.radioOnlyIfPlayers==true and self.Nplayers==0 then
@@ -4445,9 +4445,9 @@ end
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #string Text The text to transmit. -- @param #string Text The text to transmit.
-- @param Ops.FlightGroup#FLIGHTGROUP Flight The flight. -- @param Ops.FlightGroup#FLIGHTGROUP Flight The flight.
-- @param #number Duration Duration in seconds. Default 5. -- @param #number Duration (Optional) Duration in seconds. Default 5.
-- @param #boolean Clear Clear screen. -- @param #boolean Clear Clear screen.
-- @param #number Delay Delay in seconds before the text is transmitted. Default 0 sec. -- @param #number Delay (Optional) Delay in seconds before the text is transmitted. Default 0 sec.
function FLIGHTCONTROL:TextMessageToFlight(Text, Flight, Duration, Clear, Delay) function FLIGHTCONTROL:TextMessageToFlight(Text, Flight, Duration, Clear, Delay)
if Delay and Delay>0 then if Delay and Delay>0 then
@@ -4591,8 +4591,8 @@ end
--- [User] Set callsign options for TTS output. See @{Wrapper.Group#GROUP.GetCustomCallSign}() on how to set customized callsigns. --- [User] Set callsign options for TTS output. See @{Wrapper.Group#GROUP.GetCustomCallSign}() on how to set customized callsigns.
-- @param #FLIGHTCONTROL self -- @param #FLIGHTCONTROL self
-- @param #boolean ShortCallsign If true, only call out the major flight number. Default = `true`. -- @param #boolean ShortCallsign (Optional) If true, only call out the major flight number. Default = `true`.
-- @param #boolean Keepnumber If true, keep the **customized callsign** in the #GROUP name for players as-is, no amendments or numbers. Default = `true`. -- @param #boolean Keepnumber (Optional) If true, keep the **customized callsign** in the #GROUP name for players as-is, no amendments or numbers. Default = `true`.
-- @param #table CallsignTranslations (optional) Table to translate between DCS standard callsigns and bespoke ones. Does not apply if using customized -- @param #table CallsignTranslations (optional) Table to translate between DCS standard callsigns and bespoke ones. Does not apply if using customized
-- callsigns from playername or group name. -- callsigns from playername or group name.
-- @return #FLIGHTCONTROL self -- @return #FLIGHTCONTROL self
+38 -38
View File
@@ -837,7 +837,7 @@ end
--- Set if group is ready for taxi/takeoff if controlled by a `FLIGHTCONTROL`. --- Set if group is ready for taxi/takeoff if controlled by a `FLIGHTCONTROL`.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #boolean ReadyTO If `true`, flight is ready for takeoff. -- @param #boolean ReadyTO If `true`, flight is ready for takeoff.
-- @param #number Delay Delay in seconds before value is set. Default 0 sec. -- @param #number Delay (Optional) Delay in seconds before value is set. Default 0 sec.
-- @return #FLIGHTGROUP self -- @return #FLIGHTGROUP self
function FLIGHTGROUP:SetReadyForTakeoff(ReadyTO, Delay) function FLIGHTGROUP:SetReadyForTakeoff(ReadyTO, Delay)
if Delay and Delay>0 then if Delay and Delay>0 then
@@ -922,7 +922,7 @@ end
--- Set low fuel threshold. Triggers event "FuelLow" and calls event function "OnAfterFuelLow". --- Set low fuel threshold. Triggers event "FuelLow" and calls event function "OnAfterFuelLow".
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #number threshold Fuel threshold in percent. Default 25 %. -- @param #number threshold (Optional) Fuel threshold in percent. Default 25 %.
-- @return #FLIGHTGROUP self -- @return #FLIGHTGROUP self
function FLIGHTGROUP:SetFuelLowThreshold(threshold) function FLIGHTGROUP:SetFuelLowThreshold(threshold)
self.fuellowthresh=threshold or 25 self.fuellowthresh=threshold or 25
@@ -983,7 +983,7 @@ end
--- Set fuel critical threshold. Triggers event "FuelCritical" and event function "OnAfterFuelCritical". --- Set fuel critical threshold. Triggers event "FuelCritical" and event function "OnAfterFuelCritical".
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #number threshold Fuel threshold in percent. Default 10 %. -- @param #number threshold (Optional) Fuel threshold in percent. Default 10 %.
-- @return #FLIGHTGROUP self -- @return #FLIGHTGROUP self
function FLIGHTGROUP:SetFuelCriticalThreshold(threshold) function FLIGHTGROUP:SetFuelCriticalThreshold(threshold)
self.fuelcriticalthresh=threshold or 10 self.fuelcriticalthresh=threshold or 10
@@ -2629,8 +2629,8 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #number n Next waypoint index. Default is the one coming after that one that has been passed last. -- @param #number n (Optional) Next waypoint index. Default is the one coming after that one that has been passed last.
-- @param #number N Waypoint Max waypoint index to be included in the route. Default is the final waypoint. -- @param #number N(Optional) Waypoint Max waypoint index to be included in the route. Default is the final waypoint.
-- @return #boolean Transision allowed? -- @return #boolean Transision allowed?
function FLIGHTGROUP:onbeforeUpdateRoute(From, Event, To, n, N) function FLIGHTGROUP:onbeforeUpdateRoute(From, Event, To, n, N)
@@ -2752,8 +2752,8 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #number n Next waypoint index. Default is the one coming after that one that has been passed last. -- @param #number n (Optional) Next waypoint index. Default is the one coming after that one that has been passed last.
-- @param #number N Waypoint Max waypoint index to be included in the route. Default is the final waypoint. -- @param #number N (Optional) Waypoint Max waypoint index to be included in the route. Default is the final waypoint.
function FLIGHTGROUP:onafterUpdateRoute(From, Event, To, n, N) function FLIGHTGROUP:onafterUpdateRoute(From, Event, To, n, N)
-- Update route from this waypoint number onwards. -- Update route from this waypoint number onwards.
@@ -3100,9 +3100,9 @@ end
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param Wrapper.Airbase#AIRBASE airbase The airbase to hold at. -- @param Wrapper.Airbase#AIRBASE airbase The airbase to hold at.
-- @param #number SpeedTo Speed used for traveling from current position to holding point in knots. Default 75% of max speed. -- @param #number SpeedTo (Optional) Speed used for traveling from current position to holding point in knots. Default 75% of max speed.
-- @param #number SpeedHold Holding speed in knots. Default 250 kts. -- @param #number SpeedHold (Optional) Holding speed in knots. Default 250 kts.
-- @param #number SpeedLand Landing speed in knots. Default 170 kts. -- @param #number SpeedLand (Optional) Landing speed in knots. Default 170 kts.
function FLIGHTGROUP:onafterRTB(From, Event, To, airbase, SpeedTo, SpeedHold, SpeedLand) function FLIGHTGROUP:onafterRTB(From, Event, To, airbase, SpeedTo, SpeedHold, SpeedLand)
-- Debug info. -- Debug info.
@@ -3195,9 +3195,9 @@ end
--- Land at an airbase. --- Land at an airbase.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param Wrapper.Airbase#AIRBASE airbase Airbase where the group shall land. -- @param Wrapper.Airbase#AIRBASE airbase Airbase where the group shall land.
-- @param #number SpeedTo Speed used for travelling from current position to holding point in knots. -- @param #number (Optional) SpeedTo Speed used for travelling from current position to holding point in knots. Defaults to speedCruise.
-- @param #number SpeedHold Holding speed in knots. -- @param #number (Optional) SpeedHold Holding speed in knots. Defaults to 250kts.
-- @param #number SpeedLand Landing speed in knots. Default 170 kts. -- @param #number (Optional) SpeedLand Landing speed in knots. Default 170 kts.
function FLIGHTGROUP:_LandAtAirbase(airbase, SpeedTo, SpeedHold, SpeedLand) function FLIGHTGROUP:_LandAtAirbase(airbase, SpeedTo, SpeedHold, SpeedLand)
-- Set current airbase. -- Set current airbase.
@@ -3381,9 +3381,9 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #number Duration Duration how long the group will be waiting in seconds. Default `nil` (=forever). -- @param #number Duration (Optional) Duration how long the group will be waiting in seconds. Default `nil` (=forever).
-- @param #number Altitude Altitude in feet. Default 10,000 ft for airplanes and 1,000 feet for helos. -- @param #number Altitude (Optional) Altitude in feet. Default 10,000 ft for airplanes and 1,000 feet for helos.
-- @param #number Speed Speed in knots. Default 250 kts for airplanes and 20 kts for helos. -- @param #number Speed (Optional) Speed in knots. Default 250 kts for airplanes and 20 kts for helos.
function FLIGHTGROUP:onbeforeWait(From, Event, To, Duration, Altitude, Speed) function FLIGHTGROUP:onbeforeWait(From, Event, To, Duration, Altitude, Speed)
local allowed=true local allowed=true
@@ -3417,9 +3417,9 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #number Duration Duration how long the group will be waiting in seconds. Default `nil` (=forever). -- @param #number Duration (Optional) Duration how long the group will be waiting in seconds. Default `nil` (=forever).
-- @param #number Altitude Altitude in feet. Default 10,000 ft for airplanes and 1,000 feet for helos. -- @param #number Altitude (Optional) Altitude in feet. Default 10,000 ft for airplanes and 1,000 feet for helos.
-- @param #number Speed Speed in knots. Default 250 kts for airplanes and 20 kts for helos. -- @param #number Speed (Optional) Speed in knots. Default 250 kts for airplanes and 20 kts for helos.
function FLIGHTGROUP:onafterWait(From, Event, To, Duration, Altitude, Speed) function FLIGHTGROUP:onafterWait(From, Event, To, Duration, Altitude, Speed)
-- Group will orbit at its current position. -- Group will orbit at its current position.
@@ -3696,8 +3696,8 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param Core.Point#COORDINATE Coordinate The coordinate where to land. Default is current position. -- @param Core.Point#COORDINATE (Optional) Coordinate The coordinate where to land. Default is current position.
-- @param #number Duration The duration in seconds to remain on ground. Default 600 sec (10 min). -- @param #number Duration (Optional) The duration in seconds to remain on ground. Default 600 sec (10 min).
function FLIGHTGROUP:onbeforeLandAt(From, Event, To, Coordinate, Duration) function FLIGHTGROUP:onbeforeLandAt(From, Event, To, Coordinate, Duration)
return self.isHelo return self.isHelo
end end
@@ -3707,8 +3707,8 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param Core.Point#COORDINATE Coordinate The coordinate where to land. Default is current position. -- @param Core.Point#COORDINATE (Optional) Coordinate The coordinate where to land. Default is current position.
-- @param #number Duration The duration in seconds to remain on ground. Default `nil` = forever. -- @param #number Duration (Optional) The duration in seconds to remain on ground. Default `nil` = forever.
function FLIGHTGROUP:onafterLandAt(From, Event, To, Coordinate, Duration) function FLIGHTGROUP:onafterLandAt(From, Event, To, Coordinate, Duration)
-- Duration. -- Duration.
@@ -3879,8 +3879,8 @@ end
--- Initialize group parameters. Also initializes waypoints if self.waypoints is nil. --- Initialize group parameters. Also initializes waypoints if self.waypoints is nil.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #table Template Template used to init the group. Default is `self.template`. -- @param #table Template (Optional) Template used to init the group. Default is `self.template`.
-- @param #number Delay Delay in seconds before group is initialized. Default `nil`, *i.e.* instantaneous. -- @param #number Delay (Optional) Delay in seconds before group is initialized. Default `nil`, *i.e.* instantaneous.
-- @return #FLIGHTGROUP self -- @return #FLIGHTGROUP self
function FLIGHTGROUP:_InitGroup(Template, Delay) function FLIGHTGROUP:_InitGroup(Template, Delay)
@@ -4040,7 +4040,7 @@ end
--- Find the nearest friendly airbase (same or neutral coalition). --- Find the nearest friendly airbase (same or neutral coalition).
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #number Radius Search radius in NM. Default 50 NM. -- @param #number Radius (Optional) Search radius in NM. Default 50 NM.
-- @return Wrapper.Airbase#AIRBASE Closest tanker group #nil. -- @return Wrapper.Airbase#AIRBASE Closest tanker group #nil.
function FLIGHTGROUP:FindNearestAirbase(Radius) function FLIGHTGROUP:FindNearestAirbase(Radius)
@@ -4075,7 +4075,7 @@ end
--- Find the nearest tanker. --- Find the nearest tanker.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #number Radius Search radius in NM. Default 50 NM. -- @param #number Radius (Optional) Search radius in NM. Default 50 NM.
-- @return Wrapper.Group#GROUP Closest tanker group or `nil` if no tanker is in the given radius. -- @return Wrapper.Group#GROUP Closest tanker group or `nil` if no tanker is in the given radius.
function FLIGHTGROUP:FindNearestTanker(Radius) function FLIGHTGROUP:FindNearestTanker(Radius)
@@ -4226,7 +4226,7 @@ end
--- Check if the final waypoint is in the air. --- Check if the final waypoint is in the air.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #table wp Waypoint. Default final waypoint. -- @param #table wp (Optional) Waypoint. Default final waypoint.
-- @return #boolean If `true` final waypoint is a turning or flyover but not a landing type waypoint. -- @return #boolean If `true` final waypoint is a turning or flyover but not a landing type waypoint.
function FLIGHTGROUP:IsLandingAir(wp) function FLIGHTGROUP:IsLandingAir(wp)
@@ -4247,7 +4247,7 @@ end
--- Check if the final waypoint is at an airbase. --- Check if the final waypoint is at an airbase.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param #table wp Waypoint. Default final waypoint. -- @param #table wp (Optional) Waypoint. Default final waypoint.
-- @return #boolean If `true`, final waypoint is a landing waypoint at an airbase. -- @return #boolean If `true`, final waypoint is a landing waypoint at an airbase.
function FLIGHTGROUP:IsLandingAirbase(wp) function FLIGHTGROUP:IsLandingAirbase(wp)
@@ -4270,10 +4270,10 @@ end
--- Add an AIR waypoint to the flight plan. --- Add an AIR waypoint to the flight plan.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param Core.Point#COORDINATE Coordinate The coordinate of the waypoint. Use COORDINATE:SetAltitude(altitude) to define the altitude. -- @param Core.Point#COORDINATE Coordinate The coordinate of the waypoint. Use COORDINATE:SetAltitude(altitude) to define the altitude.
-- @param #number Speed Speed in knots. Default is cruise speed. -- @param #number Speed (Optional) Speed in knots. Default is cruise speed.
-- @param #number AfterWaypointWithID Insert waypoint after waypoint given ID. Default is to insert as last waypoint. -- @param #number AfterWaypointWithID (Optional) Insert waypoint after waypoint given ID. Default is to insert as last waypoint.
-- @param #number Altitude Altitude in feet. Default is y-component of Coordinate. Note that these altitudes are wrt to sea level (barometric altitude). -- @param #number Altitude (Optional) Altitude in feet. Default is y-component of Coordinate. Note that these altitudes are wrt to sea level (barometric altitude).
-- @param #boolean Updateroute If true or nil, call UpdateRoute. If false, no call. -- @param #boolean Updateroute (Optional) If true or nil, call UpdateRoute. If false, no call.
-- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table. -- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table.
function FLIGHTGROUP:AddWaypoint(Coordinate, Speed, AfterWaypointWithID, Altitude, Updateroute) function FLIGHTGROUP:AddWaypoint(Coordinate, Speed, AfterWaypointWithID, Altitude, Updateroute)
@@ -4323,10 +4323,10 @@ end
--- Add an LANDING waypoint to the flight plan. --- Add an LANDING waypoint to the flight plan.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param Wrapper.Airbase#AIRBASE Airbase The airbase where the group should land. -- @param Wrapper.Airbase#AIRBASE Airbase The airbase where the group should land.
-- @param #number Speed Speed in knots. Default 350 kts. -- @param #number Speed (Optional) Speed in knots. Default 350 kts.
-- @param #number AfterWaypointWithID Insert waypoint after waypoint given ID. Default is to insert as last waypoint. -- @param #number AfterWaypointWithID (Optional) Insert waypoint after waypoint given ID. Default is to insert as last waypoint.
-- @param #number Altitude Altitude in feet. Default is y-component of Coordinate. Note that these altitudes are wrt to sea level (barometric altitude). -- @param #number Altitude (Optional) Altitude in feet. Default is y-component of Coordinate. Note that these altitudes are wrt to sea level (barometric altitude).
-- @param #boolean Updateroute If true or nil, call UpdateRoute. If false, no call. -- @param #boolean Updateroute (Optional) If true or nil, call UpdateRoute. If false, no call.
-- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table. -- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table.
function FLIGHTGROUP:AddWaypointLanding(Airbase, Speed, AfterWaypointWithID, Altitude, Updateroute) function FLIGHTGROUP:AddWaypointLanding(Airbase, Speed, AfterWaypointWithID, Altitude, Updateroute)
@@ -4541,7 +4541,7 @@ end
--- Returns the parking spot of the element. --- Returns the parking spot of the element.
-- @param #FLIGHTGROUP self -- @param #FLIGHTGROUP self
-- @param Ops.OpsGroup#OPSGROUP.Element element Element of the flight group. -- @param Ops.OpsGroup#OPSGROUP.Element element Element of the flight group.
-- @param #number maxdist Distance threshold in meters. Default 5 m. -- @param #number maxdist (Optional) Distance threshold in meters. Default 5 m.
-- @param Wrapper.Airbase#AIRBASE airbase (Optional) The airbase to check for parking. Default is closest airbase to the element. -- @param Wrapper.Airbase#AIRBASE airbase (Optional) The airbase to check for parking. Default is closest airbase to the element.
-- @return Wrapper.Airbase#AIRBASE.ParkingSpot Parking spot or nil if no spot is within distance threshold. -- @return Wrapper.Airbase#AIRBASE.ParkingSpot Parking spot or nil if no spot is within distance threshold.
function FLIGHTGROUP:GetParkingSpot(element, maxdist, airbase) function FLIGHTGROUP:GetParkingSpot(element, maxdist, airbase)
+1 -1
View File
@@ -56,7 +56,7 @@ FLOTILLA.version="0.1.0"
--- Create a new FLOTILLA object and start the FSM. --- Create a new FLOTILLA object and start the FSM.
-- @param #FLOTILLA self -- @param #FLOTILLA self
-- @param #string TemplateGroupName Name of the template group. -- @param #string TemplateGroupName Name of the template group.
-- @param #number Ngroups Number of asset groups of this flotilla. Default 3. -- @param #number Ngroups (Optional) Number of asset groups of this flotilla. Default 3.
-- @param #string FlotillaName Name of the flotilla. Must be **unique**! -- @param #string FlotillaName Name of the flotilla. Must be **unique**!
-- @return #FLOTILLA self -- @return #FLOTILLA self
function FLOTILLA:New(TemplateGroupName, Ngroups, FlotillaName) function FLOTILLA:New(TemplateGroupName, Ngroups, FlotillaName)
+14 -14
View File
@@ -411,8 +411,8 @@ end
--- Set to accept accoustic detection. --- Set to accept accoustic detection.
-- @param #INTEL self -- @param #INTEL self
-- @param #number Radius Radius in which we can "hear" units. Defaults to 1000 meters. -- @param #number Radius (Optional) Radius in which we can "hear" units. Defaults to 1000 meters.
-- @param #table UnitCategories Set what Unit Categories we can "hear". Defaults to `{Unit.Category.GROUND_UNIT,Unit.Category.HELICOPTER}` -- @param #table UnitCategories(Optional) Set what Unit Categories we can "hear". Defaults to `{Unit.Category.GROUND_UNIT,Unit.Category.HELICOPTER}`
-- @return #INTEL self -- @return #INTEL self
function INTEL:SetAccousticDetectionOn(Radius,UnitCategories) function INTEL:SetAccousticDetectionOn(Radius,UnitCategories)
self.DetectAccoustic = true self.DetectAccoustic = true
@@ -572,7 +572,7 @@ end
-- Previously known contacts that are not detected any more, are "lost" after this time. -- Previously known contacts that are not detected any more, are "lost" after this time.
-- This avoids fast oscillations between a contact being detected and undetected. -- This avoids fast oscillations between a contact being detected and undetected.
-- @param #INTEL self -- @param #INTEL self
-- @param #number TimeInterval Time interval in seconds. Default is 120 sec. -- @param #number TimeInterval (Optional) Time interval in seconds. Default is 120 sec.
-- @return #INTEL self -- @return #INTEL self
function INTEL:SetForgetTime(TimeInterval) function INTEL:SetForgetTime(TimeInterval)
return self return self
@@ -607,10 +607,10 @@ end
--- Method to make the radar detection less accurate, e.g. for WWII scenarios. --- Method to make the radar detection less accurate, e.g. for WWII scenarios.
-- @param #INTEL self -- @param #INTEL self
-- @param #number minheight Minimum flight height to be detected, in meters AGL (above ground) -- @param #number minheight (Optional) Minimum flight height to be detected, in meters AGL (above ground). Defaults to 250m.
-- @param #number thresheight Threshold to escape the radar if flying below minheight, defaults to 90 (90% escape chance) -- @param #number thresheight (Optional) Threshold to escape the radar if flying below minheight, defaults to 90 (90% escape chance)
-- @param #number thresblur Threshold to be detected by the radar overall, defaults to 85 (85% chance to be found) -- @param #number thresblur (Optional) Threshold to be detected by the radar overall, defaults to 85 (85% chance to be found)
-- @param #number closing Closing-in in km - the limit of km from which on it becomes increasingly difficult to escape radar detection if flying towards the radar position. Should be about 1/3 of the radar detection radius in kilometers, defaults to 20. -- @param #number closing (Optional) Closing-in in km - the limit of km from which on it becomes increasingly difficult to escape radar detection if flying towards the radar position. Should be about 1/3 of the radar detection radius in kilometers, defaults to 20.
-- @return #INTEL self -- @return #INTEL self
function INTEL:SetRadarBlur(minheight,thresheight,thresblur,closing) function INTEL:SetRadarBlur(minheight,thresheight,thresblur,closing)
self.RadarBlur = true self.RadarBlur = true
@@ -737,7 +737,7 @@ end
--- Change radius of the Clusters. --- Change radius of the Clusters.
-- @param #INTEL self -- @param #INTEL self
-- @param #number radius The radius of the clusters in kilometers. Default 15 km. -- @param #number radius (Optional) The radius of the clusters in kilometers. Default 15 km.
-- @return #INTEL self -- @return #INTEL self
function INTEL:SetClusterRadius(radius) function INTEL:SetClusterRadius(radius)
self.clusterradius = (radius or 15)*1000 self.clusterradius = (radius or 15)*1000
@@ -1445,7 +1445,7 @@ end
-- @param #INTEL self -- @param #INTEL self
-- @param Wrapper.Positionable#POSITIONABLE Positionable Group or static object. -- @param Wrapper.Positionable#POSITIONABLE Positionable Group or static object.
-- @param #string RecceName Name of the recce group that detected this object. -- @param #string RecceName Name of the recce group that detected this object.
-- @param #number Tdetected Abs. mission time in seconds, when the object is detected. Default now. -- @param #number Tdetected (Optional) Abs. mission time in seconds, when the object is detected. Default now.
-- @return #INTEL self -- @return #INTEL self
function INTEL:KnowObject(Positionable, RecceName, Tdetected) function INTEL:KnowObject(Positionable, RecceName, Tdetected)
@@ -2016,7 +2016,7 @@ end
--- Calculate cluster future position after given seconds. --- Calculate cluster future position after given seconds.
-- @param #INTEL self -- @param #INTEL self
-- @param #INTEL.Cluster cluster The cluster of contacts. -- @param #INTEL.Cluster cluster The cluster of contacts.
-- @param #number seconds Time interval in seconds. Default is `self.prediction`. -- @param #number seconds (Optional) Time interval in seconds. Default is `self.prediction`.
-- @return Core.Point#COORDINATE Calculated future position of the cluster. -- @return Core.Point#COORDINATE Calculated future position of the cluster.
function INTEL:CalcClusterFuturePosition(cluster, seconds) function INTEL:CalcClusterFuturePosition(cluster, seconds)
@@ -2258,7 +2258,7 @@ end
--- Get the coordinate of a cluster. --- Get the coordinate of a cluster.
-- @param #INTEL self -- @param #INTEL self
-- @param #INTEL.Cluster Cluster The cluster. -- @param #INTEL.Cluster Cluster The cluster.
-- @param #boolean Update If `true`, update the coordinate. Default is to just return the last stored position. -- @param #boolean Update (Optional) If `true`, update the coordinate. Default is to just return the last stored position.
-- @return Core.Point#COORDINATE The coordinate of this cluster. -- @return Core.Point#COORDINATE The coordinate of this cluster.
function INTEL:GetClusterCoordinate(Cluster, Update) function INTEL:GetClusterCoordinate(Cluster, Update)
@@ -2309,8 +2309,8 @@ end
--- Check if the coordindate of the cluster changed. --- Check if the coordindate of the cluster changed.
-- @param #INTEL self -- @param #INTEL self
-- @param #INTEL.Cluster Cluster The cluster. -- @param #INTEL.Cluster Cluster The cluster.
-- @param #number Threshold in meters. Default 100 m. -- @param #number (Optional) Threshold in meters. Default 100 m.
-- @param Core.Point#COORDINATE Coordinate Reference coordinate. Default is the last known coordinate of the cluster. -- @param Core.Point#COORDINATE Coordinate (Optional) Reference coordinate. Default is the last known coordinate of the cluster.
-- @return #boolean If `true`, the coordinate changed by more than the given threshold. -- @return #boolean If `true`, the coordinate changed by more than the given threshold.
function INTEL:_CheckClusterCoordinateChanged(Cluster, Coordinate, Threshold) function INTEL:_CheckClusterCoordinateChanged(Cluster, Coordinate, Threshold)
@@ -2641,7 +2641,7 @@ end
--- Function to set how long INTEL DLINK remembers contacts. --- Function to set how long INTEL DLINK remembers contacts.
-- @param #INTEL_DLINK self -- @param #INTEL_DLINK self
-- @param #number seconds Remember this many seconds. Defaults to 180. -- @param #number seconds (Optional) Remember this many seconds. Defaults to 120.
-- @return #INTEL_DLINK self -- @return #INTEL_DLINK self
function INTEL_DLINK:SetDLinkCacheTime(seconds) function INTEL_DLINK:SetDLinkCacheTime(seconds)
self.cachetime = math.abs(seconds or 120) self.cachetime = math.abs(seconds or 120)
+12 -12
View File
@@ -316,7 +316,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #LEGION self -- @param #LEGION self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #LEGION self -- @return #LEGION self
function LEGION:SetVerbosity(VerbosityLevel) function LEGION:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -468,10 +468,10 @@ end
-- @param #LEGION self -- @param #LEGION self
-- @param Ops.Cohort#COHORT Cohort The cohort to be relocated. -- @param Ops.Cohort#COHORT Cohort The cohort to be relocated.
-- @param Ops.Legion#LEGION Legion The legion where the cohort is relocated to. -- @param Ops.Legion#LEGION Legion The legion where the cohort is relocated to.
-- @param #number Delay Delay in seconds before relocation takes place. Default `nil`, *i.e.* ASAP. -- @param #number Delay (Optional) Delay in seconds before relocation takes place. Default `nil`, *i.e.* ASAP.
-- @param #number NcarriersMin Min number of transport carriers in case the troops should be transported. Default `nil` for no transport. -- @param #number NcarriersMin (Optional) Min number of transport carriers in case the troops should be transported. Default `nil` for no transport.
-- @param #number NcarriersMax Max number of transport carriers. -- @param #number NcarriersMax Max number of transport carriers.
-- @param #table TransportLegions Legion(s) assigned for transportation. Default is that transport assets can only be recruited from this legion. -- @param #table TransportLegions (Optional) Legion(s) assigned for transportation. Default is that transport assets can only be recruited from this legion.
-- @return #LEGION self -- @return #LEGION self
function LEGION:RelocateCohort(Cohort, Legion, Delay, NcarriersMin, NcarriersMax, TransportLegions) function LEGION:RelocateCohort(Cohort, Legion, Delay, NcarriersMin, NcarriersMax, TransportLegions)
@@ -1927,7 +1927,7 @@ end
--- Check if an asset is currently on a mission (STARTED or EXECUTING). --- Check if an asset is currently on a mission (STARTED or EXECUTING).
-- @param #LEGION self -- @param #LEGION self
-- @param Functional.Warehouse#WAREHOUSE.Assetitem asset The asset. -- @param Functional.Warehouse#WAREHOUSE.Assetitem asset The asset.
-- @param #table MissionTypes Types on mission to be checked. Default all. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default all.
-- @return #boolean If true, asset has at least one mission of that type in the queue. -- @return #boolean If true, asset has at least one mission of that type in the queue.
function LEGION:IsAssetOnMission(asset, MissionTypes) function LEGION:IsAssetOnMission(asset, MissionTypes)
@@ -1980,7 +1980,7 @@ end
--- Count payloads in stock. --- Count payloads in stock.
-- @param #LEGION self -- @param #LEGION self
-- @param #table MissionTypes Types on mission to be checked. Default *all* possible types `AUFTRAG.Type`. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default *all* possible types `AUFTRAG.Type`.
-- @param #table UnitTypes Types of units. -- @param #table UnitTypes Types of units.
-- @param #table Payloads Specific payloads to be counted only. -- @param #table Payloads Specific payloads to be counted only.
-- @return #number Count of available payloads in stock. -- @return #number Count of available payloads in stock.
@@ -2056,7 +2056,7 @@ end
--- Count missions in mission queue. --- Count missions in mission queue.
-- @param #LEGION self -- @param #LEGION self
-- @param #table MissionTypes Types on mission to be checked. Default *all* possible types `AUFTRAG.Type`. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default *all* possible types `AUFTRAG.Type`.
-- @param #boolean OnlyRunning If `true`, only count running missions. -- @param #boolean OnlyRunning If `true`, only count running missions.
-- @return #number Number of missions that are not over yet. -- @return #number Number of missions that are not over yet.
function LEGION:CountMissionsInQueue(MissionTypes, OnlyRunning) function LEGION:CountMissionsInQueue(MissionTypes, OnlyRunning)
@@ -2171,8 +2171,8 @@ end
--- Count assets on mission. --- Count assets on mission.
-- @param #LEGION self -- @param #LEGION self
-- @param #table MissionTypes Types on mission to be checked. Default all. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default all.
-- @param Ops.Cohort#COHORT Cohort Only count assets of this cohort. Default count assets of all cohorts. -- @param Ops.Cohort#COHORT Cohort (Optional) Only count assets of this cohort. Default count assets of all cohorts.
-- @return #number Number of pending and queued assets. -- @return #number Number of pending and queued assets.
-- @return #number Number of pending assets. -- @return #number Number of pending assets.
-- @return #number Number of queued assets. -- @return #number Number of queued assets.
@@ -2215,7 +2215,7 @@ end
--- Get assets on mission. --- Get assets on mission.
-- @param #LEGION self -- @param #LEGION self
-- @param #table MissionTypes Types on mission to be checked. Default all. -- @param #table MissionTypes (Optional) Types on mission to be checked. Default all.
-- @return #table Assets on pending requests. -- @return #table Assets on pending requests.
function LEGION:GetAssetsOnMission(MissionTypes) function LEGION:GetAssetsOnMission(MissionTypes)
@@ -2248,7 +2248,7 @@ end
--- Get the unit types of this legion. These are the unit types of all assigned cohorts. --- Get the unit types of this legion. These are the unit types of all assigned cohorts.
-- @param #LEGION self -- @param #LEGION self
-- @param #boolean onlyactive Count only the active ones. -- @param #boolean onlyactive Count only the active ones.
-- @param #table cohorts Table of cohorts. Default all. -- @param #table cohorts (Optional) Table of cohorts. Default all.
-- @return #table Table of unit types. -- @return #table Table of unit types.
function LEGION:GetAircraftTypes(onlyactive, cohorts) function LEGION:GetAircraftTypes(onlyactive, cohorts)
@@ -2789,7 +2789,7 @@ end
--- Recruit assets from Cohorts for the given parameters. **NOTE** that we set the `asset.isReserved=true` flag so it cannot be recruited by anyone else. --- Recruit assets from Cohorts for the given parameters. **NOTE** that we set the `asset.isReserved=true` flag so it cannot be recruited by anyone else.
-- @param #table Cohorts Cohorts included. -- @param #table Cohorts Cohorts included.
-- @param #string MissionTypeRecruit Mission type for recruiting the cohort assets. -- @param #string MissionTypeRecruit Mission type for recruiting the cohort assets.
-- @param #string MissionTypeOpt Mission type for which the assets are optimized. Default is the same as `MissionTypeRecruit`. -- @param #string MissionTypeOpt (Optional) Mission type for which the assets are optimized. Default is the same as `MissionTypeRecruit`.
-- @param #number NreqMin Minimum number of required assets. -- @param #number NreqMin Minimum number of required assets.
-- @param #number NreqMax Maximum number of required assets. -- @param #number NreqMax Maximum number of required assets.
-- @param DCS#Vec2 TargetVec2 Target position as 2D vector. -- @param DCS#Vec2 TargetVec2 Target position as 2D vector.
+34 -34
View File
@@ -434,7 +434,7 @@ end
--- Enable/disable pathfinding. --- Enable/disable pathfinding.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #boolean Switch If true, enable pathfinding. -- @param #boolean Switch If true, enable pathfinding.
-- @param #number CorridorWidth Corridor with in meters. Default 400 m. -- @param #number CorridorWidth (Optional) Corridor with in meters. Default 400 m.
-- @return #NAVYGROUP self -- @return #NAVYGROUP self
function NAVYGROUP:SetPathfinding(Switch, CorridorWidth) function NAVYGROUP:SetPathfinding(Switch, CorridorWidth)
self.pathfindingOn=Switch self.pathfindingOn=Switch
@@ -444,7 +444,7 @@ end
--- Enable pathfinding. --- Enable pathfinding.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #number CorridorWidth Corridor with in meters. Default 400 m. -- @param #number CorridorWidth (Optional) Corridor with in meters. Default 400 m.
-- @return #NAVYGROUP self -- @return #NAVYGROUP self
function NAVYGROUP:SetPathfindingOn(CorridorWidth) function NAVYGROUP:SetPathfindingOn(CorridorWidth)
self:SetPathfinding(true, CorridorWidth) self:SetPathfinding(true, CorridorWidth)
@@ -476,9 +476,9 @@ end
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param Core.Point#COORDINATE Coordinate Coordinate of the target. -- @param Core.Point#COORDINATE Coordinate Coordinate of the target.
-- @param #string Clock Time when to start the attack. -- @param #string Clock Time when to start the attack.
-- @param #number Radius Radius in meters. Default 100 m. -- @param #number Radius (Optional) Radius in meters. Default 100 m.
-- @param #number Nshots Number of shots to fire. Default 3. -- @param #number Nshots (Optional) Number of shots to fire. Default 3.
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #number Prio Priority of the task. -- @param #number Prio Priority of the task.
-- @return Ops.OpsGroup#OPSGROUP.Task The task data. -- @return Ops.OpsGroup#OPSGROUP.Task The task data.
function NAVYGROUP:AddTaskFireAtPoint(Coordinate, Clock, Radius, Nshots, WeaponType, Prio) function NAVYGROUP:AddTaskFireAtPoint(Coordinate, Clock, Radius, Nshots, WeaponType, Prio)
@@ -493,12 +493,12 @@ end
--- Add a *waypoint* task. --- Add a *waypoint* task.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param Core.Point#COORDINATE Coordinate Coordinate of the target. -- @param Core.Point#COORDINATE Coordinate Coordinate of the target.
-- @param Ops.OpsGroup#OPSGROUP.Waypoint Waypoint Where the task is executed. Default is next waypoint. -- @param Ops.OpsGroup#OPSGROUP.Waypoint (Optional) Waypoint Where the task is executed. Default is next waypoint.
-- @param #number Radius Radius in meters. Default 100 m. -- @param #number Radius (Optional) Radius in meters. Default 100 m.
-- @param #number Nshots Number of shots to fire. Default 3. -- @param #number Nshots (Optional) Number of shots to fire. Default 3.
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #number Prio Priority of the task. -- @param #number Prio (Optional) Priority of the task. Defaults to 50.
-- @param #number Duration Duration in seconds after which the task is cancelled. Default *never*. -- @param #number Duration (Optional) Duration in seconds after which the task is cancelled. Default *never*.
-- @return Ops.OpsGroup#OPSGROUP.Task The task table. -- @return Ops.OpsGroup#OPSGROUP.Task The task table.
function NAVYGROUP:AddTaskWaypointFireAtPoint(Coordinate, Waypoint, Radius, Nshots, WeaponType, Prio, Duration) function NAVYGROUP:AddTaskWaypointFireAtPoint(Coordinate, Waypoint, Radius, Nshots, WeaponType, Prio, Duration)
@@ -515,10 +515,10 @@ end
--- Add a *scheduled* task. --- Add a *scheduled* task.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param Wrapper.Group#GROUP TargetGroup Target group. -- @param Wrapper.Group#GROUP TargetGroup Target group.
-- @param #number WeaponExpend How much weapons does are used. -- @param #number WeaponExpend (Optional) How much weapons does are used.
-- @param #number WeaponType Type of weapon. Default auto. -- @param #number WeaponType (Optional) Type of weapon. Default auto.
-- @param #string Clock Time when to start the attack. -- @param #string Clock (Optional) Time when to start the attack.
-- @param #number Prio Priority of the task. -- @param #number Prio (Optional) Priority of the task. Defaults to 50.
-- @return Ops.OpsGroup#OPSGROUP.Task The task data. -- @return Ops.OpsGroup#OPSGROUP.Task The task data.
function NAVYGROUP:AddTaskAttackGroup(TargetGroup, WeaponExpend, WeaponType, Clock, Prio) function NAVYGROUP:AddTaskAttackGroup(TargetGroup, WeaponExpend, WeaponType, Clock, Prio)
@@ -531,11 +531,11 @@ end
--- Create a turn into wind window. Note that this is not executed as it not added to the queue. --- Create a turn into wind window. Note that this is not executed as it not added to the queue.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #string starttime Start time, e.g. "8:00" for eight o'clock. Default now. -- @param #string starttime (Optional) Start time, e.g. "8:00" for eight o'clock. Default now.
-- @param #string stoptime Stop time, e.g. "9:00" for nine o'clock. Default 90 minutes after start time. -- @param #string stoptime (Optional) Stop time, e.g. "9:00" for nine o'clock. Default 90 minutes after start time.
-- @param #number speed Speed in knots during turn into wind leg. -- @param #number speed (Optional) Speed in knots during turn into wind leg. Defaults to 20.
-- @param #boolean uturn If true (or nil), carrier wil perform a U-turn and go back to where it came from before resuming its route to the next waypoint. If false, it will go directly to the next waypoint. -- @param #boolean uturn (Optional) If true (or nil), carrier wil perform a U-turn and go back to where it came from before resuming its route to the next waypoint. If false, it will go directly to the next waypoint.
-- @param #number offset Offset angle in degrees, e.g. to account for an angled runway. Default 0 deg. -- @param #number offset (Optional) Offset angle in degrees, e.g. to account for an angled runway. Default 0 deg.
-- @return #NAVYGROUP.IntoWind Recovery window. -- @return #NAVYGROUP.IntoWind Recovery window.
function NAVYGROUP:_CreateTurnIntoWind(starttime, stoptime, speed, uturn, offset) function NAVYGROUP:_CreateTurnIntoWind(starttime, stoptime, speed, uturn, offset)
@@ -598,11 +598,11 @@ end
--- Add a time window, where the groups steams into the wind. --- Add a time window, where the groups steams into the wind.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #string starttime Start time, e.g. "8:00" for eight o'clock. Default now. -- @param #string starttime (Optional) Start time, e.g. "8:00" for eight o'clock. Default now.
-- @param #string stoptime Stop time, e.g. "9:00" for nine o'clock. Default 90 minutes after start time. -- @param #string stoptime (Optional) Stop time, e.g. "9:00" for nine o'clock. Default 90 minutes after start time.
-- @param #number speed Wind speed on deck in knots during turn into wind leg. Default 20 knots. -- @param #number speed (Optional) Wind speed on deck in knots during turn into wind leg. Default 20 knots.
-- @param #boolean uturn If `true` (or `nil`), carrier wil perform a U-turn and go back to where it came from before resuming its route to the next waypoint. If false, it will go directly to the next waypoint. -- @param #boolean uturn (Optional) If `true` (or `nil`), carrier wil perform a U-turn and go back to where it came from before resuming its route to the next waypoint. If false, it will go directly to the next waypoint.
-- @param #number offset Offset angle clock-wise in degrees, *e.g.* to account for an angled runway. Default 0 deg. Use around -9.1° for US carriers. -- @param #number offset (Optional) Offset angle clock-wise in degrees, *e.g.* to account for an angled runway. Default 0 deg. Use around -9.1° for US carriers.
-- @return #NAVYGROUP.IntoWind Turn into window data table. -- @return #NAVYGROUP.IntoWind Turn into window data table.
function NAVYGROUP:AddTurnIntoWind(starttime, stoptime, speed, uturn, offset) function NAVYGROUP:AddTurnIntoWind(starttime, stoptime, speed, uturn, offset)
@@ -644,7 +644,7 @@ end
--- Extend duration of turn into wind. --- Extend duration of turn into wind.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #number Duration Duration in seconds. Default 300 sec. -- @param #number Duration (Optional) Duration in seconds. Default 300 sec.
-- @param #NAVYGROUP.IntoWind TurnIntoWind (Optional) Turn into window data table. If not given, the currently open one is used (if there is any). -- @param #NAVYGROUP.IntoWind TurnIntoWind (Optional) Turn into window data table. If not given, the currently open one is used (if there is any).
-- @return #NAVYGROUP self -- @return #NAVYGROUP self
function NAVYGROUP:ExtendTurnIntoWind(Duration, TurnIntoWind) function NAVYGROUP:ExtendTurnIntoWind(Duration, TurnIntoWind)
@@ -1832,10 +1832,10 @@ end
--- Add an a waypoint to the route. --- Add an a waypoint to the route.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param Core.Point#COORDINATE Coordinate The coordinate of the waypoint. Use `COORDINATE:SetAltitude()` to define the altitude. -- @param Core.Point#COORDINATE Coordinate The coordinate of the waypoint. Use `COORDINATE:SetAltitude()` to define the altitude.
-- @param #number Speed Speed in knots. Default is default cruise speed or 70% of max speed. -- @param #number Speed (Optional) Speed in knots. Default is default cruise speed or 70% of max speed.
-- @param #number AfterWaypointWithID Insert waypoint after waypoint given ID. Default is to insert as last waypoint. -- @param #number AfterWaypointWithID (Optional) Insert waypoint after waypoint given ID. Default is to insert as last waypoint.
-- @param #number Depth Depth at waypoint in feet. Only for submarines. -- @param #number Depth (Optional) Depth at waypoint in feet. Only for submarines.
-- @param #boolean Updateroute If true or nil, call UpdateRoute. If false, no call. -- @param #boolean Updateroute (Optional) If true or nil, call UpdateRoute. If false, no call.
-- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table. -- @return Ops.OpsGroup#OPSGROUP.Waypoint Waypoint table.
function NAVYGROUP:AddWaypoint(Coordinate, Speed, AfterWaypointWithID, Depth, Updateroute) function NAVYGROUP:AddWaypoint(Coordinate, Speed, AfterWaypointWithID, Depth, Updateroute)
@@ -1875,8 +1875,8 @@ end
--- Initialize group parameters. Also initializes waypoints if self.waypoints is nil. --- Initialize group parameters. Also initializes waypoints if self.waypoints is nil.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #table Template Template used to init the group. Default is `self.template`. -- @param #table Template (Optional) Template used to init the group. Default is `self.template`.
-- @param #number Delay Delay in seconds before group is initialized. Default `nil`, *i.e.* instantaneous. -- @param #number Delay (Optional) Delay in seconds before group is initialized. Default `nil`, *i.e.* instantaneous.
-- @return #NAVYGROUP self -- @return #NAVYGROUP self
function NAVYGROUP:_InitGroup(Template, Delay) function NAVYGROUP:_InitGroup(Template, Delay)
@@ -1981,7 +1981,7 @@ end
--- Check for possible collisions between two coordinates. --- Check for possible collisions between two coordinates.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #number DistanceMax Max distance in meters ahead to check. Default 5000. -- @param #number DistanceMax (Optional) Max distance in meters ahead to check. Default 5000.
-- @param #number dx -- @param #number dx
-- @return #number Free distance in meters. -- @return #number Free distance in meters.
function NAVYGROUP:_CheckFreePath(DistanceMax, dx) function NAVYGROUP:_CheckFreePath(DistanceMax, dx)
@@ -2167,7 +2167,7 @@ end
--- Get wind direction and speed at current position. --- Get wind direction and speed at current position.
-- @param #NAVYGROUP self -- @param #NAVYGROUP self
-- @param #number Altitude Altitude in meters above main sea level at which the wind is calculated. Default 18 meters. -- @param #number Altitude (Optional) Altitude in meters above main sea level at which the wind is calculated. Default 18 meters.
-- @return #number Direction the wind is blowing **from** in degrees. -- @return #number Direction the wind is blowing **from** in degrees.
-- @return #number Wind speed in m/s. -- @return #number Wind speed in m/s.
function NAVYGROUP:GetWind(Altitude) function NAVYGROUP:GetWind(Altitude)
+12 -12
View File
@@ -145,7 +145,7 @@ OPERATION.version="0.2.0"
--- Create a new generic OPERATION object. --- Create a new generic OPERATION object.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #string Name Name of the operation. Be creative! Default "Operation-01" where the last number is a running number. -- @param #string Name (Optional) Name of the operation. Be creative! Default "Operation-01" where the last number is a running number.
-- @return #OPERATION self -- @return #OPERATION self
function OPERATION:New(Name) function OPERATION:New(Name)
@@ -349,7 +349,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #OPERATION self -- @return #OPERATION self
function OPERATION:SetVerbosity(VerbosityLevel) function OPERATION:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -358,7 +358,7 @@ end
--- Set start and stop time of the operation. --- Set start and stop time of the operation.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #string ClockStart Time the mission is started, e.g. "05:00" for 5 am. If specified as a #number, it will be relative (in seconds) to the current mission time. Default is 5 seconds after mission was added. -- @param #string ClockStart (Optional) Time the mission is started, e.g. "05:00" for 5 am. If specified as a #number, it will be relative (in seconds) to the current mission time. Default is 5 seconds after mission was added.
-- @param #string ClockStop (Optional) Time the mission is stopped, e.g. "13:00" for 1 pm. If mission could not be started at that time, it will be removed from the queue. If specified as a #number it will be relative (in seconds) to the current mission time. -- @param #string ClockStop (Optional) Time the mission is stopped, e.g. "13:00" for 1 pm. If mission could not be started at that time, it will be removed from the queue. If specified as a #number it will be relative (in seconds) to the current mission time.
-- @return #OPERATION self -- @return #OPERATION self
function OPERATION:SetTime(ClockStart, ClockStop) function OPERATION:SetTime(ClockStart, ClockStop)
@@ -415,9 +415,9 @@ end
--- Add a new phase to the operation. This is added add the end of all previously added phases (if any). --- Add a new phase to the operation. This is added add the end of all previously added phases (if any).
-- @param #OPERATION self -- @param #OPERATION self
-- @param #string Name Name of the phase. Default "Phase-01" where the last number is a running number. -- @param #string Name (Optional) Name of the phase. Default "Phase-01" where the last number is a running number.
-- @param #OPERATION.Branch Branch The branch to which this phase is added. Default is the master branch. -- @param #OPERATION.Branch Branch (Optional) The branch to which this phase is added. Default is the master branch.
-- @param #number Duration Duration in seconds how long the phase will last. Default `nil`=forever. -- @param #number Duration (Optional) Duration in seconds how long the phase will last. Default `nil`=forever.
-- @return #OPERATION.Phase Phase table object. -- @return #OPERATION.Phase Phase table object.
function OPERATION:AddPhase(Name, Branch, Duration) function OPERATION:AddPhase(Name, Branch, Duration)
@@ -445,7 +445,7 @@ end
---Insert a new phase after an already defined phase of the operation. ---Insert a new phase after an already defined phase of the operation.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #OPERATION.Phase PhaseAfter The phase after which the new phase is inserted. -- @param #OPERATION.Phase PhaseAfter The phase after which the new phase is inserted.
-- @param #string Name Name of the phase. Default "Phase-01" where the last number is a running number. -- @param #string Name (Optional) Name of the phase. Default "Phase-01" where the last number is a running number.
-- @return #OPERATION.Phase Phase table object. -- @return #OPERATION.Phase Phase table object.
function OPERATION:InsertPhaseAfter(PhaseAfter, Name) function OPERATION:InsertPhaseAfter(PhaseAfter, Name)
@@ -472,7 +472,7 @@ end
--- Get a phase by its name. --- Get a phase by its name.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #string Name Name of the phase. Default "Phase-01" where the last number is a running number. -- @param #string Name (Optional) Name of the phase. Default "Phase-01" where the last number is a running number.
-- @return #OPERATION.Phase Phase table object or nil if phase could not be found. -- @return #OPERATION.Phase Phase table object or nil if phase could not be found.
function OPERATION:GetPhaseByName(Name) function OPERATION:GetPhaseByName(Name)
@@ -610,7 +610,7 @@ end
--- Get name of a phase. --- Get name of a phase.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #OPERATION.Phase Phase The phase of which the name is returned. Default is the currently active phase. -- @param #OPERATION.Phase Phase (Optional) The phase of which the name is returned. Default is the currently active phase.
-- @return #string The name of the phase or "None" if no phase is given or active. -- @return #string The name of the phase or "None" if no phase is given or active.
function OPERATION:GetPhaseName(Phase) function OPERATION:GetPhaseName(Phase)
@@ -752,7 +752,7 @@ end
--- Get name of the branch. --- Get name of the branch.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #OPERATION.Branch Branch The branch of which the name is requested. Default is the currently active or master branch. -- @param #OPERATION.Branch (Optional) Branch The branch of which the name is requested. Default is the currently active or master branch.
-- @return #string Name Name or "None" -- @return #string Name Name or "None"
function OPERATION:GetBranchName(Branch) function OPERATION:GetBranchName(Branch)
Branch=Branch or self:GetBranchActive() Branch=Branch or self:GetBranchActive()
@@ -1336,7 +1336,7 @@ end
--- Create a new phase object. --- Create a new phase object.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #string Name Name of the phase. Default "Phase-01" where the last number is a running number. -- @param #string Name (Optional) Name of the phase. Default "Phase-01" where the last number is a running number.
-- @return #OPERATION.Phase Phase table object. -- @return #OPERATION.Phase Phase table object.
function OPERATION:_CreatePhase(Name) function OPERATION:_CreatePhase(Name)
@@ -1356,7 +1356,7 @@ end
--- Create a new branch object. --- Create a new branch object.
-- @param #OPERATION self -- @param #OPERATION self
-- @param #string Name Name of the phase. Default "Phase-01" where the last number is a running number. -- @param #string Name (Optional) Name of the phase. Default "Phase-01" where the last number is a running number.
-- @return #OPERATION.Branch Branch table object. -- @return #OPERATION.Branch Branch table object.
function OPERATION:_CreateBranch(Name) function OPERATION:_CreateBranch(Name)
+137 -137
View File
@@ -514,7 +514,7 @@ OPSGROUP.CargoStatus={
--- OpsGroup version. --- OpsGroup version.
-- @field #string version -- @field #string version
OPSGROUP.version="1.0.5" OPSGROUP.version="1.0.6"
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- TODO list -- TODO list
@@ -1016,7 +1016,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetVerbosity(VerbosityLevel) function OPSGROUP:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -1068,7 +1068,7 @@ end
--- Set default cruise altitude. --- Set default cruise altitude.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Altitude Altitude in feet. Default is 10,000 ft for airplanes and 1,500 feet for helicopters. -- @param #number Altitude (Optional) Altitude in feet. Default is 10,000 ft for airplanes and 1,500 feet for helicopters.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultAltitude(Altitude) function OPSGROUP:SetDefaultAltitude(Altitude)
if Altitude then if Altitude then
@@ -1097,7 +1097,7 @@ end
--- Set current altitude. --- Set current altitude.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Altitude Altitude in feet. Default is 10,000 ft for airplanes and 1,500 feet for helicopters. -- @param #number Altitude (Optional) Altitude in feet. Default is 10,000 ft for airplanes and 1,500 feet for helicopters.
-- @param #boolean Keep If `true` the group will maintain that speed on passing waypoints. If `nil` or `false` the group will return to the speed as defined by their route. -- @param #boolean Keep If `true` the group will maintain that speed on passing waypoints. If `nil` or `false` the group will return to the speed as defined by their route.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetAltitude(Altitude, Keep, RadarAlt) function OPSGROUP:SetAltitude(Altitude, Keep, RadarAlt)
@@ -1147,7 +1147,7 @@ end
--- Set current speed. --- Set current speed.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Speed Speed in knots. Default is 70% of max speed. -- @param #number Speed (Optional) Speed in knots. Default is 70% of max speed.
-- @param #boolean Keep If `true` the group will maintain that speed on passing waypoints. If `nil` or `false` the group will return to the speed as defined by their route. -- @param #boolean Keep If `true` the group will maintain that speed on passing waypoints. If `nil` or `false` the group will return to the speed as defined by their route.
-- @param #boolean AltCorrected If `true`, use altitude corrected indicated air speed. -- @param #boolean AltCorrected If `true`, use altitude corrected indicated air speed.
-- @return #OPSGROUP self -- @return #OPSGROUP self
@@ -1176,7 +1176,7 @@ end
--- Set detection on or off. --- Set detection on or off.
-- If detection is on, detected targets of the group will be evaluated and FSM events triggered. -- If detection is on, detected targets of the group will be evaluated and FSM events triggered.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #boolean Switch If `true`, detection is on. If `false` or `nil`, detection is off. Default is off. -- @param #boolean Switch (Optional) If `true`, detection is on. If `false` or `nil`, detection is off. Default is off.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDetection(Switch) function OPSGROUP:SetDetection(Switch)
self:T(self.lid..string.format("Detection is %s", tostring(Switch))) self:T(self.lid..string.format("Detection is %s", tostring(Switch)))
@@ -1335,7 +1335,7 @@ end
-- @param Core.Point#COORDINATE TargetCoord Coordinate of the target. -- @param Core.Point#COORDINATE TargetCoord Coordinate of the target.
-- @param #number WeaponBitType Weapon type. -- @param #number WeaponBitType Weapon type.
-- @param Core.Point#COORDINATE RefCoord Reference coordinate. -- @param Core.Point#COORDINATE RefCoord Reference coordinate.
-- @param #table SurfaceTypes Valid surfaces types of the coordinate. Default any (nil). -- @param #table SurfaceTypes (Optional) Valid surfaces types of the coordinate. Default any (nil).
-- @return Core.Point#COORDINATE Coordinate in weapon range -- @return Core.Point#COORDINATE Coordinate in weapon range
function OPSGROUP:GetCoordinateInRange(TargetCoord, WeaponBitType, RefCoord, SurfaceTypes) function OPSGROUP:GetCoordinateInRange(TargetCoord, WeaponBitType, RefCoord, SurfaceTypes)
@@ -1411,10 +1411,10 @@ end
--- Set LASER parameters. --- Set LASER parameters.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Code Laser code. Default 1688. -- @param #number Code (Optional) Laser code. Default 1688.
-- @param #boolean CheckLOS Check if lasing unit has line of sight to target coordinate. Default is `true`. -- @param #boolean CheckLOS (Optional) Check if lasing unit has line of sight to target coordinate. Default is `true`.
-- @param #boolean IROff If true, then dont switch on the additional IR pointer. -- @param #boolean IROff If true, then dont switch on the additional IR pointer.
-- @param #number UpdateTime Time interval in seconds the beam gets up for moving targets. Default every 0.5 sec. -- @param #number UpdateTime (Optional) Time interval in seconds the beam gets up for moving targets. Default every 0.5 sec.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetLaser(Code, CheckLOS, IROff, UpdateTime) function OPSGROUP:SetLaser(Code, CheckLOS, IROff, UpdateTime)
self.spot.Code=Code or 1688 self.spot.Code=Code or 1688
@@ -1473,10 +1473,10 @@ end
--- Add a weapon range for ARTY auftrag. --- Add a weapon range for ARTY auftrag.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number RangeMin Minimum range in nautical miles. Default 0 NM. -- @param #number RangeMin (Optional) Minimum range in nautical miles. Default 0 NM.
-- @param #number RangeMax Maximum range in nautical miles. Default 10 NM. -- @param #number RangeMax (Optional) Maximum range in nautical miles. Default 10 NM.
-- @param #number BitType Bit mask of weapon type for which the given min/max ranges apply. Default is `ENUMS.WeaponFlag.Auto`, i.e. for all weapon types. -- @param #number BitType (Optional) Bit mask of weapon type for which the given min/max ranges apply. Default is `ENUMS.WeaponFlag.Auto`, i.e. for all weapon types.
-- @param #function ConversionToMeters Function that converts input units of ranges to meters. Defaul `UTILS.NMToMeters`. -- @param #function ConversionToMeters (Optional) Function that converts input units of ranges to meters. Defaul `UTILS.NMToMeters`.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:AddWeaponRange(RangeMin, RangeMax, BitType, ConversionToMeters) function OPSGROUP:AddWeaponRange(RangeMin, RangeMax, BitType, ConversionToMeters)
@@ -1536,8 +1536,8 @@ end
--- Get highest detected threat. Detection must be turned on. The threat level is a number between 0 and 10, where 0 is the lowest, e.g. unarmed units. --- Get highest detected threat. Detection must be turned on. The threat level is a number between 0 and 10, where 0 is the lowest, e.g. unarmed units.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number ThreatLevelMin Only consider threats with level greater or equal to this number. Default 1 (so unarmed units wont be considered). -- @param #number ThreatLevelMin (Optional) Only consider threats with level greater or equal to this number. Default 1 (so unarmed units wont be considered).
-- @param #number ThreatLevelMax Only consider threats with level smaller or queal to this number. Default 10. -- @param #number ThreatLevelMax (Optional) Only consider threats with level smaller or queal to this number. Default 10.
-- @return Wrapper.Unit#UNIT Highest threat unit detected by the group or `nil` if no threat is currently detected. -- @return Wrapper.Unit#UNIT Highest threat unit detected by the group or `nil` if no threat is currently detected.
-- @return #number Threat level. -- @return #number Threat level.
function OPSGROUP:GetThreat(ThreatLevelMin, ThreatLevelMax) function OPSGROUP:GetThreat(ThreatLevelMin, ThreatLevelMax)
@@ -1593,10 +1593,10 @@ end
--- Enable to automatically engage detected targets. --- Enable to automatically engage detected targets.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number RangeMax Max range in NM. Only detected targets within this radius from the group will be engaged. Default is 25 NM. -- @param #number RangeMax (Optional) Max range in NM. Only detected targets within this radius from the group will be engaged. Default is 25 NM.
-- @param #table TargetTypes Types of target attributes that will be engaged. See [DCS enum attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes). Default "All". -- @param #table TargetTypes (Optional) Types of target attributes that will be engaged. See [DCS enum attributes](https://wiki.hoggitworld.com/view/DCS_enum_attributes). Default "All".
-- @param Core.Set#SET_ZONE EngageZoneSet Set of zones in which targets are engaged. Default is anywhere. -- @param Core.Set#SET_ZONE EngageZoneSet (Optional) Set of zones in which targets are engaged. Default is anywhere.
-- @param Core.Set#SET_ZONE NoEngageZoneSet Set of zones in which targets are *not* engaged. Default is nowhere. -- @param Core.Set#SET_ZONE NoEngageZoneSet (Optional) Set of zones in which targets are *not* engaged. Default is nowhere.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetEngageDetectedOn(RangeMax, TargetTypes, EngageZoneSet, NoEngageZoneSet) function OPSGROUP:SetEngageDetectedOn(RangeMax, TargetTypes, EngageZoneSet, NoEngageZoneSet)
@@ -1783,7 +1783,7 @@ end
--- Get MOOSE UNIT object. --- Get MOOSE UNIT object.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number UnitNumber Number of the unit in the group. Default first unit. -- @param #number UnitNumber (Optional) Number of the unit in the group. Default first unit.
-- @return Wrapper.Unit#UNIT The MOOSE UNIT object. -- @return Wrapper.Unit#UNIT The MOOSE UNIT object.
function OPSGROUP:GetUnit(UnitNumber) function OPSGROUP:GetUnit(UnitNumber)
@@ -1799,7 +1799,7 @@ end
--- Get DCS GROUP object. --- Get DCS GROUP object.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number UnitNumber Number of the unit in the group. Default first unit. -- @param #number UnitNumber (Optional) Number of the unit in the group. Default first unit.
-- @return DCS#Unit DCS group object. -- @return DCS#Unit DCS group object.
function OPSGROUP:GetDCSUnit(UnitNumber) function OPSGROUP:GetDCSUnit(UnitNumber)
@@ -2059,8 +2059,8 @@ end
--- Despawn a unit of the group. A "Remove Unit" event is generated by default. --- Despawn a unit of the group. A "Remove Unit" event is generated by default.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit -- @param #string UnitName Name of the unit
-- @param #number Delay Delay in seconds before the group will be despawned. Default immediately. -- @param #number Delay (Optional) Delay in seconds before the group will be despawned. Default immediately.
-- @param #boolean NoEventRemoveUnit If true, no event "Remove Unit" is generated. -- @param #boolean NoEventRemoveUnit (Optional) If true, no event "Remove Unit" is generated.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:DespawnUnit(UnitName, Delay, NoEventRemoveUnit) function OPSGROUP:DespawnUnit(UnitName, Delay, NoEventRemoveUnit)
@@ -2096,8 +2096,8 @@ end
--- Despawn an element/unit of the group. --- Despawn an element/unit of the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #OPSGROUP.Element Element The element that will be despawned. -- @param #OPSGROUP.Element Element The element that will be despawned.
-- @param #number Delay Delay in seconds before the element will be despawned. Default immediately. -- @param #number Delay (Optional) Delay in seconds before the element will be despawned. Default immediately.
-- @param #boolean NoEventRemoveUnit If true, no event "Remove Unit" is generated. -- @param #boolean NoEventRemoveUnit (Optional) If true, no event "Remove Unit" is generated.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:DespawnElement(Element, Delay, NoEventRemoveUnit) function OPSGROUP:DespawnElement(Element, Delay, NoEventRemoveUnit)
@@ -2133,7 +2133,7 @@ end
-- If no `Remove Unit` event should be generated, the second optional parameter needs to be set to `true`. -- If no `Remove Unit` event should be generated, the second optional parameter needs to be set to `true`.
-- If this group belongs to an AIRWING, BRIGADE or FLEET, it will be added to the warehouse stock if the `NoEventRemoveUnit` parameter is `false` or `nil`. -- If this group belongs to an AIRWING, BRIGADE or FLEET, it will be added to the warehouse stock if the `NoEventRemoveUnit` parameter is `false` or `nil`.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds before the group will be despawned. Default immediately. -- @param #number Delay (Optional) Delay in seconds before the group will be despawned. Default immediately.
-- @param #boolean NoEventRemoveUnit If `true`, **no** event "Remove Unit" is generated. -- @param #boolean NoEventRemoveUnit If `true`, **no** event "Remove Unit" is generated.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:Despawn(Delay, NoEventRemoveUnit) function OPSGROUP:Despawn(Delay, NoEventRemoveUnit)
@@ -2176,7 +2176,7 @@ end
--- Return group back to the legion it belongs to. --- Return group back to the legion it belongs to.
-- Group is despawned and added back to the stock. -- Group is despawned and added back to the stock.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds before the group will be despawned. Default immediately -- @param #number Delay (Optional) Delay in seconds before the group will be despawned. Default immediately
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:ReturnToLegion(Delay) function OPSGROUP:ReturnToLegion(Delay)
@@ -2200,7 +2200,7 @@ end
--- Destroy a unit of the group. A *Unit Lost* for aircraft or *Dead* event for ground/naval units is generated. --- Destroy a unit of the group. A *Unit Lost* for aircraft or *Dead* event for ground/naval units is generated.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit which should be destroyed. -- @param #string UnitName Name of the unit which should be destroyed.
-- @param #number Delay Delay in seconds before the group will be destroyed. Default immediately. -- @param #number Delay (Optional) Delay in seconds before the group will be destroyed. Default immediately.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:DestroyUnit(UnitName, Delay) function OPSGROUP:DestroyUnit(UnitName, Delay)
@@ -2232,7 +2232,7 @@ end
--- Destroy group. The whole group is despawned and a *Unit Lost* for aircraft or *Dead* event for ground/naval units is generated for all current units. --- Destroy group. The whole group is despawned and a *Unit Lost* for aircraft or *Dead* event for ground/naval units is generated for all current units.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds before the group will be destroyed. Default immediately. -- @param #number Delay (Optional) Delay in seconds before the group will be destroyed. Default immediately.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:Destroy(Delay) function OPSGROUP:Destroy(Delay)
@@ -2316,9 +2316,9 @@ end
--- Self destruction of group. An explosion is created at the position of each element. --- Self destruction of group. An explosion is created at the position of each element.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds. Default now. -- @param #number Delay (Optional) Delay in seconds. Default now.
-- @param #number ExplosionPower (Optional) Explosion power in kg TNT. Default 100 kg. -- @param #number ExplosionPower (Optional) Explosion power in kg TNT. Default 100 kg.
-- @param #string ElementName Name of the element that should be destroyed. Default is all elements. -- @param #string ElementName (Optional) Name of the element that should be destroyed. Default is all elements.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SelfDestruction(Delay, ExplosionPower, ElementName) function OPSGROUP:SelfDestruction(Delay, ExplosionPower, ElementName)
@@ -2348,13 +2348,13 @@ end
--- Use SRS Simple-Text-To-Speech for transmissions. --- Use SRS Simple-Text-To-Speech for transmissions.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string PathToSRS Path to SRS directory. -- @param #string PathToSRS Path to SRS directory.
-- @param #string Gender Gender: "male" or "female" (default). -- @param #string Gender (Optional) Gender: "male" or "female" (default).
-- @param #string Culture Culture, e.g. "en-GB" (default). -- @param #string Culture (Optional) Culture, e.g. "en-GB" (default).
-- @param #string Voice Specific voice. Overrides `Gender` and `Culture`. -- @param #string Voice (Optional) Specific voice. Overrides `Gender` and `Culture`.
-- @param #number Port SRS port. Default 5002. -- @param #number Port (Optional) SRS port. Default 5002.
-- @param #string PathToGoogleKey Full path to the google credentials JSON file, e.g. `"C:\Users\myUsername\Downloads\key.json"`. -- @param #string PathToGoogleKey (Optional) Full path to the google credentials JSON file, e.g. `"C:\Users\myUsername\Downloads\key.json"`.
-- @param #string Label Label of the SRS comms for the SRS Radio overlay. Defaults to "ROBOT". No spaces allowed! -- @param #string Label (Optional) Label of the SRS comms for the SRS Radio overlay. Defaults to "ROBOT". No spaces allowed!
-- @param #number Volume Volume to be set, 0.0 = silent, 1.0 = loudest. Defaults to 1.0 -- @param #number Volume (Optional) Volume to be set, 0.0 = silent, 1.0 = loudest. Defaults to 1.0
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetSRS(PathToSRS, Gender, Culture, Voice, Port, PathToGoogleKey, Label, Volume) function OPSGROUP:SetSRS(PathToSRS, Gender, Culture, Voice, Port, PathToGoogleKey, Label, Volume)
self.useSRS=true self.useSRS=true
@@ -2379,8 +2379,8 @@ end
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string Text Text of transmission. -- @param #string Text Text of transmission.
-- @param #number Delay Delay in seconds before the transmission is started. -- @param #number Delay Delay in seconds before the transmission is started.
-- @param #boolean SayCallsign If `true`, the callsign is prepended to the given text. Default `false`. -- @param #boolean SayCallsign (Optional) If `true`, the callsign is prepended to the given text. Default `false`.
-- @param #number Frequency Override sender frequency, helpful when you need multiple radios from the same sender. Default is the frequency set for the OpsGroup. -- @param #number Frequency (Optional) Override sender frequency, helpful when you need multiple radios from the same sender. Default is the frequency set for the OpsGroup.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:RadioTransmission(Text, Delay, SayCallsign, Frequency) function OPSGROUP:RadioTransmission(Text, Delay, SayCallsign, Frequency)
@@ -2421,8 +2421,8 @@ end
--- Set that this carrier is an all aspect loader. --- Set that this carrier is an all aspect loader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierLoaderAllAspect(Length, Width) function OPSGROUP:SetCarrierLoaderAllAspect(Length, Width)
self.carrierLoader.type="front" self.carrierLoader.type="front"
@@ -2433,8 +2433,8 @@ end
--- Set that this carrier is a front loader. --- Set that this carrier is a front loader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierLoaderFront(Length, Width) function OPSGROUP:SetCarrierLoaderFront(Length, Width)
self.carrierLoader.type="front" self.carrierLoader.type="front"
@@ -2445,8 +2445,8 @@ end
--- Set that this carrier is a back loader. --- Set that this carrier is a back loader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierLoaderBack(Length, Width) function OPSGROUP:SetCarrierLoaderBack(Length, Width)
self.carrierLoader.type="back" self.carrierLoader.type="back"
@@ -2457,8 +2457,8 @@ end
--- Set that this carrier is a starboard (right side) loader. --- Set that this carrier is a starboard (right side) loader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierLoaderStarboard(Length, Width) function OPSGROUP:SetCarrierLoaderStarboard(Length, Width)
self.carrierLoader.type="right" self.carrierLoader.type="right"
@@ -2469,8 +2469,8 @@ end
--- Set that this carrier is a port (left side) loader. --- Set that this carrier is a port (left side) loader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierLoaderPort(Length, Width) function OPSGROUP:SetCarrierLoaderPort(Length, Width)
self.carrierLoader.type="left" self.carrierLoader.type="left"
@@ -2482,8 +2482,8 @@ end
--- Set that this carrier is an all aspect unloader. --- Set that this carrier is an all aspect unloader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierUnloaderAllAspect(Length, Width) function OPSGROUP:SetCarrierUnloaderAllAspect(Length, Width)
self.carrierUnloader.type="front" self.carrierUnloader.type="front"
@@ -2494,8 +2494,8 @@ end
--- Set that this carrier is a front unloader. --- Set that this carrier is a front unloader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierUnloaderFront(Length, Width) function OPSGROUP:SetCarrierUnloaderFront(Length, Width)
self.carrierUnloader.type="front" self.carrierUnloader.type="front"
@@ -2506,8 +2506,8 @@ end
--- Set that this carrier is a back unloader. --- Set that this carrier is a back unloader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierUnloaderBack(Length, Width) function OPSGROUP:SetCarrierUnloaderBack(Length, Width)
self.carrierUnloader.type="back" self.carrierUnloader.type="back"
@@ -2518,8 +2518,8 @@ end
--- Set that this carrier is a starboard (right side) unloader. --- Set that this carrier is a starboard (right side) unloader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierUnloaderStarboard(Length, Width) function OPSGROUP:SetCarrierUnloaderStarboard(Length, Width)
self.carrierUnloader.type="right" self.carrierUnloader.type="right"
@@ -2530,8 +2530,8 @@ end
--- Set that this carrier is a port (left side) unloader. --- Set that this carrier is a port (left side) unloader.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Length Length of loading zone in meters. Default 50 m. -- @param #number Length (Optional) Length of loading zone in meters. Default 50 m.
-- @param #number Width Width of loading zone in meters. Default 20 m. -- @param #number Width (Optional) Width of loading zone in meters. Default 20 m.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetCarrierUnloaderPort(Length, Width) function OPSGROUP:SetCarrierUnloaderPort(Length, Width)
self.carrierUnloader.type="left" self.carrierUnloader.type="left"
@@ -3076,7 +3076,7 @@ end
--- Mark waypoints on F10 map. --- Mark waypoints on F10 map.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Duration Duration in seconds how long the waypoints are displayed before they are automatically removed. Default is that they are never removed. -- @param #number Duration (Optional) Duration in seconds how long the waypoints are displayed before they are automatically removed. Default is that they are never removed.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:MarkWaypoints(Duration) function OPSGROUP:MarkWaypoints(Duration)
@@ -3106,7 +3106,7 @@ end
--- Remove waypoints markers on the F10 map. --- Remove waypoints markers on the F10 map.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds before the markers are removed. Default is immediately. -- @param #number Delay (Optional) Delay in seconds before the markers are removed. Default is immediately.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:RemoveWaypointMarkers(Delay) function OPSGROUP:RemoveWaypointMarkers(Delay)
@@ -3196,8 +3196,8 @@ end
--- Get next waypoint index. --- Get next waypoint index.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #boolean cyclic If `true`, return first waypoint if last waypoint was reached. Default is patrol ad infinitum value set. -- @param #boolean cyclic (Optional) If `true`, return first waypoint if last waypoint was reached. Default is patrol ad infinitum value set.
-- @param #number i Waypoint index from which the next index is returned. Default is the last waypoint passed. -- @param #number i (Optional) Waypoint index from which the next index is returned. Default is the last waypoint passed.
-- @return #number Next waypoint index. -- @return #number Next waypoint index.
function OPSGROUP:GetWaypointIndexNext(cyclic, i) function OPSGROUP:GetWaypointIndexNext(cyclic, i)
@@ -3232,7 +3232,7 @@ end
--- Get waypoint index after waypoint with given ID. So if the waypoint has index 3 it will return 4. --- Get waypoint index after waypoint with given ID. So if the waypoint has index 3 it will return 4.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number uid Unique ID of the waypoint. Default is new waypoint index after the last current one. -- @param #number uid (Optional) Unique ID of the waypoint. Default is new waypoint index after the last current one.
-- @return #number Index after waypoint with given ID. -- @return #number Index after waypoint with given ID.
function OPSGROUP:GetWaypointIndexAfterID(uid) function OPSGROUP:GetWaypointIndexAfterID(uid)
@@ -3369,7 +3369,7 @@ end
--- Get distance to waypoint. --- Get distance to waypoint.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number indx Waypoint index. Default is the next waypoint. -- @param #number indx (Optional) Waypoint index. Default is the next waypoint.
-- @return #number Distance in meters. -- @return #number Distance in meters.
function OPSGROUP:GetDistanceToWaypoint(indx) function OPSGROUP:GetDistanceToWaypoint(indx)
local dist=0 local dist=0
@@ -3394,7 +3394,7 @@ end
--- Get time to waypoint based on current velocity. --- Get time to waypoint based on current velocity.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number indx Waypoint index. Default is the next waypoint. -- @param #number indx (Optional) Waypoint index. Default is the next waypoint.
-- @return #number Time in seconds. If velocity is 0 -- @return #number Time in seconds. If velocity is 0
function OPSGROUP:GetTimeToWaypoint(indx) function OPSGROUP:GetTimeToWaypoint(indx)
@@ -3847,10 +3847,10 @@ end
--- Add a *scheduled* task. --- Add a *scheduled* task.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #table task DCS task table structure. -- @param #table task DCS task table structure.
-- @param #string clock Mission time when task is executed. Default in 5 seconds. If argument passed as #number, it defines a relative delay in seconds. -- @param #string clock (Optional) Mission time when task is executed. Default in 5 seconds. If argument passed as #number, it defines a relative delay in seconds.
-- @param #string description Brief text describing the task, e.g. "Attack SAM". -- @param #string description Brief text describing the task, e.g. "Attack SAM".
-- @param #number prio Priority of the task. -- @param #number prio (Optional) Priority of the task. Default is 50.
-- @param #number duration Duration before task is cancelled in seconds counted after task started. Default never. -- @param #number duration (Optional) Duration before task is cancelled in seconds counted after task started. Default never.
-- @return #OPSGROUP.Task The task structure. -- @return #OPSGROUP.Task The task structure.
function OPSGROUP:AddTask(task, clock, description, prio, duration) function OPSGROUP:AddTask(task, clock, description, prio, duration)
@@ -3869,10 +3869,10 @@ end
--- Create a *scheduled* task. --- Create a *scheduled* task.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #table task DCS task table structure. -- @param #table task DCS task table structure.
-- @param #string clock Mission time when task is executed. Default in 5 seconds. If argument passed as #number, it defines a relative delay in seconds. -- @param #string clock (Optional) Mission time when task is executed. Default in 5 seconds. If argument passed as #number, it defines a relative delay in seconds.
-- @param #string description Brief text describing the task, e.g. "Attack SAM". -- @param #string description Brief text describing the task, e.g. "Attack SAM".
-- @param #number prio Priority of the task. -- @param #number prio (Optional) Priority of the task. Default is 50.
-- @param #number duration Duration before task is cancelled in seconds counted after task started. Default never. -- @param #number duration (Optional) Duration before task is cancelled in seconds counted after task started. Default never.
-- @return #OPSGROUP.Task The task structure. -- @return #OPSGROUP.Task The task structure.
function OPSGROUP:NewTaskScheduled(task, clock, description, prio, duration) function OPSGROUP:NewTaskScheduled(task, clock, description, prio, duration)
@@ -3909,10 +3909,10 @@ end
--- Add a *waypoint* task. --- Add a *waypoint* task.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #table task DCS task table structure. -- @param #table task DCS task table structure.
-- @param #OPSGROUP.Waypoint Waypoint where the task is executed. Default is the at *next* waypoint. -- @param #OPSGROUP.Waypoint Waypoint (Optional) where the task is executed. Default is the at *next* waypoint.
-- @param #string description Brief text describing the task, e.g. "Attack SAM". -- @param #string description Brief text describing the task, e.g. "Attack SAM".
-- @param #number prio Priority of the task. Number between 1 and 100. Default is 50. -- @param #number prio (Optional) Priority of the task. Number between 1 and 100. Default is 50.
-- @param #number duration Duration before task is cancelled in seconds counted after task started. Default never. -- @param #number duration(Optional) Duration before task is cancelled in seconds counted after task started. Default never.
-- @return #OPSGROUP.Task The task structure. -- @return #OPSGROUP.Task The task structure.
function OPSGROUP:AddTaskWaypoint(task, Waypoint, description, prio, duration) function OPSGROUP:AddTaskWaypoint(task, Waypoint, description, prio, duration)
@@ -4767,7 +4767,7 @@ function OPSGROUP:_UpdateTask(Task, Mission)
local tvec2=UTILS.Vec2Translate(vec2, distance, heading) local tvec2=UTILS.Vec2Translate(vec2, distance, heading)
-- Debug info. -- Debug info.
self:T(self.lid..string.format("Barrage: Shots=%s, Altitude=%d m, Angle=%d°, heading=%03d°, distance=%d m", tostring(param.shots), Altitude, Alpha, heading, distance)) self:T(self.lid..string.format("Barrage: Shots=%s, Altitude=%d m, Angle=%d°, heading=%03d°, distance=%d m", tostring(param.shots), Altitude, Alpha, heading, distance))
-- Set fire at point task. -- Set fire at point task.
DCSTask=CONTROLLABLE.TaskFireAtPoint(nil, tvec2, param.radius, param.shots, param.weaponType, Altitude) DCSTask=CONTROLLABLE.TaskFireAtPoint(nil, tvec2, param.radius, param.shots, param.weaponType, Altitude)
@@ -4842,8 +4842,8 @@ end
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param DCS#Task DCSTask The DCS task. -- @param DCS#Task DCSTask The DCS task.
-- @param Ops.OpsGroup#OPSGROUP.Task Task -- @param Ops.OpsGroup#OPSGROUP.Task Task
-- @param #boolean SetTask Set task instead of pushing it. -- @param #boolean SetTask (Optional) Set task instead of pushing it. Default is to push it.
-- @param #number Delay Delay in seconds. Default nil. -- @param #number Delay (Optional) Delay in seconds. Default nil.
function OPSGROUP:_SandwitchDCSTask(DCSTask, Task, SetTask, Delay) function OPSGROUP:_SandwitchDCSTask(DCSTask, Task, SetTask, Delay)
if Delay and Delay>0 then if Delay and Delay>0 then
@@ -4896,7 +4896,7 @@ end
-- @param #string From From state. -- @param #string From From state.
-- @param #string Event Event. -- @param #string Event Event.
-- @param #string To To state. -- @param #string To To state.
-- @param #OPSGROUP.Task Task The task to cancel. Default is the current task (if any). -- @param #OPSGROUP.Task Task (Optional) The task to cancel. Default is the current task (if any).
function OPSGROUP:onafterTaskCancel(From, Event, To, Task) function OPSGROUP:onafterTaskCancel(From, Event, To, Task)
-- Get current task. -- Get current task.
@@ -6209,7 +6209,7 @@ function OPSGROUP:RouteToMission(mission, delay)
-- We must be careful when calling updateroute because there the task is overwritten. -- We must be careful when calling updateroute because there the task is overwritten.
-- We also clear present "UpdateRoute" FSM events -- We also clear present "UpdateRoute" FSM events
self:_ClearFSMEvent( "UpdateRoute" ) self:_ClearFSMEvent( "UpdateRoute" )
delayGo=-30 delayGo=-50 --30 sec was not enough for CH-47 to load more than one cargo item
self.group:SetTask(TaskCargo) self.group:SetTask(TaskCargo)
elseif mission.type==AUFTRAG.Type.ARTY then elseif mission.type==AUFTRAG.Type.ARTY then
@@ -7772,8 +7772,8 @@ end
--- Teleport the group to a different location. --- Teleport the group to a different location.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param Core.Point#COORDINATE Coordinate Coordinate where the group is teleported to. -- @param Core.Point#COORDINATE Coordinate Coordinate where the group is teleported to.
-- @param #number Delay Delay in seconds before respawn happens. Default 0. -- @param #number Delay (Optional) Delay in seconds before respawn happens. Default 0.
-- @param #boolean NoPauseMission If `true`, dont pause a running mission. -- @param #boolean NoPauseMission (Optional) If `true`, dont pause a running mission.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:Teleport(Coordinate, Delay, NoPauseMission) function OPSGROUP:Teleport(Coordinate, Delay, NoPauseMission)
@@ -7861,9 +7861,9 @@ end
--- Respawn the group. --- Respawn the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds before respawn happens. Default 0. -- @param #number Delay (Optional) Delay in seconds before respawn happens. Default 0.
-- @param DCS#Template Template (optional) The template of the Group retrieved with GROUP:GetTemplate(). If the template is not provided, the template will be retrieved of the group itself. -- @param DCS#Template Template (Optional) The template of the Group retrieved with GROUP:GetTemplate(). If the template is not provided, the template will be retrieved of the group itself.
-- @param #boolean Reset Reset waypoints and reinit group if `true`. -- @param #boolean Reset (Optional) Reset waypoints and reinit group if `true`.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:_Respawn(Delay, Template, Reset) function OPSGROUP:_Respawn(Delay, Template, Reset)
@@ -7956,8 +7956,8 @@ end
--- Spawn group from a given template. --- Spawn group from a given template.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Delay Delay in seconds before respawn happens. Default 0. -- @param #number Delay (Optional) Delay in seconds before respawn happens. Default 0.
-- @param DCS#Template Template (optional) The template of the Group retrieved with GROUP:GetTemplate(). If the template is not provided, the template will be retrieved of the group itself. -- @param DCS#Template Template (Optional) The template of the Group retrieved with GROUP:GetTemplate(). If the template is not provided, the template will be retrieved of the group itself.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:_Spawn(Delay, Template) function OPSGROUP:_Spawn(Delay, Template)
if Delay and Delay>0 then if Delay and Delay>0 then
@@ -8960,8 +8960,8 @@ end
--- Get total weight of the group including cargo. Optionally, the total weight of a specific unit can be requested. --- Get total weight of the group including cargo. Optionally, the total weight of a specific unit can be requested.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @param #boolean IncludeReserved If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included. -- @param #boolean IncludeReserved (Optional) If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included.
-- @return #number Total weight in kg. -- @return #number Total weight in kg.
function OPSGROUP:GetWeightTotal(UnitName, IncludeReserved) function OPSGROUP:GetWeightTotal(UnitName, IncludeReserved)
@@ -8996,8 +8996,8 @@ end
--- Get free cargo bay weight. --- Get free cargo bay weight.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @param #boolean IncludeReserved If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included. -- @param #boolean IncludeReserved (Optional) If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included.
-- @return #number Free cargo bay in kg. -- @return #number Free cargo bay in kg.
function OPSGROUP:GetFreeCargobay(UnitName, IncludeReserved) function OPSGROUP:GetFreeCargobay(UnitName, IncludeReserved)
@@ -9018,8 +9018,8 @@ end
--- Get relative free cargo bay in percent. --- Get relative free cargo bay in percent.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @param #boolean IncludeReserved If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included. -- @param #boolean IncludeReserved (Optional) If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included.
-- @return #number Free cargo bay in percent. -- @return #number Free cargo bay in percent.
function OPSGROUP:GetFreeCargobayRelative(UnitName, IncludeReserved) function OPSGROUP:GetFreeCargobayRelative(UnitName, IncludeReserved)
@@ -9034,8 +9034,8 @@ end
--- Get relative used (loaded) cargo bay in percent. --- Get relative used (loaded) cargo bay in percent.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @param #boolean IncludeReserved If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included. -- @param #boolean IncludeReserved (Optional) If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included.
-- @return #number Used cargo bay in percent. -- @return #number Used cargo bay in percent.
function OPSGROUP:GetUsedCargobayRelative(UnitName, IncludeReserved) function OPSGROUP:GetUsedCargobayRelative(UnitName, IncludeReserved)
local free=self:GetFreeCargobayRelative(UnitName, IncludeReserved) local free=self:GetFreeCargobayRelative(UnitName, IncludeReserved)
@@ -9075,8 +9075,8 @@ end
--- Get weight of the internal cargo the group is carriing right now. --- Get weight of the internal cargo the group is carriing right now.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @param #boolean IncludeReserved If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included. -- @param #boolean IncludeReserved (Optional) If `false`, cargo weight that is only *reserved* is **not** counted. By default (`true` or `nil`), the reserved cargo is included.
-- @return #number Cargo weight in kg. -- @return #number Cargo weight in kg.
function OPSGROUP:GetWeightCargo(UnitName, IncludeReserved) function OPSGROUP:GetWeightCargo(UnitName, IncludeReserved)
@@ -9125,7 +9125,7 @@ end
--- Get max weight of the internal cargo the group can carry. Optionally, the max cargo weight of a specific unit can be requested. --- Get max weight of the internal cargo the group can carry. Optionally, the max cargo weight of a specific unit can be requested.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @return #number Max cargo weight in kg. This does **not** include any cargo loaded or reserved currently. -- @return #number Max cargo weight in kg. This does **not** include any cargo loaded or reserved currently.
function OPSGROUP:GetWeightCargoMax(UnitName) function OPSGROUP:GetWeightCargoMax(UnitName)
@@ -9163,7 +9163,7 @@ end
--- Add weight to the internal cargo of an element of the group. --- Add weight to the internal cargo of an element of the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string UnitName Name of the unit. Default is of the whole group. -- @param #string UnitName (Optional) Name of the unit. Default is of the whole group.
-- @param #number Weight Cargo weight to be added in kg. -- @param #number Weight Cargo weight to be added in kg.
function OPSGROUP:AddWeightCargo(UnitName, Weight) function OPSGROUP:AddWeightCargo(UnitName, Weight)
@@ -11529,7 +11529,7 @@ end
--- Initialize Mission Editor waypoints. --- Initialize Mission Editor waypoints.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #OPSGROUP.Waypoint waypoint Waypoint data. -- @param #OPSGROUP.Waypoint waypoint Waypoint data.
-- @param #number wpnumber Waypoint index/number. Default is as last waypoint. -- @param #number wpnumber (Optional) Waypoint index/number. Default is as last waypoint.
function OPSGROUP:_AddWaypoint(waypoint, wpnumber) function OPSGROUP:_AddWaypoint(waypoint, wpnumber)
-- Index. -- Index.
@@ -11999,7 +11999,7 @@ end
--- Set the default ROE for the group. This is the ROE state gets when the group is spawned or to which it defaults back after a mission. --- Set the default ROE for the group. This is the ROE state gets when the group is spawned or to which it defaults back after a mission.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number roe ROE of group. Default is `ENUMS.ROE.ReturnFire`. -- @param #number roe (Optional) ROE of group. Default is `ENUMS.ROE.ReturnFire`.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultROE(roe) function OPSGROUP:SetDefaultROE(roe)
self.optionDefault.ROE=roe or ENUMS.ROE.ReturnFire self.optionDefault.ROE=roe or ENUMS.ROE.ReturnFire
@@ -12008,7 +12008,7 @@ end
--- Set current ROE for the group. --- Set current ROE for the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string roe ROE of group. Default is value set in `SetDefaultROE` (usually `ENUMS.ROE.ReturnFire`). -- @param #string roe (Optional) ROE of group. Default is value set in `SetDefaultROE` (usually `ENUMS.ROE.ReturnFire`).
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchROE(roe) function OPSGROUP:SwitchROE(roe)
@@ -12061,7 +12061,7 @@ end
--- Set the default ROT for the group. This is the ROT state gets when the group is spawned or to which it defaults back after a mission. --- Set the default ROT for the group. This is the ROT state gets when the group is spawned or to which it defaults back after a mission.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number rot ROT of group. Default is `ENUMS.ROT.PassiveDefense`. -- @param #number rot (Optional) ROT of group. Default is `ENUMS.ROT.PassiveDefense`.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultROT(rot) function OPSGROUP:SetDefaultROT(rot)
self.optionDefault.ROT=rot or ENUMS.ROT.PassiveDefense self.optionDefault.ROT=rot or ENUMS.ROT.PassiveDefense
@@ -12070,7 +12070,7 @@ end
--- Set ROT for the group. --- Set ROT for the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #string rot ROT of group. Default is value set in `:SetDefaultROT` (usually `ENUMS.ROT.PassiveDefense`). -- @param #string rot (Optional) ROT of group. Default is value set in `:SetDefaultROT` (usually `ENUMS.ROT.PassiveDefense`).
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchROT(rot) function OPSGROUP:SwitchROT(rot)
@@ -12110,7 +12110,7 @@ end
--- Set the default Alarm State for the group. This is the state gets when the group is spawned or to which it defaults back after a mission. --- Set the default Alarm State for the group. This is the state gets when the group is spawned or to which it defaults back after a mission.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number alarmstate Alarm state of group. Default is `AI.Option.Ground.val.ALARM_STATE.AUTO` (0). -- @param #number alarmstate (Optional) Alarm state of group. Default is `AI.Option.Ground.val.ALARM_STATE.AUTO` (0).
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultAlarmstate(alarmstate) function OPSGROUP:SetDefaultAlarmstate(alarmstate)
self.optionDefault.Alarm=alarmstate or 0 self.optionDefault.Alarm=alarmstate or 0
@@ -12124,7 +12124,7 @@ end
-- * 2 = "Red" -- * 2 = "Red"
-- --
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number alarmstate Alarm state of group. Default is 0="Auto". -- @param #number alarmstate (Optional) Alarm state of group. Default is 0="Auto".
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchAlarmstate(alarmstate) function OPSGROUP:SwitchAlarmstate(alarmstate)
@@ -12171,7 +12171,7 @@ end
--- Set the default EPLRS for the group. --- Set the default EPLRS for the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #boolean OnOffSwitch If `true`, EPLRS is on by default. If `false` default EPLRS setting is off. If `nil`, default is on if group has EPLRS and off if it does not have a datalink. -- @param #boolean OnOffSwitch (Optional) If `true`, EPLRS is on by default. If `false` default EPLRS setting is off. If `nil`, default is on if group has EPLRS and off if it does not have a datalink.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultEPLRS(OnOffSwitch) function OPSGROUP:SetDefaultEPLRS(OnOffSwitch)
@@ -12226,7 +12226,7 @@ end
--- Set the default emission state for the group. --- Set the default emission state for the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #boolean OnOffSwitch If `true`, EPLRS is on by default. If `false` default EPLRS setting is off. If `nil`, default is on if group has EPLRS and off if it does not have a datalink. -- @param #boolean OnOffSwitch (Optional) If `true`, EPLRS is on by default. If `false` default EPLRS setting is off. If `nil`, default is on if group has EPLRS and off if it does not have a datalink.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultEmission(OnOffSwitch) function OPSGROUP:SetDefaultEmission(OnOffSwitch)
@@ -12281,7 +12281,7 @@ end
--- Set the default invisible for the group. --- Set the default invisible for the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #boolean OnOffSwitch If `true`, group is ivisible by default. -- @param #boolean OnOffSwitch (Optional) If `true`, group is ivisible by default.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultInvisible(OnOffSwitch) function OPSGROUP:SetDefaultInvisible(OnOffSwitch)
@@ -12330,7 +12330,7 @@ end
--- Set the default immortal for the group. --- Set the default immortal for the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #boolean OnOffSwitch If `true`, group is immortal by default. -- @param #boolean OnOffSwitch (Optional) If `true`, group is immortal by default.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultImmortal(OnOffSwitch) function OPSGROUP:SetDefaultImmortal(OnOffSwitch)
@@ -12382,11 +12382,11 @@ end
--- Set default TACAN parameters. --- Set default TACAN parameters.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Channel TACAN channel. Default is 74. -- @param #number Channel (Optional) TACAN channel. Default is 74.
-- @param #string Morse Morse code. Default "XXX". -- @param #string Morse(Optional) Morse code. Default "XXX".
-- @param #string UnitName Name of the unit acting as beacon. -- @param #string UnitName Name of the unit acting as beacon.
-- @param #string Band TACAN mode. Default is "X" for ground and "Y" for airborne units. -- @param #string Band (Optional) TACAN mode. Default is "X" for ground and "Y" for airborne units.
-- @param #boolean OffSwitch If true, TACAN is off by default. -- @param #boolean OffSwitch (Optional) If true, TACAN is off by default.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultTACAN(Channel, Morse, UnitName, Band, OffSwitch) function OPSGROUP:SetDefaultTACAN(Channel, Morse, UnitName, Band, OffSwitch)
@@ -12415,7 +12415,7 @@ end
--- Activate/switch TACAN beacon settings. --- Activate/switch TACAN beacon settings.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #OPSGROUP.Beacon Tacan TACAN data table. Default is the default TACAN settings. -- @param #OPSGROUP.Beacon Tacan (Optional) TACAN data table. Default is the default TACAN settings.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:_SwitchTACAN(Tacan) function OPSGROUP:_SwitchTACAN(Tacan)
@@ -12438,9 +12438,9 @@ end
--- Activate/switch TACAN beacon settings. --- Activate/switch TACAN beacon settings.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Channel TACAN Channel. -- @param #number Channel TACAN Channel.
-- @param #string Morse TACAN morse code. Default is the value set in @{#OPSGROUP.SetDefaultTACAN} or if not set "XXX". -- @param #string Morse (Optional) TACAN morse code. Default is the value set in @{#OPSGROUP.SetDefaultTACAN} or if not set "XXX".
-- @param #string UnitName Name of the unit in the group which should activate the TACAN beacon. Can also be given as #number to specify the unit number. Default is the first unit of the group. -- @param #string UnitName (Optional) Name of the unit in the group which should activate the TACAN beacon. Can also be given as #number to specify the unit number. Default is the first unit of the group.
-- @param #string Band TACAN channel mode "X" or "Y". Default is "Y" for aircraft and "X" for ground and naval groups. -- @param #string Band (Optional) TACAN channel mode "X" or "Y". Default is "Y" for aircraft and "X" for ground and naval groups.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchTACAN(Channel, Morse, UnitName, Band) function OPSGROUP:SwitchTACAN(Channel, Morse, UnitName, Band)
@@ -12547,10 +12547,10 @@ end
--- Set default ICLS parameters. --- Set default ICLS parameters.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Channel ICLS channel. Default is 1. -- @param #number Channel (Optional) ICLS channel. Default is 1.
-- @param #string Morse Morse code. Default "XXX". -- @param #string Morse (Optional) Morse code. Default "XXX".
-- @param #string UnitName Name of the unit acting as beacon. -- @param #string UnitName Name of the unit acting as beacon.
-- @param #boolean OffSwitch If true, TACAN is off by default. -- @param #boolean OffSwitch (Optional) If true, TACAN is off by default.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultICLS(Channel, Morse, UnitName, OffSwitch) function OPSGROUP:SetDefaultICLS(Channel, Morse, UnitName, OffSwitch)
@@ -12593,9 +12593,9 @@ end
--- Activate/switch ICLS beacon settings. --- Activate/switch ICLS beacon settings.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Channel ICLS Channel. Default is what is set in `SetDefaultICLS()` so usually channel 1. -- @param #number Channel (Optional) ICLS Channel. Default is what is set in `SetDefaultICLS()` so usually channel 1.
-- @param #string Morse ICLS morse code. Default is what is set in `SetDefaultICLS()` so usually "XXX". -- @param #string Morse (Optional) ICLS morse code. Default is what is set in `SetDefaultICLS()` so usually "XXX".
-- @param #string UnitName Name of the unit in the group which should activate the ICLS beacon. Can also be given as #number to specify the unit number. Default is the first unit of the group. -- @param #string UnitName (Optional) Name of the unit in the group which should activate the ICLS beacon. Can also be given as #number to specify the unit number. Default is the first unit of the group.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchICLS(Channel, Morse, UnitName) function OPSGROUP:SwitchICLS(Channel, Morse, UnitName)
@@ -12669,9 +12669,9 @@ end
--- Set default Radio frequency and modulation. --- Set default Radio frequency and modulation.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Frequency Radio frequency in MHz. Default 251 MHz. -- @param #number Frequency (Optional) Radio frequency in MHz. Default 251 MHz.
-- @param #number Modulation Radio modulation. Default `radio.modulation.AM`. -- @param #number Modulation (Optional) Radio modulation. Default `radio.modulation.AM`.
-- @param #boolean OffSwitch If true, radio is OFF by default. -- @param #boolean OffSwitch (Optional) If true, radio is OFF by default.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultRadio(Frequency, Modulation, OffSwitch) function OPSGROUP:SetDefaultRadio(Frequency, Modulation, OffSwitch)
@@ -12698,8 +12698,8 @@ end
--- Turn radio on or switch frequency/modulation. --- Turn radio on or switch frequency/modulation.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Frequency Radio frequency in MHz. Default is value set in `SetDefaultRadio` (usually 251 MHz). -- @param #number Frequency (Optional) Radio frequency in MHz. Default is value set in `SetDefaultRadio` (usually 251 MHz).
-- @param #number Modulation Radio modulation. Default is value set in `SetDefaultRadio` (usually `radio.modulation.AM`). -- @param #number Modulation (Optional) Radio modulation. Default is value set in `SetDefaultRadio` (usually `radio.modulation.AM`).
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchRadio(Frequency, Modulation) function OPSGROUP:SwitchRadio(Frequency, Modulation)
@@ -12778,7 +12778,7 @@ end
--- Switch to a specific formation. --- Switch to a specific formation.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number Formation New formation the group will fly in. Default is the setting of `SetDefaultFormation()`. -- @param #number Formation (Optional) New formation the group will fly in. Default is the setting of `SetDefaultFormation()`.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SwitchFormation(Formation) function OPSGROUP:SwitchFormation(Formation)
@@ -12815,7 +12815,7 @@ end
--- Set default callsign. --- Set default callsign.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number CallsignName Callsign name. -- @param #number CallsignName Callsign name.
-- @param #number CallsignNumber Callsign number. Default 1. -- @param #number CallsignNumber (Optional) Callsign number. Default 1.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:SetDefaultCallsign(CallsignName, CallsignNumber) function OPSGROUP:SetDefaultCallsign(CallsignName, CallsignNumber)
@@ -13540,7 +13540,7 @@ end
--- Get the number of shells a unit or group currently has. For a group the ammo count of all units is summed up. --- Get the number of shells a unit or group currently has. For a group the ammo count of all units is summed up.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param Wrapper.Unit#UNIT unit The unit object. -- @param Wrapper.Unit#UNIT unit The unit object.
-- @param #boolean display Display ammo table as message to all. Default false. -- @param #boolean display (Optional) Display ammo table as message to all. Default false.
-- @return #OPSGROUP.Ammo Ammo data. -- @return #OPSGROUP.Ammo Ammo data.
function OPSGROUP:GetAmmoUnit(unit, display) function OPSGROUP:GetAmmoUnit(unit, display)
@@ -13975,7 +13975,7 @@ end
--- Set the template of the group. --- Set the template of the group.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #table Template Template to set. Default is from the GROUP. -- @param #table Template (Optional) Template to set. Default is from the GROUP.
-- @return #OPSGROUP self -- @return #OPSGROUP self
function OPSGROUP:_SetTemplate(Template) function OPSGROUP:_SetTemplate(Template)
@@ -14012,8 +14012,8 @@ end
--- Clear waypoints. --- Clear waypoints.
-- @param #OPSGROUP self -- @param #OPSGROUP self
-- @param #number IndexMin Clear waypoints up to this min WP index. Default 1. -- @param #number IndexMin (Optional) Clear waypoints up to this min WP index. Default 1.
-- @param #number IndexMax Clear waypoints up to this max WP index. Default `#self.waypoints`. -- @param #number IndexMax (Optional) Clear waypoints up to this max WP index. Default `#self.waypoints`.
function OPSGROUP:ClearWaypoints(IndexMin, IndexMax) function OPSGROUP:ClearWaypoints(IndexMin, IndexMax)
IndexMin=IndexMin or 1 IndexMin=IndexMin or 1
+14 -14
View File
@@ -566,7 +566,7 @@ end
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param Core.Set#SET_GROUP GroupSet Set of groups to be transported. Can also be passed as a single GROUP or OPSGROUP object. -- @param Core.Set#SET_GROUP GroupSet Set of groups to be transported. Can also be passed as a single GROUP or OPSGROUP object.
-- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo Transport zone combo. -- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo Transport zone combo.
-- @param #boolean DisembarkActivation If `true`, cargo group is activated when disembarked. If `false`, cargo groups are late activated when disembarked. Default `nil` (usually activated). -- @param #boolean DisembarkActivation (Optional) If `true`, cargo group is activated when disembarked. If `false`, cargo groups are late activated when disembarked. Default `nil` (usually activated).
-- @param Core.Zone#ZONE DisembarkZone Zone where the groups disembark to. -- @param Core.Zone#ZONE DisembarkZone Zone where the groups disembark to.
-- @param Core.Set#SET_OPSGROUP DisembarkCarriers Carrier groups where the cargo directly disembarks to. -- @param Core.Set#SET_OPSGROUP DisembarkCarriers Carrier groups where the cargo directly disembarks to.
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
@@ -644,8 +644,8 @@ end
-- @param Wrapper.Storage#STORAGE StorageTo Storage warehouse to which the cargo is delivered. -- @param Wrapper.Storage#STORAGE StorageTo Storage warehouse to which the cargo is delivered.
-- @param #string CargoType Type of cargo, *e.g.* `"weapons.bombs.Mk_84"` or liquid type as #number. -- @param #string CargoType Type of cargo, *e.g.* `"weapons.bombs.Mk_84"` or liquid type as #number.
-- @param #number CargoAmount Amount of cargo. Liquids in kg. -- @param #number CargoAmount Amount of cargo. Liquids in kg.
-- @param #number CargoWeight Weight of a single cargo item in kg. Default 1 kg. -- @param #number CargoWeight (Optional) Weight of a single cargo item in kg. Default 1 kg.
-- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo Transport zone combo if other than default. -- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo (Optional) Transport zone combo if other than default.
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
function OPSTRANSPORT:AddCargoStorage(StorageFrom, StorageTo, CargoType, CargoAmount, CargoWeight, TransportZoneCombo) function OPSTRANSPORT:AddCargoStorage(StorageFrom, StorageTo, CargoType, CargoAmount, CargoWeight, TransportZoneCombo)
@@ -1052,8 +1052,8 @@ end
--- Set number of required carrier groups for an OPSTRANSPORT assignment. Only used if transport is assigned at **LEGION** or higher level. --- Set number of required carrier groups for an OPSTRANSPORT assignment. Only used if transport is assigned at **LEGION** or higher level.
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param #number NcarriersMin Number of carriers *at least* required. Default 1. -- @param #number NcarriersMin (Optional) Number of carriers *at least* required. Default 1.
-- @param #number NcarriersMax Number of carriers *at most* used for transportation. Default is same as `NcarriersMin`. -- @param #number NcarriersMax (Optional) Number of carriers *at most* used for transportation. Default is same as `NcarriersMin`.
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
function OPSTRANSPORT:SetRequiredCarriers(NcarriersMin, NcarriersMax) function OPSTRANSPORT:SetRequiredCarriers(NcarriersMin, NcarriersMax)
@@ -1258,7 +1258,7 @@ end
--- Set transport start and stop time. --- Set transport start and stop time.
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param #string ClockStart Time the transport is started, e.g. "05:00" for 5 am. If specified as a #number, it will be relative (in seconds) to the current mission time. Default is 5 seconds after mission was added. -- @param #string ClockStart (Optional) Time the transport is started, e.g. "05:00" for 5 am. If specified as a #number, it will be relative (in seconds) to the current mission time. Default is 5 seconds after mission was added.
-- @param #string ClockStop (Optional) Time the transport is stopped, e.g. "13:00" for 1 pm. If mission could not be started at that time, it will be removed from the queue. If specified as a #number it will be relative (in seconds) to the current mission time. -- @param #string ClockStop (Optional) Time the transport is stopped, e.g. "13:00" for 1 pm. If mission could not be started at that time, it will be removed from the queue. If specified as a #number it will be relative (in seconds) to the current mission time.
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
function OPSTRANSPORT:SetTime(ClockStart, ClockStop) function OPSTRANSPORT:SetTime(ClockStart, ClockStop)
@@ -1294,9 +1294,9 @@ end
--- Set mission priority and (optional) urgency. Urgent missions can cancel other running missions. --- Set mission priority and (optional) urgency. Urgent missions can cancel other running missions.
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param #number Prio Priority 1=high, 100=low. Default 50. -- @param #number Prio (Optional) Priority 1=high, 100=low. Default 50.
-- @param #number Importance Number 1-10. If missions with lower value are in the queue, these have to be finished first. Default is `nil`. -- @param #number Importance (Optional) Number 1-10. If missions with lower value are in the queue, these have to be finished first. Default is `nil`.
-- @param #boolean Urgent If *true*, another running mission might be cancelled if it has a lower priority. -- @param #boolean Urgent (Optional) If *true*, another running mission might be cancelled if it has a lower priority.
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
function OPSTRANSPORT:SetPriority(Prio, Importance, Urgent) function OPSTRANSPORT:SetPriority(Prio, Importance, Urgent)
self.prio=Prio or 50 self.prio=Prio or 50
@@ -1307,7 +1307,7 @@ end
--- Set verbosity. --- Set verbosity.
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param #number Verbosity Be more verbose. Default 0 -- @param #number Verbosity (Optional) Be more verbose. Default 0
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
function OPSTRANSPORT:SetVerbosity(Verbosity) function OPSTRANSPORT:SetVerbosity(Verbosity)
self.verbose=Verbosity or 0 self.verbose=Verbosity or 0
@@ -1345,8 +1345,8 @@ end
-- path. -- path.
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param Wrapper.Group#GROUP PathGroup A (late activated) GROUP defining a transport path by their waypoints. -- @param Wrapper.Group#GROUP PathGroup A (late activated) GROUP defining a transport path by their waypoints.
-- @param #number Radius Randomization radius in meters. Default 0 m. -- @param #number Radius (Optional) Randomization radius in meters. Default 0 m.
-- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo Transport Zone combo. -- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo (Optional) Transport Zone combo.
-- @return #OPSTRANSPORT self -- @return #OPSTRANSPORT self
function OPSTRANSPORT:AddPathTransport(PathGroup, Reversed, Radius, TransportZoneCombo) function OPSTRANSPORT:AddPathTransport(PathGroup, Reversed, Radius, TransportZoneCombo)
@@ -1731,7 +1731,7 @@ end
--- Check if all cargo was delivered (or is dead). --- Check if all cargo was delivered (or is dead).
-- @param #OPSTRANSPORT self -- @param #OPSTRANSPORT self
-- @param #number Nmin Number of groups that must be actually delivered (and are not dead). Default 0. -- @param #number Nmin (Optional) Number of groups that must be actually delivered (and are not dead). Default 0.
-- @return #boolean If true, all possible cargo was delivered. -- @return #boolean If true, all possible cargo was delivered.
function OPSTRANSPORT:IsDelivered(Nmin) function OPSTRANSPORT:IsDelivered(Nmin)
local is=self:is(OPSTRANSPORT.Status.DELIVERED) local is=self:is(OPSTRANSPORT.Status.DELIVERED)
@@ -2298,7 +2298,7 @@ end
-- @param Wrapper.Storage#STORAGE StorageTo Storage to. -- @param Wrapper.Storage#STORAGE StorageTo Storage to.
-- @param #string CargoType Type of cargo. -- @param #string CargoType Type of cargo.
-- @param #number CargoAmount Total amount of cargo that should be transported. Liquids in kg. -- @param #number CargoAmount Total amount of cargo that should be transported. Liquids in kg.
-- @param #number CargoWeight Weight of a single cargo item in kg. Default 1 kg. -- @param #number CargoWeight (Optional) Weight of a single cargo item in kg. Default 1 kg.
-- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo Transport zone combo. -- @param #OPSTRANSPORT.TransportZoneCombo TransportZoneCombo Transport zone combo.
-- @return Ops.OpsGroup#OPSGROUP.CargoGroup Cargo group data. -- @return Ops.OpsGroup#OPSGROUP.CargoGroup Cargo group data.
function OPSTRANSPORT:_CreateCargoStorage(StorageFrom, StorageTo, CargoType, CargoAmount, CargoWeight, TransportZoneCombo) function OPSTRANSPORT:_CreateCargoStorage(StorageFrom, StorageTo, CargoType, CargoAmount, CargoWeight, TransportZoneCombo)
+7 -7
View File
@@ -121,7 +121,7 @@ OPSZONE.version="0.6.2"
--- Create a new OPSZONE class object. --- Create a new OPSZONE class object.
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param Core.Zone#ZONE Zone The zone. Can be passed as ZONE\_RADIUS, ZONE_POLYGON, ZONE\_AIRBASE or simply as the name of the airbase. -- @param Core.Zone#ZONE Zone The zone. Can be passed as ZONE\_RADIUS, ZONE_POLYGON, ZONE\_AIRBASE or simply as the name of the airbase.
-- @param #number CoalitionOwner Initial owner of the coaliton. Default `coalition.side.NEUTRAL`. -- @param #number CoalitionOwner (Optional) Initial owner of the coaliton. Default `coalition.side.NEUTRAL`.
-- @return #OPSZONE self -- @return #OPSZONE self
-- @usage -- @usage
-- myopszone = OPSZONE:New(ZONE:FindByName("OpsZoneOne"), coalition.side.RED) -- base zone from the mission editor -- myopszone = OPSZONE:New(ZONE:FindByName("OpsZoneOne"), coalition.side.RED) -- base zone from the mission editor
@@ -385,7 +385,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #OPSZONE self -- @return #OPSZONE self
function OPSZONE:SetVerbosity(VerbosityLevel) function OPSZONE:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -400,7 +400,7 @@ end
-- Which units can capture zones can be further refined by `:SetUnitCategories()`. -- Which units can capture zones can be further refined by `:SetUnitCategories()`.
-- --
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param #table Categories Object categories. Default is `{Object.Category.UNIT, Object.Category.STATIC}`. -- @param #table Categories (Optional) Object categories. Default is `{Object.Category.UNIT, Object.Category.STATIC}`.
-- @return #OPSZONE self -- @return #OPSZONE self
function OPSZONE:SetObjectCategories(Categories) function OPSZONE:SetObjectCategories(Categories)
@@ -417,7 +417,7 @@ end
--- Set categories of units that can capture or hold the zone. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit). --- Set categories of units that can capture or hold the zone. See [DCS Class Unit](https://wiki.hoggitworld.com/view/DCS_Class_Unit).
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param #table Categories Table of unit categories. Default `{Unit.Category.GROUND_UNIT}`. -- @param #table Categories (Optional) Table of unit categories. Default `{Unit.Category.GROUND_UNIT}`.
-- @return #OPSZONE self -- @return #OPSZONE self
function OPSZONE:SetUnitCategories(Categories) function OPSZONE:SetUnitCategories(Categories)
@@ -435,7 +435,7 @@ end
--- Set threat level threshold that the offending units must have to capture a zone. --- Set threat level threshold that the offending units must have to capture a zone.
-- The reason why you might want to set this is that unarmed units (*e.g.* fuel trucks) should not be able to capture a zone as they do not pose a threat. -- The reason why you might want to set this is that unarmed units (*e.g.* fuel trucks) should not be able to capture a zone as they do not pose a threat.
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param #number Threatlevel Threat level threshold. Default 0. -- @param #number Threatlevel (Optional) Threat level threshold. Default 0.
-- @return #OPSZONE self -- @return #OPSZONE self
function OPSZONE:SetCaptureThreatlevel(Threatlevel) function OPSZONE:SetCaptureThreatlevel(Threatlevel)
@@ -446,7 +446,7 @@ end
--- Set how many units must be present in a zone to capture it. By default, one unit is enough. --- Set how many units must be present in a zone to capture it. By default, one unit is enough.
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param #number Nunits Number of units. Default 1. -- @param #number Nunits (Optional) Number of units. Default 1.
-- @return #OPSZONE self -- @return #OPSZONE self
function OPSZONE:SetCaptureNunits(Nunits) function OPSZONE:SetCaptureNunits(Nunits)
@@ -460,7 +460,7 @@ end
--- Set time how long an attacking coalition must have troops inside a zone before it captures the zone. --- Set time how long an attacking coalition must have troops inside a zone before it captures the zone.
-- @param #OPSZONE self -- @param #OPSZONE self
-- @param #number Tcapture Time in seconds. Default 0. -- @param #number Tcapture (Optional) Time in seconds. Default 0.
-- @return #OPSZONE self -- @return #OPSZONE self
function OPSZONE:SetCaptureTime(Tcapture) function OPSZONE:SetCaptureTime(Tcapture)
+1 -1
View File
@@ -55,7 +55,7 @@ PLATOON.version="0.1.0"
--- Create a new PLATOON object and start the FSM. --- Create a new PLATOON object and start the FSM.
-- @param #PLATOON self -- @param #PLATOON self
-- @param #string TemplateGroupName Name of the template group. -- @param #string TemplateGroupName Name of the template group.
-- @param #number Ngroups Number of asset groups of this platoon. Default 3. -- @param #number Ngroups (Optional) Number of asset groups of this platoon. Default 3.
-- @param #string PlatoonName Name of the platoon. Must be **unique**! -- @param #string PlatoonName Name of the platoon. Must be **unique**!
-- @return #PLATOON self -- @return #PLATOON self
function PLATOON:New(TemplateGroupName, Ngroups, PlatoonName) function PLATOON:New(TemplateGroupName, Ngroups, PlatoonName)
+3 -3
View File
@@ -1542,9 +1542,9 @@ end
--- [User] Set SRS TTS details - see @{Sound.SRS} for details --- [User] Set SRS TTS details - see @{Sound.SRS} for details
-- @param #PLAYERRECCE self -- @param #PLAYERRECCE self
-- @param #number Frequency Frequency to be used. Can also be given as a table of multiple frequencies, e.g. 271 or {127,251}. There needs to be exactly the same number of modulations! -- @param #number Frequency (Optional) Frequency to be used. Can also be given as a table of multiple frequencies, e.g. 271 or {127,251}. There needs to be exactly the same number of modulations!
-- @param #number Modulation Modulation to be used. Can also be given as a table of multiple modulations, e.g. radio.modulation.AM or {radio.modulation.FM,radio.modulation.AM}. There needs to be exactly the same number of frequencies! -- @param #number Modulation (Optional) Modulation to be used. Can also be given as a table of multiple modulations, e.g. radio.modulation.AM or {radio.modulation.FM,radio.modulation.AM}. There needs to be exactly the same number of frequencies!
-- @param #string PathToSRS Defaults to "C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio" -- @param #string PathToSRS (Optional) Defaults to "C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio"
-- @param #string Gender (Optional) Defaults to "male" -- @param #string Gender (Optional) Defaults to "male"
-- @param #string Culture (Optional) Defaults to "en-US" -- @param #string Culture (Optional) Defaults to "en-US"
-- @param #number Port (Optional) Defaults to 5002 -- @param #number Port (Optional) Defaults to 5002
+33 -33
View File
@@ -115,9 +115,9 @@ PLAYERTASK.version="0.1.31"
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param Ops.Auftrag#AUFTRAG.Type Type Type of this task -- @param Ops.Auftrag#AUFTRAG.Type Type Type of this task
-- @param Ops.Target#TARGET Target Target for this task -- @param Ops.Target#TARGET Target Target for this task
-- @param #boolean Repeat Repeat this task if true (default = false) -- @param #boolean Repeat (Optional) Repeat this task if true (default = false)
-- @param #number Times Repeat on failure this many times if Repeat is true (default = 1) -- @param #number Times (Optional) Repeat on failure this many times if Repeat is true (default = 1)
-- @param #string TTSType TTS friendly task type name -- @param #string TTSType (Optional) TTS friendly task type name. Defaultsto "close air support".
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:New(Type, Target, Repeat, Times, TTSType) function PLAYERTASK:New(Type, Target, Repeat, Times, TTSType)
@@ -272,8 +272,8 @@ end
--- Constructor that automatically determines the task type based on the target. --- Constructor that automatically determines the task type based on the target.
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param Ops.Target#TARGET Target Target for this task -- @param Ops.Target#TARGET Target Target for this task
-- @param #boolean Repeat Repeat this task if true (default = false) -- @param #boolean Repeat (Optional) Repeat this task if true (default = false)
-- @param #number Times Repeat on failure this many times if Repeat is true (default = 1) -- @param #number Times (Optional) Repeat on failure this many times if Repeat is true (default = 1)
-- @param #string TTSType TTS friendly task type name -- @param #string TTSType TTS friendly task type name
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:NewFromTarget(Target, Repeat, Times, TTSType) function PLAYERTASK:NewFromTarget(Target, Repeat, Times, TTSType)
@@ -486,7 +486,7 @@ end
--- [USER] Set if a task can have a smoke marker. --- [USER] Set if a task can have a smoke marker.
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param #boolean OnOff If true (default) it can be smoke, false if not. -- @param #boolean OnOff (Optional) If true (default) it can be smoke, false if not.
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:SetCanSmoke(OnOff) function PLAYERTASK:SetCanSmoke(OnOff)
self:T(self.lid.."AddSSetCanSmokeubType") self:T(self.lid.."AddSSetCanSmokeubType")
@@ -496,7 +496,7 @@ end
--- [USER] Set if a task can show threat details. --- [USER] Set if a task can show threat details.
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param #boolean OnOff If true (default) it can be shown, false if not. -- @param #boolean OnOff (Optional) If true (default) it can be shown, false if not.
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:SetShowThreatDetails(OnOff) function PLAYERTASK:SetShowThreatDetails(OnOff)
self:T(self.lid.."SetShowThreatDetails") self:T(self.lid.."SetShowThreatDetails")
@@ -686,7 +686,7 @@ end
--- [USER] Adds a time limit for the task to be completed. --- [USER] Adds a time limit for the task to be completed.
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param #number TimeLimit Time limit in seconds for the task to be completed. (Default 0 = no time limit) -- @param #number TimeLimit (Optional) Time limit in seconds for the task to be completed. (Default 0 = no time limit)
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
-- @usage -- @usage
-- local mytask = PLAYERTASK:New(AUFTRAG.Type.RECON, ZONE:New("WF Zone"), true, 50, "Deep Earth") -- local mytask = PLAYERTASK:New(AUFTRAG.Type.RECON, ZONE:New("WF Zone"), true, 50, "Deep Earth")
@@ -892,7 +892,7 @@ end
--- [User] Smoke Target --- [User] Smoke Target
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param #number Color, defaults to SMOKECOLOR.Red -- @param #number Color (Optional) Color, defaults to SMOKECOLOR.Red
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:SmokeTarget(Color) function PLAYERTASK:SmokeTarget(Color)
self:T(self.lid.."SmokeTarget") self:T(self.lid.."SmokeTarget")
@@ -911,7 +911,7 @@ end
--- [User] Flare Target --- [User] Flare Target
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param #number Color, defaults to FLARECOLOR.Red -- @param #number Color (Optional) Color, defaults to FLARECOLOR.Red
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:FlareTarget(Color) function PLAYERTASK:FlareTarget(Color)
self:T(self.lid.."SmokeTarget") self:T(self.lid.."SmokeTarget")
@@ -927,8 +927,8 @@ end
--- [User] Illuminate Target Area --- [User] Illuminate Target Area
-- @param #PLAYERTASK self -- @param #PLAYERTASK self
-- @param #number Power Power of illumination bomb in Candela. Default 1000 cd. -- @param #number Power (Optional) Power of illumination bomb in Candela. Default 1000 cd.
-- @param #number Height Height above target used to release the bomb, default 150m. -- @param #number Height (Optional) Height above target used to release the bomb, default 150m.
-- @return #PLAYERTASK self -- @return #PLAYERTASK self
function PLAYERTASK:IlluminateTarget(Power,Height) function PLAYERTASK:IlluminateTarget(Power,Height)
self:T(self.lid.."IlluminateTarget") self:T(self.lid.."IlluminateTarget")
@@ -2021,9 +2021,9 @@ PLAYERTASKCONTROLLER.version="0.1.73"
--- Create and run a new TASKCONTROLLER instance. --- Create and run a new TASKCONTROLLER instance.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #string Name Name of this controller -- @param #string Name Name of this controller
-- @param #number Coalition of this controller, e.g. coalition.side.BLUE -- @param #number Coalition (Optional) Coalition of this controller. Defaults to coalition.side.BLUE
-- @param #string Type Type of the tasks controlled, defaults to PLAYERTASKCONTROLLER.Type.A2G -- @param #string Type (Optional) Type of the tasks controlled, defaults to PLAYERTASKCONTROLLER.Type.A2G
-- @param #string ClientFilter (optional) Additional prefix filter for the SET_CLIENT. Can be handed as @{Core.Set#SET_CLIENT} also. -- @param #string ClientFilter (Optional) Additional prefix filter for the SET_CLIENT. Can be handed as @{Core.Set#SET_CLIENT} also.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:New(Name, Coalition, Type, ClientFilter) function PLAYERTASKCONTROLLER:New(Name, Coalition, Type, ClientFilter)
@@ -2317,7 +2317,7 @@ end
--- [User] Set flash directions option for player (player based info) --- [User] Set flash directions option for player (player based info)
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #boolean OnOff Set to `true` to switch on and `false` to switch off. Default is OFF. -- @param #boolean OnOff (Optional) Set to `true` to switch on and `false` to switch off. Default is OFF.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetAllowFlashDirection(OnOff) function PLAYERTASKCONTROLLER:SetAllowFlashDirection(OnOff)
self:T(self.lid.."SetAllowFlashDirection") self:T(self.lid.."SetAllowFlashDirection")
@@ -2327,7 +2327,7 @@ end
--- [User] Set to show a menu entry to retrieve the radio frequencies used. --- [User] Set to show a menu entry to retrieve the radio frequencies used.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #boolean OnOff Set to `true` to switch on and `false` to switch off. Default is OFF. -- @param #boolean OnOff (Optional) Set to `true` to switch on and `false` to switch off. Default is OFF.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetShowRadioInfoMenu(OnOff) function PLAYERTASKCONTROLLER:SetShowRadioInfoMenu(OnOff)
self:T(self.lid.."SetAllowRadioInfoMenu") self:T(self.lid.."SetAllowRadioInfoMenu")
@@ -2436,8 +2436,8 @@ end
--- [User] Set repetition options for tasks. --- [User] Set repetition options for tasks.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #boolean OnOff Set to `true` to switch on and `false` to switch off (defaults to true) -- @param #boolean OnOff (Optional) Set to `true` to switch on and `false` to switch off (defaults to true)
-- @param #number Repeats Number of repeats (defaults to 5) -- @param #number Repeats (Optional) Number of repeats (defaults to 5)
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
-- @usage `taskmanager:SetTaskRepetition(true, 5)` -- @usage `taskmanager:SetTaskRepetition(true, 5)`
function PLAYERTASKCONTROLLER:SetTaskRepetition(OnOff, Repeats) function PLAYERTASKCONTROLLER:SetTaskRepetition(OnOff, Repeats)
@@ -2454,7 +2454,7 @@ end
--- [User] Set how long the briefing is shown on screen. --- [User] Set how long the briefing is shown on screen.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #number Seconds Duration in seconds. Defaults to 30 seconds. -- @param #number Seconds (Optional) Duration in seconds. Defaults to 30 seconds.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetBriefingDuration(Seconds) function PLAYERTASKCONTROLLER:SetBriefingDuration(Seconds)
self:T(self.lid.."SetBriefingDuration") self:T(self.lid.."SetBriefingDuration")
@@ -2484,7 +2484,7 @@ end
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param Ops.FlightGroup#FLIGHTGROUP FlightGroup The FlightGroup (e.g. drone) to be used for lasing (one unit in one group only). -- @param Ops.FlightGroup#FLIGHTGROUP FlightGroup The FlightGroup (e.g. drone) to be used for lasing (one unit in one group only).
-- Can optionally be handed as Ops.ArmyGroup#ARMYGROUP - **Note** might not find an LOS spot or get lost on the way. Cannot island-hop. -- Can optionally be handed as Ops.ArmyGroup#ARMYGROUP - **Note** might not find an LOS spot or get lost on the way. Cannot island-hop.
-- @param #number LaserCode The lasercode to be used. Defaults to 1688. -- @param #number LaserCode (Optional) The lasercode to be used. Defaults to 1688.
-- @param Core.Point#COORDINATE HoldingPoint (Optional) Point where the drone should initially circle. If not set, defaults to BullsEye of the coalition. -- @param Core.Point#COORDINATE HoldingPoint (Optional) Point where the drone should initially circle. If not set, defaults to BullsEye of the coalition.
-- @param #number Alt (Optional) Altitude in feet. Only applies if using a FLIGHTGROUP object! Defaults to 10000. -- @param #number Alt (Optional) Altitude in feet. Only applies if using a FLIGHTGROUP object! Defaults to 10000.
-- @param #number Speed (Optional) Speed in knots. Only applies if using a FLIGHTGROUP object! Defaults to 120. -- @param #number Speed (Optional) Speed in knots. Only applies if using a FLIGHTGROUP object! Defaults to 120.
@@ -2567,7 +2567,7 @@ end
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param Ops.FlightGroup#FLIGHTGROUP FlightGroup The FlightGroup (e.g. drone) to be used for lasing (one unit in one group only). -- @param Ops.FlightGroup#FLIGHTGROUP FlightGroup The FlightGroup (e.g. drone) to be used for lasing (one unit in one group only).
-- Can optionally be handed as Ops.ArmyGroup#ARMYGROUP - **Note** might not find an LOS spot or get lost on the way. Cannot island-hop. -- Can optionally be handed as Ops.ArmyGroup#ARMYGROUP - **Note** might not find an LOS spot or get lost on the way. Cannot island-hop.
-- @param #number LaserCode The lasercode to be used. Defaults to 1688. -- @param #number LaserCode (Optional) The lasercode to be used. Defaults to 1688.
-- @param Core.Point#COORDINATE HoldingPoint (Optional) Point where the drone should initially circle. If not set, defaults to BullsEye of the coalition. -- @param Core.Point#COORDINATE HoldingPoint (Optional) Point where the drone should initially circle. If not set, defaults to BullsEye of the coalition.
-- @param #number Alt (Optional) Altitude in feet. Only applies if using a FLIGHTGROUP object! Defaults to 10000. -- @param #number Alt (Optional) Altitude in feet. Only applies if using a FLIGHTGROUP object! Defaults to 10000.
-- @param #number Speed (Optional) Speed in knots. Only applies if using a FLIGHTGROUP object! Defaults to 120. -- @param #number Speed (Optional) Speed in knots. Only applies if using a FLIGHTGROUP object! Defaults to 120.
@@ -2704,8 +2704,8 @@ end
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #boolean InfoMenu If `true` this option will allow to show the Task Info-Menu also when a player has an active task. -- @param #boolean InfoMenu If `true` this option will allow to show the Task Info-Menu also when a player has an active task.
-- Since the menu isn't refreshed if a player holds an active task, the info in there might be stale. -- Since the menu isn't refreshed if a player holds an active task, the info in there might be stale.
-- @param #number ItemLimit Number of items per task type to show, default 5. -- @param #number ItemLimit (Optional) Number of items per task type to show, default 5.
-- @param #number HoldTime Minimum number of seconds between menu refreshes (called every 30 secs) if a player has **no active task**. -- @param #number HoldTime (Optional) Minimum number of seconds between menu refreshes (called every 30 secs) if a player has **no active task**.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetMenuOptions(InfoMenu,ItemLimit,HoldTime) function PLAYERTASKCONTROLLER:SetMenuOptions(InfoMenu,ItemLimit,HoldTime)
self:T(self.lid.."SetMenuOptions") self:T(self.lid.."SetMenuOptions")
@@ -2840,7 +2840,7 @@ end
--- [User] Set target radius. Determines the zone radius to distinguish CAS from BAI tasks and to find enemies if the TARGET object is a COORDINATE. --- [User] Set target radius. Determines the zone radius to distinguish CAS from BAI tasks and to find enemies if the TARGET object is a COORDINATE.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #number Radius Radius to use in meters. Defaults to 500 meters. -- @param #number Radius (Optional) Radius to use in meters. Defaults to 500 meters.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetTargetRadius(Radius) function PLAYERTASKCONTROLLER:SetTargetRadius(Radius)
self:T(self.lid.."SetTargetRadius") self:T(self.lid.."SetTargetRadius")
@@ -2851,7 +2851,7 @@ end
--- [User] Set the cluster radius if you want to use target clusters rather than single group detection. --- [User] Set the cluster radius if you want to use target clusters rather than single group detection.
-- Note that for a controller type A2A target clustering is on by default. Also remember that the diameter of the resulting zone is double the radius. -- Note that for a controller type A2A target clustering is on by default. Also remember that the diameter of the resulting zone is double the radius.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #number Radius Target cluster radius in kilometers. Default is 0.5km. -- @param #number Radius (Optional) Target cluster radius in kilometers. Default is 0.5km.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetClusterRadius(Radius) function PLAYERTASKCONTROLLER:SetClusterRadius(Radius)
self:T(self.lid.."SetClusterRadius") self:T(self.lid.."SetClusterRadius")
@@ -2873,7 +2873,7 @@ end
--- [User] Switch usage of target names for menu entries on or off --- [User] Switch usage of target names for menu entries on or off
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #boolean OnOff If true, set to on (default), if nil or false, set to off -- @param #boolean OnOff (Optional) If true, set to on (default), if nil or false, set to off
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SwitchUseGroupNames(OnOff) function PLAYERTASKCONTROLLER:SwitchUseGroupNames(OnOff)
self:T(self.lid.."SwitchUseGroupNames") self:T(self.lid.."SwitchUseGroupNames")
@@ -2887,7 +2887,7 @@ end
--- [User] Switch showing additional magnetic angles --- [User] Switch showing additional magnetic angles
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #boolean OnOff If true, set to on (default), if nil or false, set to off -- @param #boolean OnOff (Optional) If true, set to on (default), if nil or false, set to off
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SwitchMagenticAngles(OnOff) function PLAYERTASKCONTROLLER:SwitchMagenticAngles(OnOff)
self:T(self.lid.."SwitchMagenticAngles") self:T(self.lid.."SwitchMagenticAngles")
@@ -3782,7 +3782,7 @@ end
--- Calculate group future position after given seconds. --- Calculate group future position after given seconds.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param Wrapper.Group#GROUP group The group to calculate for. -- @param Wrapper.Group#GROUP group The group to calculate for.
-- @param #number seconds Time interval in seconds. Default is `self.prediction`. -- @param #number seconds (Optional) Time interval in seconds. Default is `self.prediction`.
-- @return Core.Point#COORDINATE Calculated future position of the cluster. -- @return Core.Point#COORDINATE Calculated future position of the cluster.
function PLAYERTASKCONTROLLER:_CalcGroupFuturePosition(group, seconds) function PLAYERTASKCONTROLLER:_CalcGroupFuturePosition(group, seconds)
@@ -4898,9 +4898,9 @@ end
--- [User] Set SRS TTS details - see @{Sound.SRS} for details.`SetSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible. --- [User] Set SRS TTS details - see @{Sound.SRS} for details.`SetSRS()` will try to use as many attributes configured with @{Sound.SRS#MSRS.LoadConfigFile}() as possible.
-- @param #PLAYERTASKCONTROLLER self -- @param #PLAYERTASKCONTROLLER self
-- @param #number Frequency Frequency to be used. Can also be given as a table of multiple frequencies, e.g. 271 or {127,251}. There needs to be exactly the same number of modulations! -- @param #number Frequency (Optional) Frequency to be used. Can also be given as a table of multiple frequencies, e.g. 271 or {127,251}. There needs to be exactly the same number of modulations!
-- @param #number Modulation Modulation to be used. Can also be given as a table of multiple modulations, e.g. radio.modulation.AM or {radio.modulation.FM,radio.modulation.AM}. There needs to be exactly the same number of frequencies! -- @param #number Modulation (Optional) Modulation to be used. Can also be given as a table of multiple modulations, e.g. radio.modulation.AM or {radio.modulation.FM,radio.modulation.AM}. There needs to be exactly the same number of frequencies!
-- @param #string PathToSRS Defaults to "C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio" -- @param #string PathToSRS (Optional) Defaults to "C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio"
-- @param #string Gender (Optional) Defaults to "male" -- @param #string Gender (Optional) Defaults to "male"
-- @param #string Culture (Optional) Defaults to "en-US" -- @param #string Culture (Optional) Defaults to "en-US"
-- @param #number Port (Optional) Defaults to 5002 -- @param #number Port (Optional) Defaults to 5002
@@ -4909,7 +4909,7 @@ end
-- @param #number Volume (Optional) Volume - between 0.0 (silent) and 1.0 (loudest) -- @param #number Volume (Optional) Volume - between 0.0 (silent) and 1.0 (loudest)
-- @param #string PathToGoogleKey (Optional) Path to your google key if you want to use google TTS; if you use a config file for MSRS, hand in nil here. -- @param #string PathToGoogleKey (Optional) Path to your google key if you want to use google TTS; if you use a config file for MSRS, hand in nil here.
-- @param #string AccessKey (Optional) Your Google API access key. This is necessary if DCS-gRPC is used as backend; if you use a config file for MSRS, hand in nil here. -- @param #string AccessKey (Optional) Your Google API access key. This is necessary if DCS-gRPC is used as backend; if you use a config file for MSRS, hand in nil here.
-- @param Core.Point#COORDINATE Coordinate Coordinate from which the controller radio is sending -- @param Core.Point#COORDINATE Coordinate (Optional) Coordinate from which the controller radio is sending
-- @param #string Backend (Optional) MSRS Backend to be used, can be MSRS.Backend.SRSEXE or MSRS.Backend.GRPC; if you use a config file for MSRS, hand in nil here. -- @param #string Backend (Optional) MSRS Backend to be used, can be MSRS.Backend.SRSEXE or MSRS.Backend.GRPC; if you use a config file for MSRS, hand in nil here.
-- @return #PLAYERTASKCONTROLLER self -- @return #PLAYERTASKCONTROLLER self
function PLAYERTASKCONTROLLER:SetSRS(Frequency,Modulation,PathToSRS,Gender,Culture,Port,Voice,Volume,PathToGoogleKey,AccessKey,Coordinate,Backend) function PLAYERTASKCONTROLLER:SetSRS(Frequency,Modulation,PathToSRS,Gender,Culture,Port,Voice,Volume,PathToGoogleKey,AccessKey,Coordinate,Backend)
+15 -15
View File
@@ -564,7 +564,7 @@ end
--- Set the speed the tanker flys in its orbit pattern. --- Set the speed the tanker flys in its orbit pattern.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number speed True air speed (TAS) in knots. Default 274 knots, which results in ~250 KIAS. -- @param #number speed (Optional) True air speed (TAS) in knots. Default 274 knots, which results in ~250 KIAS.
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetSpeed(speed) function RECOVERYTANKER:SetSpeed(speed)
self.speed=UTILS.KnotsToMps(speed or 274) self.speed=UTILS.KnotsToMps(speed or 274)
@@ -573,7 +573,7 @@ end
--- Set orbit pattern altitude of the tanker. --- Set orbit pattern altitude of the tanker.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number altitude Tanker altitude in feet. Default 6000 ft. -- @param #number altitude (Optional) Tanker altitude in feet. Default 6000 ft.
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetAltitude(altitude) function RECOVERYTANKER:SetAltitude(altitude)
self.altitude=UTILS.FeetToMeters(altitude or 6000) self.altitude=UTILS.FeetToMeters(altitude or 6000)
@@ -582,8 +582,8 @@ end
--- Set race-track distances. --- Set race-track distances.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number distbow Distance [NM] in front of the carrier. Default 10 NM. -- @param #number distbow (Optional) Distance [NM] in front of the carrier. Default 10 NM.
-- @param #number diststern Distance [NM] behind the carrier. Default 4 NM. -- @param #number diststern (Optional) Distance [NM] behind the carrier. Default 4 NM.
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetRacetrackDistances(distbow, diststern) function RECOVERYTANKER:SetRacetrackDistances(distbow, diststern)
self.distBow=UTILS.NMToMeters(distbow or 10) self.distBow=UTILS.NMToMeters(distbow or 10)
@@ -593,7 +593,7 @@ end
--- Set minimum pattern update interval. After a pattern update this time interval has to pass before the next update is allowed. --- Set minimum pattern update interval. After a pattern update this time interval has to pass before the next update is allowed.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number interval Min interval in minutes. Default is 10 minutes. -- @param #number interval(Optional) Min interval in minutes. Default is 10 minutes.
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetPatternUpdateInterval(interval) function RECOVERYTANKER:SetPatternUpdateInterval(interval)
self.dTupdate=(interval or 10)*60 self.dTupdate=(interval or 10)*60
@@ -602,7 +602,7 @@ end
--- Set pattern update distance threshold. Tanker will update its pattern when the carrier changes its position by more than this distance. --- Set pattern update distance threshold. Tanker will update its pattern when the carrier changes its position by more than this distance.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number distancechange Distance threshold in NM. Default 5 NM (=9.62 km). -- @param #number distancechange (Optional) Distance threshold in NM. Default 5 NM (=9.62 km).
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetPatternUpdateDistance(distancechange) function RECOVERYTANKER:SetPatternUpdateDistance(distancechange)
self.Dupdate=UTILS.NMToMeters(distancechange or 5) self.Dupdate=UTILS.NMToMeters(distancechange or 5)
@@ -611,7 +611,7 @@ end
--- Set pattern update heading threshold. Tanker will update its pattern when the carrier changes its heading by more than this value. --- Set pattern update heading threshold. Tanker will update its pattern when the carrier changes its heading by more than this value.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number headingchange Heading threshold in degrees. Default 5 degrees. -- @param #number headingchange (Optional) Heading threshold in degrees. Default 5 degrees.
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetPatternUpdateHeading(headingchange) function RECOVERYTANKER:SetPatternUpdateHeading(headingchange)
self.Hupdate=headingchange or 5 self.Hupdate=headingchange or 5
@@ -620,7 +620,7 @@ end
--- Set low fuel state of tanker. When fuel is below this threshold, the tanker will RTB or be respawned if takeoff type is in air. --- Set low fuel state of tanker. When fuel is below this threshold, the tanker will RTB or be respawned if takeoff type is in air.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number fuelthreshold Low fuel threshold in percent. Default 10 % of max fuel. -- @param #number fuelthreshold (Optional) Low fuel threshold in percent. Default 10 % of max fuel.
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetLowFuelThreshold(fuelthreshold) function RECOVERYTANKER:SetLowFuelThreshold(fuelthreshold)
self.lowfuel=fuelthreshold or 10 self.lowfuel=fuelthreshold or 10
@@ -794,9 +794,9 @@ end
--- Set TACAN channel of tanker. Note that mode is automatically set to "Y" for AA TACAN since only that works. --- Set TACAN channel of tanker. Note that mode is automatically set to "Y" for AA TACAN since only that works.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number channel TACAN channel. Default 1. -- @param #number channel (Optional) TACAN channel. Default 1.
-- @param #string morse TACAN morse code identifier. Three letters. Default "TKR". -- @param #string morse (Optional) TACAN morse code identifier. Three letters. Default "TKR".
-- @param #string mode TACAN mode, which can be either "Y" (default) or "X". -- @param #string mode (Optional) TACAN mode, which can be either "Y" (default) or "X".
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetTACAN(channel, morse, mode) function RECOVERYTANKER:SetTACAN(channel, morse, mode)
self.TACANchannel=channel or 1 self.TACANchannel=channel or 1
@@ -808,8 +808,8 @@ end
--- Set radio frequency and optionally modulation of the tanker. --- Set radio frequency and optionally modulation of the tanker.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number frequency Radio frequency in MHz. Default 251 MHz. -- @param #number frequency (Optional) Radio frequency in MHz. Default 251 MHz.
-- @param #string modulation Radio modulation, either "AM" or "FM". Default "AM". -- @param #string modulation (Optional) Radio modulation, either "AM" or "FM". Default "AM".
-- @return #RECOVERYTANKER self -- @return #RECOVERYTANKER self
function RECOVERYTANKER:SetRadio(frequency, modulation) function RECOVERYTANKER:SetRadio(frequency, modulation)
self.RadioFreq=frequency or 251 self.RadioFreq=frequency or 251
@@ -1537,8 +1537,8 @@ end
--- Init waypoint after spawn. Tanker is first guided to a position astern the carrier and starts its racetrack pattern from there. --- Init waypoint after spawn. Tanker is first guided to a position astern the carrier and starts its racetrack pattern from there.
-- @param #RECOVERYTANKER self -- @param #RECOVERYTANKER self
-- @param #number dist Distance [NM] of initial waypoint astern carrier. Default 8 NM. -- @param #number dist (Optional) Distance [NM] of initial waypoint astern carrier. Default 8 NM.
-- @param #number delay Delay before routing in seconds. Default 1 second. -- @param #number delay (Optional) Delay before routing in seconds. Default 1 second.
function RECOVERYTANKER:_InitRoute(dist, delay) function RECOVERYTANKER:_InitRoute(dist, delay)
-- Defaults. -- Defaults.
+9 -9
View File
@@ -455,7 +455,7 @@ end
--- Set low fuel state of helo. When fuel is below this threshold, the helo will RTB or be respawned if takeoff type is in air. --- Set low fuel state of helo. When fuel is below this threshold, the helo will RTB or be respawned if takeoff type is in air.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number threshold Low fuel threshold in percent. Default 5%. -- @param #number threshold (Optional) Low fuel threshold in percent. Default 5%.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetLowFuelThreshold(threshold) function RESCUEHELO:SetLowFuelThreshold(threshold)
self.lowfuel=threshold or 5 self.lowfuel=threshold or 5
@@ -480,7 +480,7 @@ end
--- Set rescue zone radius. Crashed or ejected units inside this radius of the carrier will be rescued if possible. --- Set rescue zone radius. Crashed or ejected units inside this radius of the carrier will be rescued if possible.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number radius Radius of rescue zone in nautical miles. Default is 15 NM. -- @param #number radius (Optional) Radius of rescue zone in nautical miles. Default is 15 NM.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetRescueZone(radius) function RESCUEHELO:SetRescueZone(radius)
radius=UTILS.NMToMeters(radius or 15) radius=UTILS.NMToMeters(radius or 15)
@@ -490,7 +490,7 @@ end
--- Set rescue hover speed. --- Set rescue hover speed.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number speed Speed in knots. Default 5 kts. -- @param #number speed (Optional) Speed in knots. Default 5 kts.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetRescueHoverSpeed(speed) function RESCUEHELO:SetRescueHoverSpeed(speed)
self.rescuespeed=UTILS.KnotsToMps(speed or 5) self.rescuespeed=UTILS.KnotsToMps(speed or 5)
@@ -499,7 +499,7 @@ end
--- Set rescue duration. This is the time it takes to rescue a pilot at the crash site. --- Set rescue duration. This is the time it takes to rescue a pilot at the crash site.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number duration Duration in minutes. Default 5 min. -- @param #number duration (Optional) Duration in minutes. Default 5 min.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetRescueDuration(duration) function RESCUEHELO:SetRescueDuration(duration)
self.rescueduration=(duration or 5)*60 self.rescueduration=(duration or 5)*60
@@ -541,7 +541,7 @@ end
--- Set takeoff type. --- Set takeoff type.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number takeofftype Takeoff type. Default SPAWN.Takeoff.Hot. -- @param #number takeofftype (Optional) Takeoff type. Default SPAWN.Takeoff.Hot.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetTakeoff(takeofftype) function RESCUEHELO:SetTakeoff(takeofftype)
self.takeoff=takeofftype or SPAWN.Takeoff.Hot self.takeoff=takeofftype or SPAWN.Takeoff.Hot
@@ -574,7 +574,7 @@ end
--- Set altitude of helo. --- Set altitude of helo.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number alt Altitude in meters. Default 70 m. -- @param #number alt (Optional) Altitude in meters. Default 70 m.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetAltitude(alt) function RESCUEHELO:SetAltitude(alt)
self.altitude=alt or 70 self.altitude=alt or 70
@@ -583,7 +583,7 @@ end
--- Set offset parallel to orientation of carrier. --- Set offset parallel to orientation of carrier.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number distance Offset distance in meters. Default 200 m (~660 ft). -- @param #number distance (Optional) Offset distance in meters. Default 200 m (~660 ft).
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetOffsetX(distance) function RESCUEHELO:SetOffsetX(distance)
self.offsetX=distance or 200 self.offsetX=distance or 200
@@ -592,7 +592,7 @@ end
--- Set offset perpendicular to orientation to carrier. --- Set offset perpendicular to orientation to carrier.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number distance Offset distance in meters. Default 240 m (~780 ft). -- @param #number distance (Optional) Offset distance in meters. Default 240 m (~780 ft).
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetOffsetZ(distance) function RESCUEHELO:SetOffsetZ(distance)
self.offsetZ=distance or 240 self.offsetZ=distance or 240
@@ -650,7 +650,7 @@ end
--- Set follow time update interval. --- Set follow time update interval.
-- @param #RESCUEHELO self -- @param #RESCUEHELO self
-- @param #number dt Time interval in seconds. Default 1.0 sec. -- @param #number dt (Optional) Time interval in seconds. Default 1.0 sec.
-- @return #RESCUEHELO self -- @return #RESCUEHELO self
function RESCUEHELO:SetFollowTimeInterval(dt) function RESCUEHELO:SetFollowTimeInterval(dt)
self.dtFollow=dt or 1.0 self.dtFollow=dt or 1.0
+6 -6
View File
@@ -92,7 +92,7 @@ SQUADRON.version="0.8.1"
--- Create a new SQUADRON object and start the FSM. --- Create a new SQUADRON object and start the FSM.
-- @param #SQUADRON self -- @param #SQUADRON self
-- @param #string TemplateGroupName Name of the template group. -- @param #string TemplateGroupName Name of the template group.
-- @param #number Ngroups Number of asset groups of this squadron. Default 3. -- @param #number Ngroups (Optional) Number of asset groups of this squadron. Default 3.
-- @param #string SquadronName Name of the squadron, e.g. "VFA-37". Must be **unique**! -- @param #string SquadronName Name of the squadron, e.g. "VFA-37". Must be **unique**!
-- @return #SQUADRON self -- @return #SQUADRON self
function SQUADRON:New(TemplateGroupName, Ngroups, SquadronName) function SQUADRON:New(TemplateGroupName, Ngroups, SquadronName)
@@ -125,7 +125,7 @@ end
--- Set number of units in groups. --- Set number of units in groups.
-- @param #SQUADRON self -- @param #SQUADRON self
-- @param #number nunits Number of units. Must be >=1 and <=4. Default 2. -- @param #number nunits (Optional) Number of units. Must be >=1 and <=4. Default 2.
-- @return #SQUADRON self -- @return #SQUADRON self
function SQUADRON:SetGrouping(nunits) function SQUADRON:SetGrouping(nunits)
self.ngrouping=nunits or 2 self.ngrouping=nunits or 2
@@ -150,7 +150,7 @@ end
--- Set takeoff type. All assets of this squadron will be spawned with cold (default) or hot engines. --- Set takeoff type. All assets of this squadron will be spawned with cold (default) or hot engines.
-- Spawning on runways is not supported. -- Spawning on runways is not supported.
-- @param #SQUADRON self -- @param #SQUADRON self
-- @param #string TakeoffType Take off type: "Cold" (default) or "Hot" with engines on or "Air" for spawning in air. -- @param #string TakeoffType (Optional) Take off type: "Cold" (default) or "Hot" with engines on or "Air" for spawning in air.
-- @return #SQUADRON self -- @return #SQUADRON self
function SQUADRON:SetTakeoffType(TakeoffType) function SQUADRON:SetTakeoffType(TakeoffType)
TakeoffType=TakeoffType or "Cold" TakeoffType=TakeoffType or "Cold"
@@ -193,7 +193,7 @@ end
--- Set despawn after landing. Aircraft will be despawned after the landing event. --- Set despawn after landing. Aircraft will be despawned after the landing event.
-- Can help to avoid DCS AI taxiing issues. -- Can help to avoid DCS AI taxiing issues.
-- @param #SQUADRON self -- @param #SQUADRON self
-- @param #boolean Switch If `true` (default), activate despawn after landing. -- @param #boolean Switch (Optional) If `true` (default), activate despawn after landing.
-- @return #SQUADRON self -- @return #SQUADRON self
function SQUADRON:SetDespawnAfterLanding(Switch) function SQUADRON:SetDespawnAfterLanding(Switch)
if Switch then if Switch then
@@ -207,7 +207,7 @@ end
--- Set despawn after holding. Aircraft will be despawned when they arrive at their holding position at the airbase. --- Set despawn after holding. Aircraft will be despawned when they arrive at their holding position at the airbase.
-- Can help to avoid DCS AI taxiing issues. -- Can help to avoid DCS AI taxiing issues.
-- @param #SQUADRON self -- @param #SQUADRON self
-- @param #boolean Switch If `true` (default), activate despawn after holding. -- @param #boolean Switch (Optional) If `true` (default), activate despawn after holding.
-- @return #SQUADRON self -- @return #SQUADRON self
function SQUADRON:SetDespawnAfterHolding(Switch) function SQUADRON:SetDespawnAfterHolding(Switch)
if Switch then if Switch then
@@ -221,7 +221,7 @@ end
--- Set low fuel threshold. --- Set low fuel threshold.
-- @param #SQUADRON self -- @param #SQUADRON self
-- @param #number LowFuel Low fuel threshold in percent. Default 25. -- @param #number LowFuel (Optional) Low fuel threshold in percent. Default 25.
-- @return #SQUADRON self -- @return #SQUADRON self
function SQUADRON:SetFuelLowThreshold(LowFuel) function SQUADRON:SetFuelLowThreshold(LowFuel)
self.fuellow=LowFuel or 25 self.fuellow=LowFuel or 25
+5 -5
View File
@@ -400,7 +400,7 @@ end
--- Set priority of the target. --- Set priority of the target.
-- @param #TARGET self -- @param #TARGET self
-- @param #number Priority Priority of the target. Default 50. -- @param #number Priority (Optional) Priority of the target. Default 50.
-- @return #TARGET self -- @return #TARGET self
function TARGET:SetPriority(Priority) function TARGET:SetPriority(Priority)
self.prio=Priority or 50 self.prio=Priority or 50
@@ -409,7 +409,7 @@ end
--- Set importance of the target. --- Set importance of the target.
-- @param #TARGET self -- @param #TARGET self
-- @param #number Importance Importance of the target. Default `nil`. -- @param #number Importance (Optional) Importance of the target. Default `nil`.
-- @return #TARGET self -- @return #TARGET self
function TARGET:SetImportance(Importance) function TARGET:SetImportance(Importance)
self.importance=Importance self.importance=Importance
@@ -508,10 +508,10 @@ end
--- Add mission type and number of required assets to resource. --- Add mission type and number of required assets to resource.
-- @param #TARGET self -- @param #TARGET self
-- @param #string MissionType Mission Type. -- @param #string MissionType Mission Type.
-- @param #number Nmin Min number of required assets. -- @param #number Nmin (Optional) Min number of required assets. Default is 1.
-- @param #number Nmax Max number of requried assets. -- @param #number Nmax (Optional) Max number of requried assets. Default is 1.
-- @param #table Attributes Generalized attribute(s). -- @param #table Attributes Generalized attribute(s).
-- @param #table Properties DCS attribute(s). Default `nil`. -- @param #table Properties (Optional) DCS attribute(s). Default `nil`.
-- @return #TARGET.Resource The resource table. -- @return #TARGET.Resource The resource table.
function TARGET:AddResource(MissionType, Nmin, Nmax, Attributes, Properties) function TARGET:AddResource(MissionType, Nmin, Nmax, Attributes, Properties)
+13 -13
View File
@@ -170,7 +170,7 @@ end
--- Set radio power. Note that this only applies if no relay unit is used. --- Set radio power. Note that this only applies if no relay unit is used.
-- @param #RADIOQUEUE self -- @param #RADIOQUEUE self
-- @param #number power Radio power in Watts. Default 100 W. -- @param #number power (Optional) Radio power in Watts. Default 100 W.
-- @return #RADIOQUEUE self The RADIOQUEUE object. -- @return #RADIOQUEUE self The RADIOQUEUE object.
function RADIOQUEUE:SetRadioPower(power) function RADIOQUEUE:SetRadioPower(power)
self.power=power or 100 self.power=power or 100
@@ -179,8 +179,8 @@ end
--- Set SRS. --- Set SRS.
-- @param #RADIOQUEUE self -- @param #RADIOQUEUE self
-- @param #string PathToSRS Path to SRS. -- @param #string PathToSRS (Optional) Path to SRS.
-- @param #number Port SRS port. Default 5002. -- @param #number Port (Optional) SRS port. Default 5002.
-- @return #RADIOQUEUE self The RADIOQUEUE object. -- @return #RADIOQUEUE self The RADIOQUEUE object.
function RADIOQUEUE:SetSRS(PathToSRS, Port) function RADIOQUEUE:SetSRS(PathToSRS, Port)
local path = PathToSRS or MSRS.path local path = PathToSRS or MSRS.path
@@ -195,9 +195,9 @@ end
-- @param #number digit The digit 0-9. -- @param #number digit The digit 0-9.
-- @param #string filename The name of the sound file. -- @param #string filename The name of the sound file.
-- @param #number duration The duration of the sound file in seconds. -- @param #number duration The duration of the sound file in seconds.
-- @param #string path The directory within the miz file where the sound is located. Default "l10n/DEFAULT/". -- @param #string path (Optional) The directory within the miz file where the sound is located. Default "l10n/DEFAULT/".
-- @param #string subtitle Subtitle of the transmission. -- @param #string subtitle Subtitle of the transmission.
-- @param #number subduration Duration [sec] of the subtitle being displayed. Default 5 sec. -- @param #number subduration (Optional) Duration [sec] of the subtitle being displayed. Default 5 sec.
-- @return #RADIOQUEUE self The RADIOQUEUE object. -- @return #RADIOQUEUE self The RADIOQUEUE object.
function RADIOQUEUE:SetDigit(digit, filename, duration, path, subtitle, subduration) function RADIOQUEUE:SetDigit(digit, filename, duration, path, subtitle, subduration)
@@ -245,11 +245,11 @@ end
-- @param #RADIOQUEUE self -- @param #RADIOQUEUE self
-- @param #string filename Name of the sound file. Usually an ogg or wav file type. -- @param #string filename Name of the sound file. Usually an ogg or wav file type.
-- @param #number duration Duration in seconds the file lasts. -- @param #number duration Duration in seconds the file lasts.
-- @param #number path Directory path inside the miz file where the sound file is located. Default "l10n/DEFAULT/". -- @param #number path (Optional) Directory path inside the miz file where the sound file is located. Default "l10n/DEFAULT/".
-- @param #number tstart Start time (abs) seconds. Default now. -- @param #number tstart (Optional) Start time (abs) seconds. Default now.
-- @param #number interval Interval in seconds after the last transmission finished. -- @param #number interval (Optional) Interval in seconds after the last transmission finished. Defaults to 0.
-- @param #string subtitle Subtitle of the transmission. -- @param #string subtitle Subtitle of the transmission.
-- @param #number subduration Duration [sec] of the subtitle being displayed. Default 5 sec. -- @param #number subduration (Optional) Duration [sec] of the subtitle being displayed. Default 5 sec.
-- @return #RADIOQUEUE.Transmission Radio transmission table. -- @return #RADIOQUEUE.Transmission Radio transmission table.
function RADIOQUEUE:NewTransmission(filename, duration, path, tstart, interval, subtitle, subduration) function RADIOQUEUE:NewTransmission(filename, duration, path, tstart, interval, subtitle, subduration)
@@ -295,8 +295,8 @@ end
--- Add a SOUNDFILE to the radio queue. --- Add a SOUNDFILE to the radio queue.
-- @param #RADIOQUEUE self -- @param #RADIOQUEUE self
-- @param Sound.SoundOutput#SOUNDFILE soundfile Sound file object to be added. -- @param Sound.SoundOutput#SOUNDFILE soundfile Sound file object to be added.
-- @param #number tstart Start time (abs) seconds. Default now. -- @param #number tstart (Optional) Start time (abs) seconds. Default now.
-- @param #number interval Interval in seconds after the last transmission finished. -- @param #number interval (Optional) Interval in seconds after the last transmission finished. Defaults to 0.
-- @return #RADIOQUEUE self -- @return #RADIOQUEUE self
function RADIOQUEUE:AddSoundFile(soundfile, tstart, interval) function RADIOQUEUE:AddSoundFile(soundfile, tstart, interval)
--env.info(string.format("FF add soundfile: name=%s%s", soundfile:GetPath(), soundfile:GetFileName())) --env.info(string.format("FF add soundfile: name=%s%s", soundfile:GetPath(), soundfile:GetFileName()))
@@ -308,8 +308,8 @@ end
--- Add a SOUNDTEXT to the radio queue. --- Add a SOUNDTEXT to the radio queue.
-- @param #RADIOQUEUE self -- @param #RADIOQUEUE self
-- @param Sound.SoundOutput#SOUNDTEXT soundtext Text-to-speech text. -- @param Sound.SoundOutput#SOUNDTEXT soundtext Text-to-speech text.
-- @param #number tstart Start time (abs) seconds. Default now. -- @param #number tstart (Optional) Start time (abs) seconds. Default now.
-- @param #number interval Interval in seconds after the last transmission finished. -- @param #number interval (Optional) Interval in seconds after the last transmission finished. Defaults to 0.
-- @return #RADIOQUEUE self -- @return #RADIOQUEUE self
function RADIOQUEUE:AddSoundText(soundtext, tstart, interval) function RADIOQUEUE:AddSoundText(soundtext, tstart, interval)
+40 -40
View File
@@ -793,10 +793,10 @@ end
-- set the path to the exe file via @{#MSRS.SetPath}. -- set the path to the exe file via @{#MSRS.SetPath}.
-- --
-- @param #MSRS self -- @param #MSRS self
-- @param #string Path Path to SRS directory. Default `C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio`. -- @param #string Path (Optional) Path to SRS directory. Default `C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio`.
-- @param #number Frequency Radio frequency in MHz. Default 143.00 MHz. Can also be given as a #table of multiple frequencies. -- @param #number Frequency (Optional) Radio frequency in MHz. Default 143.00 MHz. Can also be given as a #table of multiple frequencies.
-- @param #number Modulation Radio modulation: 0=AM (default), 1=FM. See `radio.modulation.AM` and `radio.modulation.FM` enumerators. Can also be given as a #table of multiple modulations. -- @param #number Modulation (Optional) Radio modulation: 0=AM (default), 1=FM. See `radio.modulation.AM` and `radio.modulation.FM` enumerators. Can also be given as a #table of multiple modulations.
-- @param #string Backend Backend used: `MSRS.Backend.SRSEXE` (default) or `MSRS.Backend.GRPC`. -- @param #string Backend (Optional) Backend used: `MSRS.Backend.SRSEXE` (default) or `MSRS.Backend.GRPC`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:New(Path, Frequency, Modulation, Backend) function MSRS:New(Path, Frequency, Modulation, Backend)
@@ -866,7 +866,7 @@ end
-- - `MSRS.Backend.GRPC`: Via DCS-gRPC. -- - `MSRS.Backend.GRPC`: Via DCS-gRPC.
-- --
-- @param #MSRS self -- @param #MSRS self
-- @param #string Backend Backend used. Default is `MSRS.Backend.SRSEXE`. -- @param #string Backend (Optional) Backend used. Default is `MSRS.Backend.SRSEXE`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetBackend(Backend) function MSRS:SetBackend(Backend)
self:F( {Backend=Backend} ) self:F( {Backend=Backend} )
@@ -944,7 +944,7 @@ end
--- Set path to SRS install directory. More precisely, path to where the `DCS-SR-ExternalAudio.exe` is located. --- Set path to SRS install directory. More precisely, path to where the `DCS-SR-ExternalAudio.exe` is located.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Path Path to the directory, where the sound file is located. Default is `C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio`. -- @param #string Path (Optional) Path to the directory, where the sound file is located. Default is `C:\\Program Files\\DCS-SimpleRadio-Standalone\\ExternalAudio`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetPath(Path) function MSRS:SetPath(Path)
self:F( {Path=Path} ) self:F( {Path=Path} )
@@ -993,7 +993,7 @@ end
--- Set label. --- Set label.
-- @param #MSRS self -- @param #MSRS self
-- @param #number Label. Default "ROBOT" -- @param #number Label (Optional) Label. Default "ROBOT"
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetLabel(Label) function MSRS:SetLabel(Label)
self:F( {Label=Label} ) self:F( {Label=Label} )
@@ -1010,7 +1010,7 @@ end
--- Set port. --- Set port.
-- @param #MSRS self -- @param #MSRS self
-- @param #number Port Port. Default 5002. -- @param #number Port (Optional) Port. Default 5002.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetPort(Port) function MSRS:SetPort(Port)
self:F( {Port=Port} ) self:F( {Port=Port} )
@@ -1028,7 +1028,7 @@ end
--- Set coalition. --- Set coalition.
-- @param #MSRS self -- @param #MSRS self
-- @param #number Coalition Coalition. Default 0. -- @param #number Coalition (Optional) Coalition. Default 0.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetCoalition(Coalition) function MSRS:SetCoalition(Coalition)
self:F( {Coalition=Coalition} ) self:F( {Coalition=Coalition} )
@@ -1114,7 +1114,7 @@ end
--- Set gender. --- Set gender.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Gender Gender: "male" or "female" (default). -- @param #string Gender (Optional) Gender: "male" or "female" (default).
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetGender(Gender) function MSRS:SetGender(Gender)
self:F( {Gender=Gender} ) self:F( {Gender=Gender} )
@@ -1153,7 +1153,7 @@ end
--- Set to use a specific voice for a given provider. Note that this will override any gender and culture settings. --- Set to use a specific voice for a given provider. Note that this will override any gender and culture settings.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Voice Voice. -- @param #string Voice Voice.
-- @param #string Provider Provider. Default is as set by @{#MSRS.SetProvider}, which itself defaults to `MSRS.Provider.WINDOWS` if not set. -- @param #string Provider (Optional) Provider. Default is as set by @{#MSRS.SetProvider}, which itself defaults to `MSRS.Provider.WINDOWS` if not set.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetVoiceProvider(Voice, Provider) function MSRS:SetVoiceProvider(Voice, Provider)
self:F( {Voice=Voice, Provider=Provider} ) self:F( {Voice=Voice, Provider=Provider} )
@@ -1166,7 +1166,7 @@ end
--- Set to use a specific voice if Microsoft Windows' native TTS is use as provider. Note that this will override any gender and culture settings. --- Set to use a specific voice if Microsoft Windows' native TTS is use as provider. Note that this will override any gender and culture settings.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Voice Voice. Default `"Microsoft Hazel Desktop"`. -- @param #string Voice (Optional) Voice. Default `"Microsoft Hazel Desktop"`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetVoiceWindows(Voice) function MSRS:SetVoiceWindows(Voice)
self:F( {Voice=Voice} ) self:F( {Voice=Voice} )
@@ -1177,7 +1177,7 @@ end
--- Set to use a specific voice if Google is use as provider. Note that this will override any gender and culture settings. --- Set to use a specific voice if Google is use as provider. Note that this will override any gender and culture settings.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Voice Voice. Default `MSRS.Voices.Google.Standard.en_GB_Standard_A`. -- @param #string Voice (Optional) Voice. Default `MSRS.Voices.Google.Standard.en_GB_Standard_A`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetVoiceGoogle(Voice) function MSRS:SetVoiceGoogle(Voice)
self:F( {Voice=Voice} ) self:F( {Voice=Voice} )
@@ -1188,7 +1188,7 @@ end
--- Set to use a specific voice if Piper is used as provider (only Hound-TTS backend). Note that this will override any gender and culture settings. --- Set to use a specific voice if Piper is used as provider (only Hound-TTS backend). Note that this will override any gender and culture settings.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Voice [Piper Voices](https://rhasspy.github.io/piper-samples/). Default `"en_US-ryan-low"`. -- @param #string Voice (Optional) [Piper Voices](https://rhasspy.github.io/piper-samples/). Default `"en_US-ryan-low"`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetVoicePiper(Voice) function MSRS:SetVoicePiper(Voice)
self:F( {Voice=Voice} ) self:F( {Voice=Voice} )
@@ -1199,7 +1199,7 @@ end
--- Set to use a specific voice if Microsoft Azure is use as provider (only DCS-gRPC backend). Note that this will override any gender and culture settings. --- Set to use a specific voice if Microsoft Azure is use as provider (only DCS-gRPC backend). Note that this will override any gender and culture settings.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Voice [Azure Voice](https://learn.microsoft.com/azure/cognitive-services/speech-service/language-support). Default `"en-US-AriaNeural"`. -- @param #string Voice (Optional) [Azure Voice](https://learn.microsoft.com/azure/cognitive-services/speech-service/language-support). Default `"en-US-AriaNeural"`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetVoiceAzure(Voice) function MSRS:SetVoiceAzure(Voice)
self:F( {Voice=Voice} ) self:F( {Voice=Voice} )
@@ -1210,7 +1210,7 @@ end
--- Set to use a specific voice if Amazon Web Service is use as provider (only DCS-gRPC backend). Note that this will override any gender and culture settings. --- Set to use a specific voice if Amazon Web Service is use as provider (only DCS-gRPC backend). Note that this will override any gender and culture settings.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Voice [AWS Voice](https://docs.aws.amazon.com/polly/latest/dg/voicelist.html). Default `"Brian"`. -- @param #string Voice (Optional) [AWS Voice](https://docs.aws.amazon.com/polly/latest/dg/voicelist.html). Default `"Brian"`.
-- @return #MSRS self -- @return #MSRS self
function MSRS:SetVoiceAmazon(Voice) function MSRS:SetVoiceAmazon(Voice)
self:F( {Voice=Voice} ) self:F( {Voice=Voice} )
@@ -1221,7 +1221,7 @@ end
--- Get voice. --- Get voice.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Provider Provider. Default is the currently set provider (`self.provider`). -- @param #string Provider (Optional) Provider. Default is the currently set provider (`self.provider`).
-- @return #string Voice. -- @return #string Voice.
function MSRS:GetVoice(Provider) function MSRS:GetVoice(Provider)
@@ -1396,7 +1396,7 @@ end
--- Get provider options. --- Get provider options.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Provider Provider. Default is as set via @{#MSRS.SetProvider}. -- @param #string Provider (Optional) Provider. Default is as set via @{#MSRS.SetProvider}.
-- @return #MSRS.ProviderOptions Provider options. -- @return #MSRS.ProviderOptions Provider options.
function MSRS:GetProviderOptions(Provider) function MSRS:GetProviderOptions(Provider)
return self.poptions[Provider or self.provider] or {} return self.poptions[Provider or self.provider] or {}
@@ -1718,7 +1718,7 @@ end
-- @param #number volume Volume. -- @param #number volume Volume.
-- @param #number speed Speed. -- @param #number speed Speed.
-- @param #number port Port. -- @param #number port Port.
-- @param #string label Label, defaults to "ROBOT" (displayed sender name in the radio overlay of SRS) - No spaces allowed! -- @param #string label (Optional) Label, defaults to "ROBOT" (displayed sender name in the radio overlay of SRS) - No spaces allowed!
-- @param Core.Point#COORDINATE coordinate Coordinate. -- @param Core.Point#COORDINATE coordinate Coordinate.
-- @return #string Command. -- @return #string Command.
function MSRS:_GetCommand(freqs, modus, coal, gender, voice, culture, volume, speed, port, label, coordinate) function MSRS:_GetCommand(freqs, modus, coal, gender, voice, culture, volume, speed, port, label, coordinate)
@@ -2020,9 +2020,9 @@ end
-- @param #string Message The text to speak. -- @param #string Message The text to speak.
-- @param #table Frequencies The table of frequencies to use. -- @param #table Frequencies The table of frequencies to use.
-- @param #table Modulations The table of modulations to use. -- @param #table Modulations The table of modulations to use.
-- @param #number Volume The volume to use, defaults to 1.0. -- @param #number Volume (Optional) The volume to use, defaults to 1.0.
-- @param #string Label The label to use, defaults to "MSRS". -- @param #string Label (Optional) The label to use, defaults to "MSRS".
-- @param #number Coalition The coalition to use. -- @param #number Coalition (Optional) The coalition to use.
-- @param Core.Point#COORDINATE Point (Optional) The point from which the voice is sent. -- @param Core.Point#COORDINATE Point (Optional) The point from which the voice is sent.
-- @param #number Speed (Optional) How fast to speak, defaults to 1.0. -- @param #number Speed (Optional) How fast to speak, defaults to 1.0.
-- @param #string Gender (Optional) Gender to use. -- @param #string Gender (Optional) Gender to use.
@@ -2162,8 +2162,8 @@ end
--- Hound speech time calculator. Use to determine how long it takes to speak something out. --- Hound speech time calculator. Use to determine how long it takes to speak something out.
-- @param MSRS self -- @param MSRS self
-- @param #string Message The message to measure. Can also be handed as string lenght. -- @param #string Message The message to measure. Can also be handed as string lenght.
-- @param #number Speed The speed to use, defaults to 1.0. -- @param #number Speed (Optional) The speed to use, defaults to 1.0.
-- @param #boolean UseGoogle If to use google. Default: no. -- @param #boolean UseGoogle (Optional) If to use google. Default: no.
function MSRS:_HoundSpeechTime(Message,Speed,UseGoogle) function MSRS:_HoundSpeechTime(Message,Speed,UseGoogle)
local speed = Speed or 1.0 local speed = Speed or 1.0
local speechtime = HoundTTS.getSpeechTime(Message, speed, UseGoogle) local speechtime = HoundTTS.getSpeechTime(Message, speed, UseGoogle)
@@ -2176,8 +2176,8 @@ end
--- Get central SRS configuration to be able to play tts over SRS radio using the `DCS-SR-ExternalAudio.exe`. --- Get central SRS configuration to be able to play tts over SRS radio using the `DCS-SR-ExternalAudio.exe`.
-- @param #MSRS self -- @param #MSRS self
-- @param #string Path Path to config file, defaults to "C:\Users\<yourname>\Saved Games\DCS\Config" -- @param #string Path (Optional) Path to config file, defaults to "C:\Users\<yourname>\Saved Games\DCS\Config"
-- @param #string Filename File to load, defaults to "Moose_MSRS.lua" -- @param #string Filename (Optional) File to load, defaults to "Moose_MSRS.lua"
-- @return #boolean success -- @return #boolean success
-- @usage -- @usage
-- 0) Benefits: Centralize configuration of SRS, keep paths and keys out of the mission source code, making it safer and easier to move missions to/between servers, -- 0) Benefits: Centralize configuration of SRS, keep paths and keys out of the mission source code, making it safer and easier to move missions to/between servers,
@@ -2320,7 +2320,7 @@ end
-- * (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min -- * (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min
-- --
-- @param #number length can also be passed as #string -- @param #number length can also be passed as #string
-- @param #number speed Defaults to 1.0 -- @param #number speed (Optional) Defaults to 1.0
-- @param #boolean isGoogle We're using Google TTS -- @param #boolean isGoogle We're using Google TTS
function MSRS.getSpeechTime(length,speed,isGoogle) function MSRS.getSpeechTime(length,speed,isGoogle)
@@ -2477,22 +2477,22 @@ end
--- Create a new transmission and add it to the radio queue. --- Create a new transmission and add it to the radio queue.
-- @param #MSRSQUEUE self -- @param #MSRSQUEUE self
-- @param #string text Text to play. -- @param #string text Text to play.
-- @param #number duration Duration in seconds the file lasts. Default is determined by number of characters of the text message. -- @param #number duration (Optional) Duration in seconds the file lasts. Default is determined by number of characters of the text message.
-- @param Sound.SRS#MSRS msrs MOOSE SRS object. -- @param Sound.SRS#MSRS msrs MOOSE SRS object.
-- @param #number tstart Start time (abs) seconds. Default now. -- @param #number tstart (Optional) Start time (abs) seconds. Default now.
-- @param #number interval Interval in seconds after the last transmission finished. -- @param #number interval (Optional) Interval in seconds after the last transmission finished.
-- @param #table subgroups Groups that should receive the subtiltle. -- @param #table subgroups Groups that should receive the subtiltle.
-- @param #string subtitle Subtitle displayed when the message is played. -- @param #string subtitle Subtitle displayed when the message is played.
-- @param #number subduration Duration [sec] of the subtitle being displayed. Default 5 sec. -- @param #number subduration (Optional) Duration [sec] of the subtitle being displayed. Default 5 sec.
-- @param #number frequency Radio frequency if other than MSRS default. -- @param #number frequency (Optional) Radio frequency if other than MSRS default.
-- @param #number modulation Radio modulation if other then MSRS default. -- @param #number modulation (Optional) Radio modulation if other then MSRS default.
-- @param #string gender Gender of the voice -- @param #string gender (Optional) Gender of the voice
-- @param #string culture Culture of the voice -- @param #string culture C(Optional) ulture of the voice
-- @param #string voice Specific voice -- @param #string voice (Optional) Specific voice
-- @param #number volume Volume setting -- @param #number volume (Optional) Volume setting
-- @param #string label Label to be used -- @param #string label (Optional) Label to be used
-- @param Core.Point#COORDINATE coordinate Coordinate to be used -- @param Core.Point#COORDINATE coordinate (Optional) Coordinate to be used
-- @param #number speed Speed to be used -- @param #number speed (Optional) Speed to be used
-- @return #MSRSQUEUE.Transmission Radio transmission table. -- @return #MSRSQUEUE.Transmission Radio transmission table.
function MSRSQUEUE:NewTransmission(text, duration, msrs, tstart, interval, subgroups, subtitle, subduration, frequency, modulation, gender, culture, voice, volume, label,coordinate,speed) function MSRSQUEUE:NewTransmission(text, duration, msrs, tstart, interval, subgroups, subtitle, subduration, frequency, modulation, gender, culture, voice, volume, label,coordinate,speed)
self:T({Text=text, Dur=duration, start=tstart, int=interval, sub=subgroups, subt=subtitle, sudb=subduration, F=frequency, M=modulation, G=gender, C=culture, V=voice, Vol=volume, L=label, S=speed}) self:T({Text=text, Dur=duration, start=tstart, int=interval, sub=subgroups, subt=subtitle, sudb=subduration, F=frequency, M=modulation, G=gender, C=culture, V=voice, Vol=volume, L=label, S=speed})
+12 -12
View File
@@ -61,7 +61,7 @@ do -- Sound Base
-- * (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min -- * (x - in_min) * (out_max - out_min) / (in_max - in_min) + out_min
-- --
-- @param #string Text The text string to analyze. -- @param #string Text The text string to analyze.
-- @param #number Speed Speed factor. Default 1. -- @param #number Speed (Optional) Speed factor. Default 1.
-- @param #boolean isGoogle If true, google text-to-speech is used. -- @param #boolean isGoogle If true, google text-to-speech is used.
function SOUNDBASE:GetSpeechTime(length,speed,isGoogle) function SOUNDBASE:GetSpeechTime(length,speed,isGoogle)
@@ -158,9 +158,9 @@ do -- Sound File
--- Constructor to create a new SOUNDFILE object. --- Constructor to create a new SOUNDFILE object.
-- @param #SOUNDFILE self -- @param #SOUNDFILE self
-- @param #string FileName The name of the sound file, e.g. "Hello World.ogg". -- @param #string FileName The name of the sound file, e.g. "Hello World.ogg".
-- @param #string Path The path of the directory, where the sound file is located. Default is "l10n/DEFAULT/" within the miz file. -- @param #string Path (Optional) The path of the directory, where the sound file is located. Default is "l10n/DEFAULT/" within the miz file.
-- @param #number Duration Duration in seconds, how long it takes to play the sound file. Default is 3 seconds. -- @param #number Duration (Optional) Duration in seconds, how long it takes to play the sound file. Default is 3 seconds.
-- @param #boolean UseSrs Set if SRS should be used to play this file. Default is false. -- @param #boolean UseSrs (Optional) Set if SRS should be used to play this file. Default is false.
-- @return #SOUNDFILE self -- @return #SOUNDFILE self
function SOUNDFILE:New(FileName, Path, Duration, UseSrs) function SOUNDFILE:New(FileName, Path, Duration, UseSrs)
@@ -187,7 +187,7 @@ do -- Sound File
--- Set path, where the sound file is located. --- Set path, where the sound file is located.
-- @param #SOUNDFILE self -- @param #SOUNDFILE self
-- @param #string Path Path to the directory, where the sound file is located. In case this is nil, it defaults to the DCS mission temp directory. -- @param #string Path (Optional) Path to the directory, where the sound file is located. In case this is nil, it defaults to the DCS mission temp directory.
-- @return #SOUNDFILE self -- @return #SOUNDFILE self
function SOUNDFILE:SetPath(Path) function SOUNDFILE:SetPath(Path)
self:F( {Path} ) self:F( {Path} )
@@ -228,7 +228,7 @@ do -- Sound File
--- Set sound file name. This must be a .ogg or .mp3 file! --- Set sound file name. This must be a .ogg or .mp3 file!
-- @param #SOUNDFILE self -- @param #SOUNDFILE self
-- @param #string FileName Name of the file. Default is "Hello World.mp3". -- @param #string FileName (Optional) Name of the file. Default is "Hello World.mp3".
-- @return #SOUNDFILE self -- @return #SOUNDFILE self
function SOUNDFILE:SetFileName(FileName) function SOUNDFILE:SetFileName(FileName)
--TODO: check that sound file is really .ogg or .mp3 --TODO: check that sound file is really .ogg or .mp3
@@ -246,7 +246,7 @@ do -- Sound File
--- Set duration how long it takes to play the sound file. --- Set duration how long it takes to play the sound file.
-- @param #SOUNDFILE self -- @param #SOUNDFILE self
-- @param #string Duration Duration in seconds. Default 3 seconds. -- @param #string Duration (Optional) Duration in seconds. Default 3 seconds.
-- @return #SOUNDFILE self -- @return #SOUNDFILE self
function SOUNDFILE:SetDuration(Duration) function SOUNDFILE:SetDuration(Duration)
if Duration and type(Duration)=="string" then if Duration and type(Duration)=="string" then
@@ -353,7 +353,7 @@ do -- Text-To-Speech
--- Constructor to create a new SOUNDTEXT object. --- Constructor to create a new SOUNDTEXT object.
-- @param #SOUNDTEXT self -- @param #SOUNDTEXT self
-- @param #string Text The text to speak. -- @param #string Text The text to speak.
-- @param #number Duration Duration in seconds, how long it takes to play the text. Default is 3 seconds. -- @param #number Duration (Optional) Duration in seconds, how long it takes to play the text. Default is 3 seconds.
-- @return #SOUNDTEXT self -- @return #SOUNDTEXT self
function SOUNDTEXT:New(Text, Duration) function SOUNDTEXT:New(Text, Duration)
@@ -373,7 +373,7 @@ do -- Text-To-Speech
--- Set text. --- Set text.
-- @param #SOUNDTEXT self -- @param #SOUNDTEXT self
-- @param #string Text Text to speak. Default "Hello World!". -- @param #string Text (Optional) Text to speak. Default "Hello World!".
-- @return #SOUNDTEXT self -- @return #SOUNDTEXT self
function SOUNDTEXT:SetText(Text) function SOUNDTEXT:SetText(Text)
@@ -384,7 +384,7 @@ do -- Text-To-Speech
--- Set duration, how long it takes to speak the text. --- Set duration, how long it takes to speak the text.
-- @param #SOUNDTEXT self -- @param #SOUNDTEXT self
-- @param #number Duration Duration in seconds. Default 3 seconds. -- @param #number Duration (Optional) Duration in seconds. Default 3 seconds.
-- @return #SOUNDTEXT self -- @return #SOUNDTEXT self
function SOUNDTEXT:SetDuration(Duration) function SOUNDTEXT:SetDuration(Duration)
@@ -395,7 +395,7 @@ do -- Text-To-Speech
--- Set gender. --- Set gender.
-- @param #SOUNDTEXT self -- @param #SOUNDTEXT self
-- @param #string Gender Gender: "male" or "female" (default). -- @param #string Gender (Optional) Gender: "male" or "female" (default).
-- @return #SOUNDTEXT self -- @return #SOUNDTEXT self
function SOUNDTEXT:SetGender(Gender) function SOUNDTEXT:SetGender(Gender)
@@ -406,7 +406,7 @@ do -- Text-To-Speech
--- Set TTS culture - local for the voice. --- Set TTS culture - local for the voice.
-- @param #SOUNDTEXT self -- @param #SOUNDTEXT self
-- @param #string Culture TTS culture. Default "en-GB". -- @param #string Culture (Optional) TTS culture. Default "en-GB".
-- @return #SOUNDTEXT self -- @return #SOUNDTEXT self
function SOUNDTEXT:SetCulture(Culture) function SOUNDTEXT:SetCulture(Culture)
+12 -2
View File
@@ -131,14 +131,24 @@ ENUMS.WeaponFlag={
Cannons = 805306368, -- GUN_POD + BuiltInCannon Cannons = 805306368, -- GUN_POD + BuiltInCannon
--- Torpedo --- Torpedo
Torpedo = 4294967296, Torpedo = 4294967296,
--- Decoy
Decoys = 8589934592,
--- Shell
SmokeShell = 17179869184,
IlluminationShell = 34359738368,
MarkerShell = 51539607552,
MarkerWeapon = 51539620864,
SubmunitionDispenserShell = 68719476736,
ConventionalShell = 206963736576,
--- ---
-- Even More Genral -- Even More Genral
Auto = 3221225470, -- Any Weapon (AnyBomb + AnyRocket + AnyMissile + Cannons) Auto = 265214230526, -- Any Weapon (AnyBomb + AnyRocket + AnyMissile + Cannons + Torpedos)
AutoDCS = 1073741822, -- Something if often see AutoDCS = 1073741822, -- Something if often see
AnyAG = 2956984318, -- Any Air-To-Ground Weapon AnyAG = 2956984318, -- Any Air-To-Ground Weapon
AnyAA = 264241152, -- Any Air-To-Air Weapon AnyAA = 264241152, -- Any Air-To-Air Weapon
AnyUnguided = 2952822768, -- Any Unguided Weapon AnyUnguided = 2952822768, -- Any Unguided Weapon
AnyGuided = 268402702, -- Any Guided Weapon AnyGuided = 268402702, -- Any Guided Weapon
AnyShell = 258503344128, -- Any Shell
} }
--- Weapon types by category. See the [Weapon Flag](https://wiki.hoggitworld.com/view/DCS_enum_weapon_flag) enumerator on hoggit wiki. --- Weapon types by category. See the [Weapon Flag](https://wiki.hoggitworld.com/view/DCS_enum_weapon_flag) enumerator on hoggit wiki.
@@ -220,7 +230,7 @@ ENUMS.WeaponType.Torpedo={
} }
ENUMS.WeaponType.Any={ ENUMS.WeaponType.Any={
-- General combinations -- General combinations
Weapon = 3221225470, -- Any Weapon (AnyBomb + AnyRocket + AnyMissile + Cannons) Weapon = 265214230526, -- Any Weapon (AnyBomb + AnyRocket + AnyMissile + Cannons + Torpedos)
AG = 2956984318, -- Any Air-To-Ground Weapon AG = 2956984318, -- Any Air-To-Ground Weapon
AA = 264241152, -- Any Air-To-Air Weapon AA = 264241152, -- Any Air-To-Air Weapon
Unguided = 2952822768, -- Any Unguided Weapon Unguided = 2952822768, -- Any Unguided Weapon
@@ -126,8 +126,8 @@ PROFILER = {
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--- Start profiler. --- Start profiler.
-- @param #number Delay Delay in seconds before profiler is stated. Default is immediately. -- @param #number Delay (Optional) Delay in seconds before profiler is stated. Default is immediately.
-- @param #number Duration Duration in (game) seconds before the profiler is stopped. Default is when mission ends. -- @param #number Duration (Optional) Duration in (game) seconds before the profiler is stopped. Default is when mission ends.
function PROFILER.Start( Delay, Duration ) function PROFILER.Start( Delay, Duration )
-- Check if os, io and lfs are available. -- Check if os, io and lfs are available.
+7 -7
View File
@@ -77,8 +77,8 @@ SOCKET.version="0.3.0"
--- Create a new SOCKET object. --- Create a new SOCKET object.
-- @param #SOCKET self -- @param #SOCKET self
-- @param #number Port UDP port. Default `10042`. -- @param #number Port (Optional) UDP port. Default `10042`.
-- @param #string Host Host. Default `"127.0.0.1"`. -- @param #string Host (Optional) Host. Default `"127.0.0.1"`.
-- @return #SOCKET self -- @return #SOCKET self
function SOCKET:New(Port, Host) function SOCKET:New(Port, Host)
@@ -103,7 +103,7 @@ end
--- Set port. --- Set port.
-- @param #SOCKET self -- @param #SOCKET self
-- @param #number Port Port. Default 10042. -- @param #number Port (Optional) Port. Default 10042.
-- @return #SOCKET self -- @return #SOCKET self
function SOCKET:SetPort(Port) function SOCKET:SetPort(Port)
self.port=Port or 10042 self.port=Port or 10042
@@ -111,7 +111,7 @@ end
--- Set host. --- Set host.
-- @param #SOCKET self -- @param #SOCKET self
-- @param #string Host Host. Default `"127.0.0.1"`. -- @param #string Host (Optional) Host. Default `"127.0.0.1"`.
-- @return #SOCKET self -- @return #SOCKET self
function SOCKET:SetHost(Host) function SOCKET:SetHost(Host)
self.host=Host or "127.0.0.1" self.host=Host or "127.0.0.1"
@@ -159,11 +159,11 @@ end
--- Send a text-to-speech message. --- Send a text-to-speech message.
-- @param #SOCKET self -- @param #SOCKET self
-- @param #string Text The text message to speek. -- @param #string Text The text message to speek.
-- @param #number Provider The TTS provider: 0=Microsoft (default), 1=Google. -- @param #number Provider (Optional) The TTS provider: 0=Microsoft (default), 1=Google.
-- @param #string Voice The specific voice to use, e.g. `"Microsoft David Desktop"` or "`en-US-Standard-A`". If not set, the service will choose a voice based on the other parameters such as culture and gender. -- @param #string Voice The specific voice to use, e.g. `"Microsoft David Desktop"` or "`en-US-Standard-A`". If not set, the service will choose a voice based on the other parameters such as culture and gender.
-- @param #string Culture The Culture or language code, *e.g.* `"en-US"`. -- @param #string Culture The Culture or language code, *e.g.* `"en-US"`.
-- @param #string Gender The Gender, *i.e.* "male", "female". Default "female". -- @param #string Gender (Optional) The Gender, *i.e.* "male", "female". Default "female".
-- @param #number Volume The volume. Microsoft: [0,100] default 50, Google: [-96, 10] default 0. -- @param #number Volume (Optional) The volume. Microsoft: [0,100] default 50, Google: [-96, 10] default 0.
-- @return #SOCKET self -- @return #SOCKET self
function SOCKET:SendTextToSpeech(Text, Provider, Voice, Culture, Gender, Volume) function SOCKET:SendTextToSpeech(Text, Provider, Voice, Culture, Gender, Volume)
+125 -91
View File
@@ -522,43 +522,77 @@ function UTILS.TableLength(T)
end end
--- Print a table to log in a nice format --- Print a table to log in a nice format
-- @param #table table The table to print -- @param #table t The table to print
-- @param #number indent Number of indents -- @param #number indent (Optional) Number of indents. Defaults to 0.
-- @param #boolean noprint Don't log but return text -- @param #boolean noprint Don't log but return text
-- @param #number maxDepth (Optional) Only cycle this deep, defaults to 5.
-- @param #table seen (Optional)
-- @return #string text Text created on the fly of the log output -- @return #string text Text created on the fly of the log output
function UTILS.PrintTableToLog(table, indent, noprint) function UTILS.PrintTableToLog(t, indent, noprint, maxDepth, seen)
local text = "\n" maxDepth = maxDepth or 5
if not table or type(table) ~= "table" then indent = indent or 0
seen = seen or {}
if not t or type(t) ~= "table" then
env.warning("No table passed!") env.warning("No table passed!")
return nil return nil
end end
if not indent then indent = 0 end
for k, v in pairs(table) do -- Max depth guard
if string.find(k," ") then k='"'..k..'"'end if indent > maxDepth then
if type(v) == "table" and UTILS.TableLength(v) > 0 then local msg = string.rep(" ", indent) .. "<max depth reached>\n"
if not noprint then if not noprint then env.info(msg) end
env.info(string.rep(" ", indent) .. tostring(k) .. " = {") return msg
end end
text = text ..string.rep(" ", indent) .. tostring(k) .. " = {\n"
text = text .. tostring(UTILS.PrintTableToLog(v, indent + 1), noprint).."\n" -- Cycle / repeated reference guard
if seen[t] then
local msg = string.rep(" ", indent) .. "<cycle>\n"
if not noprint then env.info(msg) end
return msg
end
seen[t] = true
local text = "\n"
for k, v in pairs(t) do
local key = k
if type(key) == "string" and key:find(" ", 1, true) then
key = '"' .. key .. '"'
else
key = tostring(key)
end
if type(v) == "table" and next(v) ~= nil then
if not noprint then
env.info(string.rep(" ", indent) .. key .. " = {")
end
text = text .. string.rep(" ", indent) .. key .. " = {\n"
text = text .. UTILS.PrintTableToLog(v, indent + 1, noprint, maxDepth, seen)
text = text .. string.rep(" ", indent) .. "},\n"
if not noprint then if not noprint then
env.info(string.rep(" ", indent) .. "},") env.info(string.rep(" ", indent) .. "},")
end end
text = text .. string.rep(" ", indent) .. "},\n"
elseif type(v) == "function" then elseif type(v) == "function" then
-- skip functions (optional: log "<function>")
else else
local value local value
if tostring(v) == "true" or tostring(v) == "false" or tonumber(v) ~= nil then if type(v) == "boolean" or type(v) == "number" then
value=v value = tostring(v)
else else
value = '"' .. tostring(v) .. '"' value = '"' .. tostring(v) .. '"'
end end
if not noprint then if not noprint then
env.info(string.rep(" ", indent) .. tostring(k) .. " = " .. tostring(value)..",\n") env.info(string.rep(" ", indent) .. key .. " = " .. value .. ",")
end end
text = text .. string.rep(" ", indent) .. tostring(k) .. " = " .. tostring(value)..",\n" text = text .. string.rep(" ", indent) .. key .. " = " .. value .. ",\n"
end end
end end
return text return text
end end
@@ -1339,7 +1373,7 @@ function UTILS.ClockToSeconds(clock)
end end
--- Display clock and mission time on screen as a message to all. --- Display clock and mission time on screen as a message to all.
-- @param #number duration Duration in seconds how long the time is displayed. Default is 5 seconds. -- @param #number duration (Optional) Duration in seconds how long the time is displayed. Default is 5 seconds.
function UTILS.DisplayMissionTime(duration) function UTILS.DisplayMissionTime(duration)
duration=duration or 5 duration=duration or 5
local Tnow=timer.getAbsTime() local Tnow=timer.getAbsTime()
@@ -1353,7 +1387,7 @@ end
--- Replace illegal characters [<>|/?*:\\] in a string. --- Replace illegal characters [<>|/?*:\\] in a string.
-- @param #string Text Input text. -- @param #string Text Input text.
-- @param #string ReplaceBy Replace illegal characters by this character or string. Default underscore "_". -- @param #string ReplaceBy (Optional) Replace illegal characters by this character or string. Default underscore "_".
-- @return #string The input text with illegal chars replaced. -- @return #string The input text with illegal chars replaced.
function UTILS.ReplaceIllegalCharacters(Text, ReplaceBy) function UTILS.ReplaceIllegalCharacters(Text, ReplaceBy)
ReplaceBy=ReplaceBy or "_" ReplaceBy=ReplaceBy or "_"
@@ -2227,7 +2261,7 @@ function UTILS.GetSunRiseAndSet(DayOfYear, Latitude, Longitude, Rising, Tlocal)
-- @param #number Latitude Latitude. -- @param #number Latitude Latitude.
-- @param #number Longitude Longitude. -- @param #number Longitude Longitude.
-- @param #boolean Rising If true, calc sun rise, or sun set otherwise. -- @param #boolean Rising If true, calc sun rise, or sun set otherwise.
-- @param #number Tlocal Local time offset in hours. E.g. +4 for a location which has GMT+4. Default 0. -- @param #number Tlocal (Optional) Local time offset in hours. E.g. +4 for a location which has GMT+4. Default 0.
-- @return #number Sun rise in seconds of the day. -- @return #number Sun rise in seconds of the day.
function UTILS.GetSunrise(Day, Month, Year, Latitude, Longitude, Tlocal) function UTILS.GetSunrise(Day, Month, Year, Latitude, Longitude, Tlocal)
@@ -2243,7 +2277,7 @@ end
-- @param #number Latitude Latitude. -- @param #number Latitude Latitude.
-- @param #number Longitude Longitude. -- @param #number Longitude Longitude.
-- @param #boolean Rising If true, calc sun rise, or sun set otherwise. -- @param #boolean Rising If true, calc sun rise, or sun set otherwise.
-- @param #number Tlocal Local time offset in hours. E.g. +4 for a location which has GMT+4. Default 0. -- @param #number Tlocal (Optional) Local time offset in hours. E.g. +4 for a location which has GMT+4. Default 0.
-- @return #number Sun rise in seconds of the day. -- @return #number Sun rise in seconds of the day.
function UTILS.GetSunset(Day, Month, Year, Latitude, Longitude, Tlocal) function UTILS.GetSunset(Day, Month, Year, Latitude, Longitude, Tlocal)
@@ -2921,12 +2955,12 @@ end
-- @param #boolean Reduce If false, existing loaded groups will not be reduced to fit the saved number. -- @param #boolean Reduce If false, existing loaded groups will not be reduced to fit the saved number.
-- @param #boolean Structured (Optional, needs Reduce = true) If true, and the data has been saved as structure before, remove the correct unit types as per the saved list. -- @param #boolean Structured (Optional, needs Reduce = true) If true, and the data has been saved as structure before, remove the correct unit types as per the saved list.
-- @param #boolean Cinematic (Optional, needs Structured = true) If true, place a fire/smoke effect on the dead static position. -- @param #boolean Cinematic (Optional, needs Structured = true) If true, place a fire/smoke effect on the dead static position.
-- @param #number Effect (Optional for Cinematic) What effect to use. Defaults to a random effect. Smoke presets are: 1=small smoke and fire, 2=medium smoke and fire, 3=large smoke and fire, 4=huge smoke and fire, 5=small smoke, 6=medium smoke, 7=large smoke, 8=huge smoke. -- @param #number Effect (Optional) (Optional for Cinematic) What effect to use. Defaults to a random effect. Smoke presets are: 1=small smoke and fire, 2=medium smoke and fire, 3=large smoke and fire, 4=huge smoke and fire, 5=small smoke, 6=medium smoke, 7=large smoke, 8=huge smoke.
-- @param #number Density (Optional for Cinematic) What smoke density to use, can be 0 to 1. Defaults to 0.5. -- @param #number Density (Optional) (Optional for Cinematic) What smoke density to use, can be 0 to 1. Defaults to 0.5.
-- @param #boolean Resurrection If true, dead units can be restored on load. Defaults to false. -- @param #boolean Resurrection (Optional) If true, dead units can be restored on load. Defaults to false.
-- @param #number ResurrectPercentage Use this percentage of probability to resurrect a unit. [0..100], defaults to 25. -- @param #number ResurrectPercentage (Optional) Use this percentage of probability to resurrect a unit. [0..100], defaults to 25.
-- @param #number Healmin If set, life points of a resurrected unit will be randomly restored to min this percentage. [0..100], defaults to 25. -- @param #number Healmin (Optional) If set, life points of a resurrected unit will be randomly restored to min this percentage. [0..100], defaults to 25.
-- @param #number Healmax If set, life points of a resurrected unit will be randomly restored to max this percentage. [0..100], defaults to 75. -- @param #number Healmax (Optional) If set, life points of a resurrected unit will be randomly restored to max this percentage. [0..100], defaults to 75.
-- @return #table Table of data objects (tables) containing groupname, coordinate and group object. Returns nil when file cannot be read. -- @return #table Table of data objects (tables) containing groupname, coordinate and group object. Returns nil when file cannot be read.
-- @return #table When using Cinematic: table of names of smoke and fire objects, so they can be extinguished with `COORDINATE.StopBigSmokeAndFire( name )` -- @return #table When using Cinematic: table of names of smoke and fire objects, so they can be extinguished with `COORDINATE.StopBigSmokeAndFire( name )`
function UTILS.LoadStationaryListOfGroups(Path,Filename,Reduce,Structured,Cinematic,Effect,Density,Resurrection,ResurrectPercentage,Healmin,Healmax) function UTILS.LoadStationaryListOfGroups(Path,Filename,Reduce,Structured,Cinematic,Effect,Density,Resurrection,ResurrectPercentage,Healmin,Healmax)
@@ -3049,8 +3083,8 @@ end
-- @param #boolean Spawn If set to false, do not re-spawn the groups loaded in location and reduce to size. -- @param #boolean Spawn If set to false, do not re-spawn the groups loaded in location and reduce to size.
-- @param #boolean Structured (Optional, needs Spawn=true)If true, and the data has been saved as structure before, remove the correct unit types as per the saved list. -- @param #boolean Structured (Optional, needs Spawn=true)If true, and the data has been saved as structure before, remove the correct unit types as per the saved list.
-- @param #boolean Cinematic (Optional, needs Structured=true) If true, place a fire/smoke effect on the dead static position. -- @param #boolean Cinematic (Optional, needs Structured=true) If true, place a fire/smoke effect on the dead static position.
-- @param #number Effect (Optional for Cinematic) What effect to use. Defaults to a random effect. Smoke presets are: 1=small smoke and fire, 2=medium smoke and fire, 3=large smoke and fire, 4=huge smoke and fire, 5=small smoke, 6=medium smoke, 7=large smoke, 8=huge smoke. -- @param #number Effect (Optional) (Optional for Cinematic) What effect to use. Defaults to a random effect. Smoke presets are: 1=small smoke and fire, 2=medium smoke and fire, 3=large smoke and fire, 4=huge smoke and fire, 5=small smoke, 6=medium smoke, 7=large smoke, 8=huge smoke.
-- @param #number Density (Optional for Cinematic) What smoke density to use, can be 0 to 1. Defaults to 0.5. -- @param #number Density (Optional) (Optional for Cinematic) What smoke density to use, can be 0 to 1. Defaults to 0.5.
-- @return Core.Set#SET_GROUP Set of GROUP objects. -- @return Core.Set#SET_GROUP Set of GROUP objects.
-- Returns nil when file cannot be read. Returns a table of data entries if Spawn is false: `{ groupname=groupname, size=size, coordinate=coordinate, template=template }` -- Returns nil when file cannot be read. Returns a table of data entries if Spawn is false: `{ groupname=groupname, size=size, coordinate=coordinate, template=template }`
-- @return #table When using Cinematic: table of names of smoke and fire objects, so they can be extinguished with `COORDINATE.StopBigSmokeAndFire( name )` -- @return #table When using Cinematic: table of names of smoke and fire objects, so they can be extinguished with `COORDINATE.StopBigSmokeAndFire( name )`
@@ -3235,8 +3269,8 @@ end
-- @param #boolean Reduce If false, do not destroy the units with size=0. -- @param #boolean Reduce If false, do not destroy the units with size=0.
-- @param #boolean Dead (Optional, needs Reduce = true) If Dead is true, re-spawn the dead object as dead and do not just delete it. -- @param #boolean Dead (Optional, needs Reduce = true) If Dead is true, re-spawn the dead object as dead and do not just delete it.
-- @param #boolean Cinematic (Optional, needs Dead = true) If true, place a fire/smoke effect on the dead static position. -- @param #boolean Cinematic (Optional, needs Dead = true) If true, place a fire/smoke effect on the dead static position.
-- @param #number Effect (Optional for Cinematic) What effect to use. Defaults to a random effect. Smoke presets are: 1=small smoke and fire, 2=medium smoke and fire, 3=large smoke and fire, 4=huge smoke and fire, 5=small smoke, 6=medium smoke, 7=large smoke, 8=huge smoke. -- @param #number Effect (Optional) (Optional for Cinematic) What effect to use. Defaults to a random effect. Smoke presets are: 1=small smoke and fire, 2=medium smoke and fire, 3=large smoke and fire, 4=huge smoke and fire, 5=small smoke, 6=medium smoke, 7=large smoke, 8=huge smoke.
-- @param #number Density (Optional for Cinematic) What smoke density to use, can be 0 to 1. Defaults to 0.5. -- @param #number Density (Optional) (Optional for Cinematic) What smoke density to use, can be 0 to 1. Defaults to 0.5.
-- @return #table Table of data objects (tables) containing staticname, size (0=dead else 1), coordinate and the static object. Dead objects will have coordinate points `{x=0,y=0,z=0}` -- @return #table Table of data objects (tables) containing staticname, size (0=dead else 1), coordinate and the static object. Dead objects will have coordinate points `{x=0,y=0,z=0}`
-- @return #table When using Cinematic: table of names of smoke and fire objects, so they can be extinguished with `COORDINATE.StopBigSmokeAndFire( name )` -- @return #table When using Cinematic: table of names of smoke and fire objects, so they can be extinguished with `COORDINATE.StopBigSmokeAndFire( name )`
-- Returns nil when file cannot be read. -- Returns nil when file cannot be read.
@@ -3405,13 +3439,13 @@ end
--- Helper function to plot a racetrack on the F10 Map - curtesy of Buur. --- Helper function to plot a racetrack on the F10 Map - curtesy of Buur.
-- @param Core.Point#COORDINATE Coordinate -- @param Core.Point#COORDINATE Coordinate
-- @param #number Altitude Altitude in feet -- @param #number Altitude Altitude in feet
-- @param #number Speed Speed in knots -- @param #number Speed (Optional) Speed in knots. Defaults to 350.
-- @param #number Heading Heading in degrees -- @param #number Heading (Optional) Heading in degrees. Defaults to 270.
-- @param #number Leg Leg in NM -- @param #number Leg (Optional) Leg in NM. Defaults to 10nm.
-- @param #number Coalition Coalition side, e.g. coaltion.side.RED or coaltion.side.BLUE -- @param #number Coalition (Optional) Coalition side, e.g. coaltion.side.RED or coaltion.side.BLUE. Defaults to -1.
-- @param #table Color Color of the line in RGB, e.g. {1,0,0} for red -- @param #table Color (Optional) Color of the line in RGB, e.g. {1,0,0} for red, Defaults to {1,0,0}.
-- @param #number Alpha Transparency factor, between 0.1 and 1 -- @param #number Alpha (Optional) Transparency factor, between 0.1 and 1. Defaults to 1.
-- @param #number LineType Line type to be used, line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid. -- @param #number LineType (Optional) Line type to be used, line type: 0=No line, 1=Solid, 2=Dashed, 3=Dotted, 4=Dot dash, 5=Long dash, 6=Two dash. Default 1=Solid.
-- @param #boolean ReadOnly -- @param #boolean ReadOnly
function UTILS.PlotRacetrack(Coordinate, Altitude, Speed, Heading, Leg, Coalition, Color, Alpha, LineType, ReadOnly) function UTILS.PlotRacetrack(Coordinate, Altitude, Speed, Heading, Leg, Coalition, Color, Alpha, LineType, ReadOnly)
local fix_coordinate = Coordinate local fix_coordinate = Coordinate
@@ -4214,7 +4248,7 @@ function UTILS.ReadCSV(filename)
end end
--- Seed the LCG random number generator. --- Seed the LCG random number generator.
-- @param #number seed Seed value. Default is a random number using math.random() -- @param #number seed (Optional) Seed value. Default is a random number using math.random()
function UTILS.LCGRandomSeed(seed) function UTILS.LCGRandomSeed(seed)
UTILS.lcg = { UTILS.lcg = {
seed = seed or math.random(1, 2^32 - 1), seed = seed or math.random(1, 2^32 - 1),
@@ -4278,24 +4312,24 @@ end
-- References: [DCS Forum Topic](https://forum.dcs.world/topic/282989-farp-equipment-to-run-it) -- References: [DCS Forum Topic](https://forum.dcs.world/topic/282989-farp-equipment-to-run-it)
-- @param #string Name Name of this FARP installation. Must be unique. -- @param #string Name Name of this FARP installation. Must be unique.
-- @param Core.Point#COORDINATE Coordinate Where to spawn the FARP. -- @param Core.Point#COORDINATE Coordinate Where to spawn the FARP.
-- @param #string FARPType Type of FARP, can be one of the known types ENUMS.FARPType.FARP, ENUMS.FARPType.INVISIBLE, ENUMS.FARPType.HELIPADSINGLE, ENUMS.FARPType.PADSINGLE. Defaults to ENUMS.FARPType.FARP. -- @param #string FARPType (Optional) Type of FARP, can be one of the known types ENUMS.FARPType.FARP, ENUMS.FARPType.INVISIBLE, ENUMS.FARPType.HELIPADSINGLE, ENUMS.FARPType.PADSINGLE. Defaults to ENUMS.FARPType.FARP.
-- @param #number Coalition Coalition of this FARP, i.e. coalition.side.BLUE or coalition.side.RED, defaults to coalition.side.BLUE. -- @param #number Coalition (Optional) Coalition of this FARP, i.e. coalition.side.BLUE or coalition.side.RED, defaults to coalition.side.BLUE.
-- @param #number Country Country of this FARP, defaults to country.id.USA (blue) or country.id.RUSSIA (red). -- @param #number Country (Optional) Country of this FARP, defaults to country.id.USA (blue) or country.id.RUSSIA (red).
-- @param #number CallSign Callsign of the FARP ATC, defaults to CALLSIGN.FARP.Berlin. -- @param #number CallSign (Optional) Callsign of the FARP ATC, defaults to CALLSIGN.FARP.Berlin.
-- @param #number Frequency Frequency of the FARP ATC Radio, defaults to 127.5 (MHz). -- @param #number Frequency (Optional) Frequency of the FARP ATC Radio, defaults to 127.5 (MHz).
-- @param #number Modulation Modulation of the FARP ATC Radio, defaults to radio.modulation.AM. -- @param #number Modulation (Optional) Modulation of the FARP ATC Radio, defaults to radio.modulation.AM.
-- @param #number ADF ADF Beacon (FM) Frequency in KHz, e.g. 428. If not nil, creates an VHF/FM ADF Beacon for this FARP. Requires a sound called "beacon.ogg" to be in the mission (trigger "sound to" ...) -- @param #number ADF ADF Beacon (FM) Frequency in KHz, e.g. 428. If not nil, creates an VHF/FM ADF Beacon for this FARP. Requires a sound called "beacon.ogg" to be in the mission (trigger "sound to" ...)
-- @param #number SpawnRadius Radius of the FARP, i.e. where the FARP objects will be placed in meters, not more than 150m away. Defaults to 100. -- @param #number SpawnRadius (Optional) Radius of the FARP, i.e. where the FARP objects will be placed in meters, not more than 150m away. Defaults to 100.
-- @param #string VehicleTemplate, template name for additional vehicles. Can be nil for no additional vehicles. -- @param #string VehicleTemplate, template name for additional vehicles. Can be nil for no additional vehicles.
-- @param #number Liquids Tons of fuel to be added initially to the FARP. Defaults to 10 (tons). Set to 0 for no fill. -- @param #number Liquids (Optional) Tons of fuel to be added initially to the FARP. Defaults to 10 (tons). Set to 0 for no fill.
-- @param #number Equipment Number of equipment items per known item to be added initially to the FARP. Defaults to 10 (items). Set to 0 for no fill. -- @param #number Equipment(Optional) Number of equipment items per known item to be added initially to the FARP. Defaults to 10 (items). Set to 0 for no fill.
-- @param #number Airframes Number of helicopter airframes per known type in Ops.CSAR#CSAR.AircraftType to be added initially to the FARP. Set to 0 for no airframes. -- @param #number Airframes Number of helicopter airframes per known type in Ops.CSAR#CSAR.AircraftType to be added initially to the FARP. Set to 0 for no airframes.
-- @param #string F10Text Text to display on F10 map if given. Handy to post things like the ADF beacon Frequency, Callsign and ATC Frequency. -- @param #string F10Text Text to display on F10 map if given. Handy to post things like the ADF beacon Frequency, Callsign and ATC Frequency.
-- @param #boolean DynamicSpawns If true, allow Dynamic Spawns from this FARP. -- @param #boolean DynamicSpawns If true, allow Dynamic Spawns from this FARP.
-- @param #boolean HotStart If true and DynamicSpawns is true, allow hot starts for Dynamic Spawns from this FARP. -- @param #boolean HotStart If true and DynamicSpawns is true, allow hot starts for Dynamic Spawns from this FARP.
-- @param #number NumberPads If given, spawn this number of pads. -- @param #number NumberPads If given, spawn this number of pads.
-- @param #number SpacingX For NumberPads > 1, space this many meters horizontally. Defaults to 100. -- @param #number SpacingX (Optional) For NumberPads > 1, space this many meters horizontally. Defaults to 100.
-- @param #number SpacingY For NumberPads > 1, space this many meters vertically. Defaults to 100. -- @param #number SpacingY (Optional) For NumberPads > 1, space this many meters vertically. Defaults to 100.
-- @return #list<Wrapper.Static#STATIC> Table of spawned objects and vehicle object (if given). -- @return #list<Wrapper.Static#STATIC> Table of spawned objects and vehicle object (if given).
-- @return #string ADFBeaconName Name of the ADF beacon, to be able to remove/stop it later. -- @return #string ADFBeaconName Name of the ADF beacon, to be able to remove/stop it later.
-- @return #number MarkerID ID of the F10 Text, to be able to remove it later. -- @return #number MarkerID ID of the F10 Text, to be able to remove it later.
@@ -4480,9 +4514,9 @@ end
-- @param #number ADF (Optional) ADF Frequency in kHz (Kilohertz), if given activate an ADF Beacon at the location of the MASH. -- @param #number ADF (Optional) ADF Frequency in kHz (Kilohertz), if given activate an ADF Beacon at the location of the MASH.
-- @param #string Livery (Optional) The livery of the static CH-47, defaults to dark green. -- @param #string Livery (Optional) The livery of the static CH-47, defaults to dark green.
-- @param #boolean DeployHelo (Optional) If true, deploy the helicopter static. -- @param #boolean DeployHelo (Optional) If true, deploy the helicopter static.
-- @param #number MASHRadio MASH Radio Frequency, defaults to 127.5. -- @param #number MASHRadio (Optional) MASH Radio Frequency, defaults to 127.5.
-- @param #number MASHRadioModulation MASH Radio Modulation, defaults to radio.modulation.AM. -- @param #number MASHRadioModulation (Optional) MASH Radio Modulation, defaults to radio.modulation.AM.
-- @param #number MASHCallsign Defaults to CALLSIGN.FARP.Berlin. -- @param #number MASHCallsign (Optional) Defaults to CALLSIGN.FARP.Berlin.
-- @param #table Templates (Optional) You can hand in your own template table of numbered(!) entries. Each entry consist of a relative(!) x,y position and data of a -- @param #table Templates (Optional) You can hand in your own template table of numbered(!) entries. Each entry consist of a relative(!) x,y position and data of a
-- static, shape_name is optional. Also, livery_id is optional, but is applied to the helicopter static only. -- static, shape_name is optional. Also, livery_id is optional, but is applied to the helicopter static only.
-- @return #table Table of Wrapper.Static#STATIC objects that were spawned. -- @return #table Table of Wrapper.Static#STATIC objects that were spawned.
@@ -4826,13 +4860,13 @@ end
--- Show a picture on the screen to all --- Show a picture on the screen to all
-- @param #string FileName File name of the picture -- @param #string FileName File name of the picture
-- @param #number Duration Duration in seconds, defaults to 10 -- @param #number Duration (Optional) Duration in seconds, defaults to 10
-- @param #boolean ClearView If true, clears the view before showing the picture, defaults to false -- @param #boolean ClearView (Optional) If true, clears the view before showing the picture, defaults to false
-- @param #number StartDelay Delay in seconds before showing the picture, defaults to 0 -- @param #number StartDelay (Optional) Delay in seconds before showing the picture, defaults to 0
-- @param #number HorizontalAlign Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right -- @param #number HorizontalAlign (Optional) Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right. Defaults to 1.
-- @param #number VerticalAlign Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom -- @param #number VerticalAlign (Optional) Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom. Defaults to 1.
-- @param #number Size Size of the picture in percent, defaults to 100 -- @param #number Size (Optional) Size of the picture in percent, defaults to 100
-- @param #number SizeUnits Size units, 0 for % of original picture size, and 1 for % of window size -- @param #number SizeUnits (Optional) Size units, 0 for % of original picture size, and 1 for % of window size. Defaults to 0.
function UTILS.ShowPictureToAll(FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits) function UTILS.ShowPictureToAll(FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits)
ClearView = ClearView or false ClearView = ClearView or false
StartDelay = StartDelay or 0 StartDelay = StartDelay or 0
@@ -4849,13 +4883,13 @@ end
--- Show a picture on the screen to Coalition --- Show a picture on the screen to Coalition
-- @param #number Coalition Coalition ID, can be coalition.side.BLUE, coalition.side.RED or coalition.side.NEUTRAL -- @param #number Coalition Coalition ID, can be coalition.side.BLUE, coalition.side.RED or coalition.side.NEUTRAL
-- @param #string FileName File name of the picture -- @param #string FileName File name of the picture
-- @param #number Duration Duration in seconds, defaults to 10 -- @param #number Duration (Optional) Duration in seconds, defaults to 10
-- @param #boolean ClearView If true, clears the view before showing the picture, defaults to false -- @param #boolean ClearView (Optional) If true, clears the view before showing the picture, defaults to false
-- @param #number StartDelay Delay in seconds before showing the picture, defaults to 0 -- @param #number StartDelay (Optional) Delay in seconds before showing the picture, defaults to 0
-- @param #number HorizontalAlign Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right -- @param #number HorizontalAlign (Optional) Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right. Defaults to 1.
-- @param #number VerticalAlign Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom -- @param #number VerticalAlign (Optional) Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom. Defaults to 1.
-- @param #number Size Size of the picture in percent, defaults to 100 -- @param #number Size (Optional) Size of the picture in percent, defaults to 100
-- @param #number SizeUnits Size units, 0 for % of original picture size, and 1 for % of window size -- @param #number SizeUnits (Optional) Size units, 0 for % of original picture size, and 1 for % of window size. Defaults to 0.
function UTILS.ShowPictureToCoalition(Coalition, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits) function UTILS.ShowPictureToCoalition(Coalition, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits)
ClearView = ClearView or false ClearView = ClearView or false
StartDelay = StartDelay or 0 StartDelay = StartDelay or 0
@@ -4874,13 +4908,13 @@ end
--- Show a picture on the screen to Country --- Show a picture on the screen to Country
-- @param #number Country Country ID, can be country.id.USA, country.id.RUSSIA, etc. -- @param #number Country Country ID, can be country.id.USA, country.id.RUSSIA, etc.
-- @param #string FileName File name of the picture -- @param #string FileName File name of the picture
-- @param #number Duration Duration in seconds, defaults to 10 -- @param #number Duration (Optional) Duration in seconds, defaults to 10
-- @param #boolean ClearView If true, clears the view before showing the picture, defaults to false -- @param #boolean ClearView (Optional) If true, clears the view before showing the picture, defaults to false
-- @param #number StartDelay Delay in seconds before showing the picture, defaults to 0 -- @param #number StartDelay (Optional) Delay in seconds before showing the picture, defaults to 0
-- @param #number HorizontalAlign Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right -- @param #number HorizontalAlign (Optional) Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right. Defaults to 1.
-- @param #number VerticalAlign Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom -- @param #number VerticalAlign (Optional) Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom. Defaults to 1.
-- @param #number Size Size of the picture in percent, defaults to 100 -- @param #number Size(Optional) Size of the picture in percent, defaults to 100
-- @param #number SizeUnits Size units, 0 for % of original picture size, and 1 for % of window size -- @param #number SizeUnits (Optional) Size units, 0 for % of original picture size, and 1 for % of window size. Defaults to 0.
function UTILS.ShowPictureToCountry(Country, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits) function UTILS.ShowPictureToCountry(Country, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits)
ClearView = ClearView or false ClearView = ClearView or false
StartDelay = StartDelay or 0 StartDelay = StartDelay or 0
@@ -4897,13 +4931,13 @@ end
--- Show a picture on the screen to Group --- Show a picture on the screen to Group
-- @param Wrapper.Group#GROUP Group Group to show the picture to -- @param Wrapper.Group#GROUP Group Group to show the picture to
-- @param #string FileName File name of the picture -- @param #string FileName File name of the picture
-- @param #number Duration Duration in seconds, defaults to 10 -- @param #number Duration (Optional) Duration in seconds, defaults to 10
-- @param #boolean ClearView If true, clears the view before showing the picture, defaults to false -- @param #boolean ClearView (Optional) If true, clears the view before showing the picture, defaults to false
-- @param #number StartDelay Delay in seconds before showing the picture, defaults to 0 -- @param #number StartDelay (Optional) Delay in seconds before showing the picture, defaults to 0
-- @param #number HorizontalAlign Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right -- @param #number HorizontalAlign (Optional) Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right. Defaults to 1.
-- @param #number VerticalAlign Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom -- @param #number VerticalAlign (Optional) Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom. Defaults to 1.
-- @param #number Size Size of the picture in percent, defaults to 100 -- @param #number Size (Optional) Size of the picture in percent, defaults to 100
-- @param #number SizeUnits Size units, 0 for % of original picture size, and 1 for % of window size -- @param #number SizeUnits (Optional) Size units, 0 for % of original picture size, and 1 for % of window size. Defaults to 0.
function UTILS.ShowPictureToGroup(Group, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits) function UTILS.ShowPictureToGroup(Group, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits)
ClearView = ClearView or false ClearView = ClearView or false
StartDelay = StartDelay or 0 StartDelay = StartDelay or 0
@@ -4920,13 +4954,13 @@ end
--- Show a picture on the screen to Unit --- Show a picture on the screen to Unit
-- @param Wrapper.Unit#UNIT Unit Unit to show the picture to -- @param Wrapper.Unit#UNIT Unit Unit to show the picture to
-- @param #string FileName File name of the picture -- @param #string FileName File name of the picture
-- @param #number Duration Duration in seconds, defaults to 10 -- @param #number Duration (Optional) Duration in seconds, defaults to 10
-- @param #boolean ClearView If true, clears the view before showing the picture, defaults to false -- @param #boolean ClearView (Optional) If true, clears the view before showing the picture, defaults to false
-- @param #number StartDelay Delay in seconds before showing the picture, defaults to 0 -- @param #number StartDelay (Optional) Delay in seconds before showing the picture, defaults to 0
-- @param #number HorizontalAlign Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right -- @param #number HorizontalAlign (Optional) Horizontal alignment of the picture, 0: Left, 1: Center, 2: Right. Defaults to 1.
-- @param #number VerticalAlign Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom -- @param #number VerticalAlign (Optional) Vertical alignment of the picture, 0: Top, 1: Center, 2: Bottom. Defaults to 1.
-- @param #number Size Size of the picture in percent, defaults to 100 -- @param #number Size (Optional) Size of the picture in percent, defaults to 100
-- @param #number SizeUnits Size units, 0 for % of original picture size, and 1 for % of window size -- @param #number SizeUnits (Optional) Size units, 0 for % of original picture size, and 1 for % of window size. Defaults to 0.
function UTILS.ShowPictureToUnit(Unit, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits) function UTILS.ShowPictureToUnit(Unit, FilePath, Duration, ClearView, StartDelay, HorizontalAlign, VerticalAlign, Size, SizeUnits)
ClearView = ClearView or false ClearView = ClearView or false
StartDelay = StartDelay or 0 StartDelay = StartDelay or 0
@@ -4948,8 +4982,8 @@ end
--- Set the mission briefing for a coalition. --- Set the mission briefing for a coalition.
-- @param #number Coalition Briefing coalition ID, can be coalition.side.BLUE, coalition.side.RED or coalition.side.NEUTRAL -- @param #number Coalition Briefing coalition ID, can be coalition.side.BLUE, coalition.side.RED or coalition.side.NEUTRAL
-- @param #string Text Briefing text, can contain newlines, will be converted formatted properly for DCS -- @param #string Text Briefing text, can contain newlines, will be converted formatted properly for DCS.
-- @param #string Picture Picture file path, can be a file in the DEFAULT folder inside the .miz -- @param #string Picture (Optional) Picture file path, can be a file in the DEFAULT folder inside the .miz. Defaults to "".
function UTILS.SetMissionBriefing(Coalition, Text, Picture) function UTILS.SetMissionBriefing(Coalition, Text, Picture)
Text = Text or "" Text = Text or ""
Text = Text:gsub("\n", "\\n") Text = Text:gsub("\n", "\\n")
+11 -11
View File
@@ -2164,7 +2164,7 @@ end
--- Get number of parking spots at an airbase. Optionally, a specific terminal type can be requested. --- Get number of parking spots at an airbase. Optionally, a specific terminal type can be requested.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #AIRBASE.TerminalType termtype Terminal type of which the number of spots is counted. Default all spots but spawn points on runway. -- @param #AIRBASE.TerminalType termtype (Optional) Terminal type of which the number of spots is counted. Default all spots but spawn points on runway.
-- @return #number Number of parking spots at this airbase. -- @return #number Number of parking spots at this airbase.
function AIRBASE:GetParkingSpotsNumber(termtype) function AIRBASE:GetParkingSpotsNumber(termtype)
@@ -2184,7 +2184,7 @@ end
--- Get number of free parking spots at an airbase. --- Get number of free parking spots at an airbase.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #AIRBASE.TerminalType termtype Terminal type. -- @param #AIRBASE.TerminalType termtype Terminal type.
-- @param #boolean allowTOAC If true, spots are considered free even though TO_AC is true. Default is off which is saver to avoid spawning aircraft on top of each other. Option might be enabled for FARPS and ships. -- @param #boolean allowTOAC (Optional) If true, spots are considered free even though TO_AC is true. Default is off which is saver to avoid spawning aircraft on top of each other. Option might be enabled for FARPS and ships.
-- @return #number Number of free parking spots at this airbase. -- @return #number Number of free parking spots at this airbase.
function AIRBASE:GetFreeParkingSpotsNumber(termtype, allowTOAC) function AIRBASE:GetFreeParkingSpotsNumber(termtype, allowTOAC)
@@ -2207,7 +2207,7 @@ end
--- Get the coordinates of free parking spots at an airbase. --- Get the coordinates of free parking spots at an airbase.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #AIRBASE.TerminalType termtype Terminal type. -- @param #AIRBASE.TerminalType termtype Terminal type.
-- @param #boolean allowTOAC If true, spots are considered free even though TO_AC is true. Default is off which is saver to avoid spawning aircraft on top of each other. Option might be enabled for FARPS and ships. -- @param #boolean allowTOAC (Optional) If true, spots are considered free even though TO_AC is true. Default is off which is saver to avoid spawning aircraft on top of each other. Option might be enabled for FARPS and ships.
-- @return #table Table of coordinates of the free parking spots. -- @return #table Table of coordinates of the free parking spots.
function AIRBASE:GetFreeParkingSpotsCoordinates(termtype, allowTOAC) function AIRBASE:GetFreeParkingSpotsCoordinates(termtype, allowTOAC)
@@ -2434,7 +2434,7 @@ end
--- Get a table containing the coordinates, terminal index and terminal type of free parking spots at an airbase. --- Get a table containing the coordinates, terminal index and terminal type of free parking spots at an airbase.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #AIRBASE.TerminalType termtype Terminal type. -- @param #AIRBASE.TerminalType termtype Terminal type.
-- @param #boolean allowTOAC If true, spots are considered free even though TO_AC is true. Default is off which is saver to avoid spawning aircraft on top of each other. Option might be enabled for FARPS and ships. -- @param #boolean allowTOAC (Optional) If true, spots are considered free even though TO_AC is true. Default is off which is saver to avoid spawning aircraft on top of each other. Option might be enabled for FARPS and ships.
-- @return #table Table free parking spots. Table has the elements ".Coordinate, ".TerminalID", ".TerminalType", ".TOAC", ".Free", ".TerminalID0", ".DistToRwy". -- @return #table Table free parking spots. Table has the elements ".Coordinate, ".TerminalID", ".TerminalType", ".TOAC", ".Free", ".TerminalID0", ".DistToRwy".
function AIRBASE:GetFreeParkingSpotsTable(termtype, allowTOAC) function AIRBASE:GetFreeParkingSpotsTable(termtype, allowTOAC)
@@ -2486,7 +2486,7 @@ end
--- Place markers of parking spots on the F10 map. --- Place markers of parking spots on the F10 map.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #AIRBASE.TerminalType termtype Terminal type for which marks should be placed. -- @param #AIRBASE.TerminalType termtype Terminal type for which marks should be placed.
-- @param #boolean mark If false, do not place markers but only give output to DCS.log file. Default true. -- @param #boolean mark (Optional) If false, do not place markers but only give output to DCS.log file. Default true.
function AIRBASE:MarkParkingSpots(termtype, mark) function AIRBASE:MarkParkingSpots(termtype, mark)
-- Default is true. -- Default is true.
@@ -3266,7 +3266,7 @@ end
--- Set the active runway for landing and takeoff. --- Set the active runway for landing and takeoff.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #string Name Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction. -- @param #string Name Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction.
-- @param #boolean PreferLeft If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right. -- @param #boolean PreferLeft (Optional) If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right.
function AIRBASE:SetActiveRunway(Name, PreferLeft) function AIRBASE:SetActiveRunway(Name, PreferLeft)
self:SetActiveRunwayTakeoff(Name, PreferLeft) self:SetActiveRunwayTakeoff(Name, PreferLeft)
@@ -3278,7 +3278,7 @@ end
--- Set the active runway for landing. --- Set the active runway for landing.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #string Name Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction. -- @param #string Name Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction.
-- @param #boolean PreferLeft If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right. -- @param #boolean PreferLeft (Optional) If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right.
-- @return #AIRBASE.Runway The active runway for landing. -- @return #AIRBASE.Runway The active runway for landing.
function AIRBASE:SetActiveRunwayLanding(Name, PreferLeft) function AIRBASE:SetActiveRunwayLanding(Name, PreferLeft)
@@ -3326,7 +3326,7 @@ end
--- Set the active runway for takeoff. --- Set the active runway for takeoff.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #string Name Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction. -- @param #string Name Name of the runway, e.g. "31" or "02L" or "90R". If not given, the runway is determined from the wind direction.
-- @param #boolean PreferLeft If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right. -- @param #boolean PreferLeft (Optional) If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right.
-- @return #AIRBASE.Runway The active runway for landing. -- @return #AIRBASE.Runway The active runway for landing.
function AIRBASE:SetActiveRunwayTakeoff(Name, PreferLeft) function AIRBASE:SetActiveRunwayTakeoff(Name, PreferLeft)
@@ -3351,7 +3351,7 @@ end
--- Get the runway where aircraft would be taking of or landing into the direction of the wind. --- Get the runway where aircraft would be taking of or landing into the direction of the wind.
-- NOTE that this requires the wind to be non-zero as set in the mission editor. -- NOTE that this requires the wind to be non-zero as set in the mission editor.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #boolean PreferLeft If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right. -- @param #boolean PreferLeft (Optional) If `true`, perfer the left runway. If `false`, prefer the right runway. If `nil` (default), do not care about left or right.
-- @return #AIRBASE.Runway Active runway data table. -- @return #AIRBASE.Runway Active runway data table.
function AIRBASE:GetRunwayIntoWind(PreferLeft) function AIRBASE:GetRunwayIntoWind(PreferLeft)
@@ -3407,7 +3407,7 @@ end
--- Get name of a given runway, e.g. "31L". --- Get name of a given runway, e.g. "31L".
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param #AIRBASE.Runway Runway The runway. Default is the active runway. -- @param #AIRBASE.Runway Runway (Optional) The runway. Default is the active runway.
-- @param #boolean LongLeftRight If `true`, return "Left" or "Right" instead of "L" or "R". -- @param #boolean LongLeftRight If `true`, return "Left" or "Right" instead of "L" or "R".
-- @return #string Name of the runway or "XX" if it could not be found. -- @return #string Name of the runway or "XX" if it could not be found.
function AIRBASE:GetRunwayName(Runway, LongLeftRight) function AIRBASE:GetRunwayName(Runway, LongLeftRight)
@@ -3438,7 +3438,7 @@ end
--- Function that checks if at leat one unit of a group has been spawned close to a spawn point on the runway. --- Function that checks if at leat one unit of a group has been spawned close to a spawn point on the runway.
-- @param #AIRBASE self -- @param #AIRBASE self
-- @param Wrapper.Group#GROUP group Group to be checked. -- @param Wrapper.Group#GROUP group Group to be checked.
-- @param #number radius Radius around the spawn point to be checked. Default is 50 m. -- @param #number radius (Optional) Radius around the spawn point to be checked. Default is 50 m.
-- @param #boolean despawn If true, the group is destroyed. -- @param #boolean despawn If true, the group is destroyed.
-- @return #boolean True if group is within radius around spawn points on runway. -- @return #boolean True if group is within radius around spawn points on runway.
function AIRBASE:CheckOnRunWay(group, radius, despawn) function AIRBASE:CheckOnRunWay(group, radius, despawn)
+1 -1
View File
@@ -117,7 +117,7 @@ end
-- @param #CLIENT self -- @param #CLIENT self
-- @param #string ClientName Name of the DCS **Unit** as defined within the Mission Editor. -- @param #string ClientName Name of the DCS **Unit** as defined within the Mission Editor.
-- @param #string ClientBriefing Text that describes the briefing of the mission when a Player logs into the Client. -- @param #string ClientBriefing Text that describes the briefing of the mission when a Player logs into the Client.
-- @param #boolean Error A flag that indicates whether an error should be raised if the CLIENT cannot be found. By default an error will be raised. -- @param #boolean Error (Optional) A flag that indicates whether an error should be raised if the CLIENT cannot be found. By default an error will be raised.
-- @return #CLIENT -- @return #CLIENT
-- @usage -- @usage
-- -- Create new Clients. -- -- Create new Clients.
@@ -875,7 +875,7 @@ end
--- Set callsign of the CONTROLLABLE. See [DCS command setCallsign](https://wiki.hoggitworld.com/view/DCS_command_setCallsign) --- Set callsign of the CONTROLLABLE. See [DCS command setCallsign](https://wiki.hoggitworld.com/view/DCS_command_setCallsign)
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param DCS#CALLSIGN CallName Number corresponding the the callsign identifier you wish this group to be called. -- @param DCS#CALLSIGN CallName Number corresponding the the callsign identifier you wish this group to be called.
-- @param #number CallNumber The number value the group will be referred to as. Only valid numbers are 1-9. For example Uzi **5**-1. Default 1. -- @param #number CallNumber (Optional) The number value the group will be referred to as. Only valid numbers are 1-9. For example Uzi **5**-1. Default 1.
-- @param #number Delay (Optional) Delay in seconds before the callsign is set. Default is immediately. -- @param #number Delay (Optional) Delay in seconds before the callsign is set. Default is immediately.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:CommandSetCallsign( CallName, CallNumber, Delay ) function CONTROLLABLE:CommandSetCallsign( CallName, CallNumber, Delay )
@@ -953,7 +953,7 @@ end
--- Set radio frequency. See [DCS command SetFrequency](https://wiki.hoggitworld.com/view/DCS_command_setFrequency) --- Set radio frequency. See [DCS command SetFrequency](https://wiki.hoggitworld.com/view/DCS_command_setFrequency)
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number Frequency Radio frequency in MHz. -- @param #number Frequency Radio frequency in MHz.
-- @param #number Modulation Radio modulation. Default `radio.modulation.AM`. -- @param #number Modulation (Optional) Radio modulation. Default `radio.modulation.AM`.
-- @param #number Power (Optional) Power of the Radio in Watts. Defaults to 10. -- @param #number Power (Optional) Power of the Radio in Watts. Defaults to 10.
-- @param #number Delay (Optional) Delay in seconds before the frequency is set. Default is immediately. -- @param #number Delay (Optional) Delay in seconds before the frequency is set. Default is immediately.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
@@ -980,7 +980,7 @@ end
--- [AIR] Set radio frequency. See [DCS command SetFrequencyForUnit](https://wiki.hoggitworld.com/view/DCS_command_setFrequencyForUnit) --- [AIR] Set radio frequency. See [DCS command SetFrequencyForUnit](https://wiki.hoggitworld.com/view/DCS_command_setFrequencyForUnit)
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number Frequency Radio frequency in MHz. -- @param #number Frequency Radio frequency in MHz.
-- @param #number Modulation Radio modulation. Default `radio.modulation.AM`. -- @param #number Modulation (Optional) Radio modulation. Default `radio.modulation.AM`.
-- @param #number Power (Optional) Power of the Radio in Watts. Defaults to 10. -- @param #number Power (Optional) Power of the Radio in Watts. Defaults to 10.
-- @param #number UnitID (Optional, if your object is a UNIT) The UNIT ID this is for. -- @param #number UnitID (Optional, if your object is a UNIT) The UNIT ID this is for.
-- @param #number Delay (Optional) Delay in seconds before the frequency is set. Default is immediately. -- @param #number Delay (Optional) Delay in seconds before the frequency is set. Default is immediately.
@@ -1005,7 +1005,7 @@ end
--- [AIR] Set smoke on or off. See [DCS command smoke on off](https://wiki.hoggitworld.com/view/DCS_command_smoke_on_off) --- [AIR] Set smoke on or off. See [DCS command smoke on off](https://wiki.hoggitworld.com/view/DCS_command_smoke_on_off)
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #boolean OnOff Set to true for on and false for off. Defaults to true. -- @param #boolean OnOff (Optional) Set to true for on and false for off. Defaults to true.
-- @param #number Delay (Optional) Delay the command by this many seconds. -- @param #number Delay (Optional) Delay the command by this many seconds.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:CommandSmokeOnOff(OnOff, Delay) function CONTROLLABLE:CommandSmokeOnOff(OnOff, Delay)
@@ -1065,7 +1065,7 @@ end
--- Set EPLRS data link on/off. --- Set EPLRS data link on/off.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #boolean SwitchOnOff If true (or nil) switch EPLRS on. If false switch off. -- @param #boolean SwitchOnOff If true (or nil) switch EPLRS on. If false switch off.
-- @param #number idx Task index. Default 1. -- @param #number idx (Optional) Task index. Default 1.
-- @return #table Task wrapped action. -- @return #table Task wrapped action.
function CONTROLLABLE:TaskEPLRS( SwitchOnOff, idx ) function CONTROLLABLE:TaskEPLRS( SwitchOnOff, idx )
@@ -1099,32 +1099,14 @@ end
-- @param #number AttackQty (optional) This parameter limits maximal quantity of attack. The aircraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aircraft/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 #number AttackQty (optional) This parameter limits maximal quantity of attack. The aircraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aircraft/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#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 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 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.
-- @param #boolean GroupAttack (Optional) If true, attack as group. -- @param #boolean GroupAttack (Optional) If true, attack as group.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:TaskAttackGroup( AttackGroup, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit, GroupAttack ) function CONTROLLABLE:TaskAttackGroup( AttackGroup, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit, GroupAttack )
-- self:F2( { self.ControllableName, AttackGroup, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit } ) -- self:F2( { self.ControllableName, AttackGroup, WeaponType, WeaponExpend, AttackQty, Direction, Altitude, AttackQtyLimit } )
-- AttackGroup = {
-- id = 'AttackGroup',
-- params = {
-- groupId = Group.ID,
-- weaponType = number,
-- expend = enum AI.Task.WeaponExpend,
-- attackQty = number,
-- directionEnabled = boolean,
-- direction = Azimuth,
-- altitudeEnabled = boolean,
-- altitude = Distance,
-- attackQtyLimit = boolean,
-- }
-- }
local DCSTask = { id = 'AttackGroup', local DCSTask = { id = 'AttackGroup',
params = { params = {
groupId = AttackGroup:GetID(), groupId = AttackGroup:GetID(),
weaponType = WeaponType or 1073741822, weaponType = WeaponType or ENUMS.WeaponFlag.Auto,
expend = WeaponExpend or "Auto", expend = WeaponExpend or "Auto",
attackQtyLimit = AttackQty and true or false, attackQtyLimit = AttackQty and true or false,
attackQty = AttackQty or 1, attackQty = AttackQty or 1,
@@ -1135,7 +1117,6 @@ function CONTROLLABLE:TaskAttackGroup( AttackGroup, WeaponType, WeaponExpend, At
groupAttack = GroupAttack and true or false, groupAttack = GroupAttack and true or false,
}, },
} }
return DCSTask return DCSTask
end end
@@ -1163,7 +1144,7 @@ function CONTROLLABLE:TaskAttackUnit( AttackUnit, GroupAttack, WeaponExpend, Att
altitude = Altitude, altitude = Altitude,
attackQtyLimit = AttackQty and true or false, attackQtyLimit = AttackQty and true or false,
attackQty = AttackQty, attackQty = AttackQty,
weaponType = WeaponType or 1073741822, weaponType = WeaponType or ENUMS.WeaponFlag.Auto,
}, },
} }
@@ -1197,7 +1178,7 @@ function CONTROLLABLE:TaskBombing( Vec2, GroupAttack, WeaponExpend, AttackQty, D
direction = Direction and math.rad(Direction) or 0, direction = Direction and math.rad(Direction) or 0,
altitudeEnabled = Altitude and true or false, altitudeEnabled = Altitude and true or false,
altitude = Altitude or 2000, altitude = Altitude or 2000,
weaponType = WeaponType or 1073741822, weaponType = WeaponType or ENUMS.WeaponFlag.AnyBomb,
attackType = Divebomb and "Dive" or nil, attackType = Divebomb and "Dive" or nil,
}, },
} }
@@ -1249,7 +1230,7 @@ end
-- @param #number AttackQty (Optional) This parameter limits maximal quantity of attack. The aircraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aircraft/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 #number AttackQty (Optional) This parameter limits maximal quantity of attack. The aircraft/controllable will not make more attack than allowed even if the target controllable not destroyed and the aircraft/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#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 [meters] from where to attack. Default 30 m. -- @param #number Altitude (Optional) The altitude [meters] from where to attack. Default 30 m.
-- @param #number WeaponType (Optional) The WeaponType. Default Auto=1073741822. -- @param #number WeaponType (Optional) The WeaponType. Default `ENUMS.WeaponFlag.Auto`.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:TaskAttackMapObject( Vec2, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, WeaponType ) function CONTROLLABLE:TaskAttackMapObject( Vec2, GroupAttack, WeaponExpend, AttackQty, Direction, Altitude, WeaponType )
@@ -1266,7 +1247,7 @@ function CONTROLLABLE:TaskAttackMapObject( Vec2, GroupAttack, WeaponExpend, Atta
direction = Direction and math.rad(Direction) or 0, direction = Direction and math.rad(Direction) or 0,
altitudeEnabled = Altitude and true or false, altitudeEnabled = Altitude and true or false,
altitude = Altitude, altitude = Altitude,
weaponType = WeaponType or 1073741822, weaponType = WeaponType or ENUMS.WeaponFlag.Auto,
}, },
} }
@@ -1385,7 +1366,7 @@ end
-- The controllable has to be an infantry group! -- The controllable has to be an infantry group!
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param Core.Point#COORDINATE Coordinate Coordinates where AI is expecting to be picked up. -- @param Core.Point#COORDINATE Coordinate Coordinates where AI is expecting to be picked up.
-- @param #number Radius Radius in meters. Default 200 m. -- @param #number Radius (Optional) Radius in meters. Default 200 m.
-- @param #string UnitType The unit type name of the carrier, e.g. "UH-1H". Must not be specified. -- @param #string UnitType The unit type name of the carrier, e.g. "UH-1H". Must not be specified.
-- @return DCS#Task Embark to transport task. -- @return DCS#Task Embark to transport task.
function CONTROLLABLE:TaskEmbarkToTransport( Coordinate, Radius, UnitType ) function CONTROLLABLE:TaskEmbarkToTransport( Coordinate, Radius, UnitType )
@@ -1459,8 +1440,8 @@ end
--- (AIR) Orbit at a position with at a given altitude and speed. Optionally, a race track pattern can be specified. --- (AIR) Orbit at a position with at a given altitude and speed. Optionally, a race track pattern can be specified.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param Core.Point#COORDINATE Coord Coordinate at which the CONTROLLABLE orbits. Can also be given as a `DCS#Vec3` or `DCS#Vec2` object. -- @param Core.Point#COORDINATE Coord Coordinate at which the CONTROLLABLE orbits. Can also be given as a `DCS#Vec3` or `DCS#Vec2` object.
-- @param #number Altitude Altitude in meters of the orbit pattern. Default y component of Coord. -- @param #number Altitude (Optional) Altitude in meters of the orbit pattern. Default y component of Coord.
-- @param #number Speed Speed [m/s] flying the orbit pattern. Default 128 m/s = 250 knots. -- @param #number Speed (Optional) Speed [m/s] flying the orbit pattern. Default 128 m/s = 250 knots.
-- @param Core.Point#COORDINATE CoordRaceTrack (Optional) If this coordinate is specified, the CONTROLLABLE will fly a race-track pattern using this and the initial coordinate. -- @param Core.Point#COORDINATE CoordRaceTrack (Optional) If this coordinate is specified, the CONTROLLABLE will fly a race-track pattern using this and the initial coordinate.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:TaskOrbit( Coord, Altitude, Speed, CoordRaceTrack ) function CONTROLLABLE:TaskOrbit( Coord, Altitude, Speed, CoordRaceTrack )
@@ -1530,11 +1511,11 @@ end
-- --
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param Wrapper.Airbase#AIRBASE Airbase Airbase to attack. -- @param Wrapper.Airbase#AIRBASE Airbase Airbase to attack.
-- @param #number WeaponType (optional) Bitmask of weapon types those allowed to use. See [DCS enum weapon flag](https://wiki.hoggitworld.com/view/DCS_enum_weapon_flag). Default 2147485694 = AnyBomb (GuidedBomb + AnyUnguidedBomb). -- @param #number WeaponType (Optional) Bitmask of weapon types those allowed to use. See [DCS enum weapon flag](https://wiki.hoggitworld.com/view/DCS_enum_weapon_flag). Default 2147485694 = AnyBomb (GuidedBomb + AnyUnguidedBomb).
-- @param DCS#AI.Task.WeaponExpend WeaponExpend Enum AI.Task.WeaponExpend that defines how much munitions the AI will expend per attack run. Default "ALL". -- @param DCS#AI.Task.WeaponExpend (Optional) WeaponExpend Enum AI.Task.WeaponExpend that defines how much munitions the AI will expend per attack run. Default "ALL".
-- @param #number AttackQty Number of times the group will attack if the target. Default 1. -- @param #number AttackQty (Optional) Number of times the group will attack if the target. Default 1.
-- @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#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 GroupAttack (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 group and not to a single aircraft. -- @param #boolean GroupAttack (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 group and not to a single aircraft.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:TaskBombingRunway( Airbase, WeaponType, WeaponExpend, AttackQty, Direction, GroupAttack ) function CONTROLLABLE:TaskBombingRunway( Airbase, WeaponType, WeaponExpend, AttackQty, Direction, GroupAttack )
@@ -1725,7 +1706,7 @@ end
-- @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 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 Escort task is finished. -- @param #number LastWaypointIndex Detach waypoint of another controllable. Once reached the unit / controllable Escort task is finished.
-- @param #number EngagementDistance Maximal distance from escorted controllable to threat in meters. If the threat is already engaged by escort escort will disengage if the distance becomes greater than 1.5 * engagementDistMax. -- @param #number EngagementDistance Maximal distance from escorted controllable to threat in meters. If the threat is already engaged by escort escort will disengage if the distance becomes greater than 1.5 * engagementDistMax.
-- @param DCS#AttributeNameArray TargetTypes Array of AttributeName that is contains threat categories allowed to engage. Default {"Air"}. See https://wiki.hoggit.us/view/DCS_enum_attributes -- @param DCS#AttributeNameArray TargetTypes (Optional) Array of AttributeName that is contains threat categories allowed to engage. Default {"Air"}. See https://wiki.hoggit.us/view/DCS_enum_attributes
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:TaskEscort( FollowControllable, Vec3, LastWaypointIndex, EngagementDistance, TargetTypes ) function CONTROLLABLE:TaskEscort( FollowControllable, Vec3, LastWaypointIndex, EngagementDistance, TargetTypes )
@@ -1765,7 +1746,7 @@ end
-- @param #number AmmoCount (optional) Quantity of ammunition to expand (omit to fire until ammunition is depleted). -- @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 -- @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
-- @param #number Altitude (Optional) Altitude in meters. -- @param #number Altitude (Optional) Altitude in meters.
-- @param #number ASL Altitude is above mean sea level. Default is above ground level. -- @param #number ASL (Optional) Altitude is above mean sea level. Default is above ground level.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:TaskFireAtPoint( Vec2, Radius, AmmoCount, WeaponType, Altitude, ASL ) function CONTROLLABLE:TaskFireAtPoint( Vec2, Radius, AmmoCount, WeaponType, Altitude, ASL )
@@ -1818,11 +1799,11 @@ end
-- It's important to note that depending on the type of unit that is being assigned the task (AIR or GROUND), you must choose the correct type of callsign enumerator. For airborne controllables use CALLSIGN.Aircraft and for ground based use CALLSIGN.JTAC enumerators. -- It's important to note that depending on the type of unit that is being assigned the task (AIR or GROUND), you must choose the correct type of callsign enumerator. For airborne controllables use CALLSIGN.Aircraft and for ground based use CALLSIGN.JTAC enumerators.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param Wrapper.Group#GROUP AttackGroup Target GROUP object. -- @param Wrapper.Group#GROUP AttackGroup Target GROUP object.
-- @param #number WeaponType Bitmask of weapon types, which are allowed to use. -- @param #number WeaponType (Optional) Bitmask of weapon types, which are allowed to use. Defaults tp ENUMS.WeaponFlag.AutoDCS.
-- @param DCS#AI.Task.Designation Designation (Optional) Designation type. -- @param DCS#AI.Task.Designation Designation (Optional) Designation type. Defaults to Auto.
-- @param #boolean Datalink (Optional) Allows to use datalink to send the target information to attack aircraft. Enabled by default. -- @param #boolean Datalink (Optional) Allows to use datalink to send the target information to attack aircraft. Enabled by default.
-- @param #number Frequency Frequency in MHz used to communicate with the FAC. Default 133 MHz. -- @param #number Frequency (Optional) Frequency in MHz used to communicate with the FAC. Default 133 MHz.
-- @param #number Modulation Modulation of radio for communication. Default 0=AM. -- @param #number Modulation (Optional) Modulation of radio for communication. Default 0=AM.
-- @param #number CallsignName Callsign enumerator name of the FAC. (CALLSIGN.Aircraft.{name} for airborne controllables, CALLSIGN.JTACS.{name} for ground units) -- @param #number CallsignName Callsign enumerator name of the FAC. (CALLSIGN.Aircraft.{name} for airborne controllables, CALLSIGN.JTACS.{name} for ground units)
-- @param #number CallsignNumber Callsign number, e.g. Axeman-**1**. -- @param #number CallsignNumber Callsign number, e.g. Axeman-**1**.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
@@ -1848,8 +1829,8 @@ end
--- (AIR) Engaging targets of defined types. --- (AIR) Engaging targets of defined types.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @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#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 DCS#AttributeNameArray TargetTypes (Optional) Array of target categories allowed to engage. Defaults to {"Air"}.
-- @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. Default 0. -- @param #number Priority (Optional) 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. Default 0.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:EnRouteTaskEngageTargets( Distance, TargetTypes, Priority ) function CONTROLLABLE:EnRouteTaskEngageTargets( Distance, TargetTypes, Priority )
@@ -1890,7 +1871,7 @@ end
--- (AIR) Enroute anti-ship task. --- (AIR) Enroute anti-ship task.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param DCS#AttributeNameArray TargetTypes Array of target categories allowed to engage. Default `{"Ships"}`. -- @param DCS#AttributeNameArray TargetTypes (Optional) Array of target categories allowed to engage. Default `{"Ships"}`.
-- @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. Default 0. -- @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. Default 0.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:EnRouteTaskAntiShip(TargetTypes, Priority) function CONTROLLABLE:EnRouteTaskAntiShip(TargetTypes, Priority)
@@ -1911,7 +1892,7 @@ end
--- (AIR) Enroute SEAD task. --- (AIR) Enroute SEAD task.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param DCS#AttributeNameArray TargetTypes Array of target categories allowed to engage. Default `{"Air Defence"}`. -- @param DCS#AttributeNameArray TargetTypes (Optional) Array of target categories allowed to engage. Default `{"Air Defence"}`.
-- @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. Default 0. -- @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. Default 0.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:EnRouteTaskSEAD(TargetTypes, Priority) function CONTROLLABLE:EnRouteTaskSEAD(TargetTypes, Priority)
@@ -1932,7 +1913,7 @@ end
--- (AIR) Enroute CAP task. --- (AIR) Enroute CAP task.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param DCS#AttributeNameArray TargetTypes Array of target categories allowed to engage. Default `{"Air"}`. -- @param DCS#AttributeNameArray TargetTypes (Optional) Array of target categories allowed to engage. Default `{"Air"}`.
-- @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. Default 0. -- @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. Default 0.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:EnRouteTaskCAP(TargetTypes, Priority) function CONTROLLABLE:EnRouteTaskCAP(TargetTypes, Priority)
@@ -2105,11 +2086,11 @@ end
-- Target designation is set to auto and is dependent on the circumstances. -- Target designation is set to auto and is dependent on the circumstances.
-- See [hoggit](https://wiki.hoggitworld.com/view/DCS_task_fac). -- See [hoggit](https://wiki.hoggitworld.com/view/DCS_task_fac).
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number Frequency Frequency in MHz. Default 133 MHz. -- @param #number Frequency (Optional) Frequency in MHz. Default 133 MHz.
-- @param #number Modulation Radio modulation. Default `radio.modulation.AM`. -- @param #number Modulation (Optional) Radio modulation. Default `radio.modulation.AM`.
-- @param #number CallsignID CallsignID, e.g. `CALLSIGN.JTAC.Anvil` for ground or `CALLSIGN.Aircraft.Ford` for air. -- @param #number CallsignID CallsignID, e.g. `CALLSIGN.JTAC.Anvil` for ground or `CALLSIGN.Aircraft.Ford` for air.
-- @param #number CallsignNumber Callsign first number, e.g. 2 for `Ford-2`. -- @param #number CallsignNumber Callsign first number, e.g. 2 for `Ford-2`.
-- @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 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. Defaults to 0.
-- @return DCS#Task The DCS task structure. -- @return DCS#Task The DCS task structure.
function CONTROLLABLE:EnRouteTaskFAC( Frequency, Modulation, CallsignID, CallsignNumber, Priority ) function CONTROLLABLE:EnRouteTaskFAC( Frequency, Modulation, CallsignID, CallsignNumber, Priority )
@@ -2339,8 +2320,8 @@ do -- Patrol methods
-- @param #table ZoneList Table of zones. -- @param #table ZoneList Table of zones.
-- @param #number Speed Speed in km/h the group moves at. -- @param #number Speed Speed in km/h the group moves at.
-- @param #string Formation (Optional) Formation the group should use. -- @param #string Formation (Optional) Formation the group should use.
-- @param #number DelayMin Delay in seconds before the group progresses to the next route point. Default 1 sec. -- @param #number DelayMin (Optional) Delay in seconds before the group progresses to the next route point. Default 1 sec.
-- @param #number DelayMax Max. delay in seconds. Actual delay is randomly chosen between DelayMin and DelayMax. Default equal to DelayMin. -- @param #number DelayMax (Optional) Max. delay in seconds. Actual delay is randomly chosen between DelayMin and DelayMax. Default equal to DelayMin.
-- @return #CONTROLLABLE -- @return #CONTROLLABLE
function CONTROLLABLE:PatrolZones( ZoneList, Speed, Formation, DelayMin, DelayMax ) function CONTROLLABLE:PatrolZones( ZoneList, Speed, Formation, DelayMin, DelayMax )
@@ -2855,7 +2836,7 @@ do -- Route methods
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param Core.Zone#ZONE Zone The zone where to route to. -- @param Core.Zone#ZONE Zone The zone where to route to.
-- @param #boolean Randomize Defines whether to target point gets randomized within the Zone. -- @param #boolean Randomize Defines whether to target point gets randomized within the Zone.
-- @param #number Speed The speed in m/s. Default is 5.555 m/s = 20 km/h. -- @param #number Speed (Optional) The speed in m/s. Default is 5.555 m/s = 20 km/h.
-- @param DCS#FORMATION Formation The formation string. -- @param DCS#FORMATION Formation The formation string.
function CONTROLLABLE:TaskRouteToZone( Zone, Randomize, Speed, Formation ) function CONTROLLABLE:TaskRouteToZone( Zone, Randomize, Speed, Formation )
self:F2( Zone ) self:F2( Zone )
@@ -2915,7 +2896,7 @@ do -- Route methods
-- A given formation can be given. -- A given formation can be given.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param DCS#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 #number Speed (Optional) The speed in m/s. Default is 5.555 m/s = 20 km/h.
-- @param DCS#FORMATION Formation The formation string. -- @param DCS#FORMATION Formation The formation string.
function CONTROLLABLE:TaskRouteToVec2( Vec2, Speed, Formation ) function CONTROLLABLE:TaskRouteToVec2( Vec2, Speed, Formation )
@@ -3847,7 +3828,7 @@ end
--- Set RTB on bingo fuel. --- Set RTB on bingo fuel.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #boolean RTB true if RTB on bingo fuel (default), false if no RTB on bingo fuel. -- @param #boolean RTB (Optional) true if RTB on bingo fuel (default), false if no RTB on bingo fuel.
-- Warning! When you switch this option off, the airborne group will continue to fly until all fuel has been consumed, and will crash. -- Warning! When you switch this option off, the airborne group will continue to fly until all fuel has been consumed, and will crash.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:OptionRTBBingoFuel( RTB ) -- R2.2 function CONTROLLABLE:OptionRTBBingoFuel( RTB ) -- R2.2
@@ -3974,7 +3955,7 @@ end
--- [Ground] Option that defines the vehicle spacing when in an on road and off road formation. --- [Ground] Option that defines the vehicle spacing when in an on road and off road formation.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number meters Can be zero to 100 meters. Defaults to 50 meters. -- @param #number meters (Optional) Can be zero to 100 meters. Defaults to 50 meters.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:OptionFormationInterval(meters) function CONTROLLABLE:OptionFormationInterval(meters)
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -3995,7 +3976,7 @@ end
--- [Air] Defines the usage of Electronic Counter Measures by airborne forces. --- [Air] Defines the usage of Electronic Counter Measures by airborne forces.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number ECMvalue Can be - 0=Never on, 1=if locked by radar, 2=if detected by radar, 3=always on, defaults to 1 -- @param #number ECMvalue (Optional) Can be - 0=Never on, 1=if locked by radar, 2=if detected by radar, 3=always on, defaults to 1
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:OptionECM( ECMvalue ) function CONTROLLABLE:OptionECM( ECMvalue )
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -4291,7 +4272,7 @@ end
--- Defines the range at which a GROUND unit/group is allowed to use its weapons automatically. --- Defines the range at which a GROUND unit/group is allowed to use its weapons automatically.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number EngageRange Engage range limit in percent (a number between 0 and 100). Default 100. -- @param #number EngageRange (Optional) Engage range limit in percent (a number between 0 and 100). Default 100.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:OptionEngageRange( EngageRange ) function CONTROLLABLE:OptionEngageRange( EngageRange )
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -4441,7 +4422,7 @@ end
--- [AIR] Set the AI to report contact for certain types of objects. --- [AIR] Set the AI to report contact for certain types of objects.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #table Objects Table of attribute names for which AI reports contact. Defaults to {"Air"}. See [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes) -- @param #table Objects (Optional) Table of attribute names for which AI reports contact. Defaults to {"Air"}. See [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes)
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:SetOptionRadioContact(Objects) function CONTROLLABLE:SetOptionRadioContact(Objects)
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -4455,7 +4436,7 @@ end
--- [AIR] Set the AI to report engaging certain types of objects. --- [AIR] Set the AI to report engaging certain types of objects.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #table Objects Table of attribute names for which AI reports contact. Defaults to {"Air"}, see [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes) -- @param #table Objects (Optional) Table of attribute names for which AI reports contact. Defaults to {"Air"}, see [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes)
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:SetOptionRadioEngage(Objects) function CONTROLLABLE:SetOptionRadioEngage(Objects)
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -4469,7 +4450,7 @@ end
--- [AIR] Set the AI to report killing certain types of objects. --- [AIR] Set the AI to report killing certain types of objects.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #table Objects Table of attribute names for which AI reports contact. Defaults to {"Air"}, see [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes) -- @param #table Objects (Optional) Table of attribute names for which AI reports contact. Defaults to {"Air"}, see [Hoggit Wiki](https://wiki.hoggitworld.com/view/DCS_enum_attributes)
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:SetOptionRadioKill(Objects) function CONTROLLABLE:SetOptionRadioKill(Objects)
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -4483,12 +4464,12 @@ end
--- (GROUND) Relocate controllable to a random point within a given radius; use e.g.for evasive actions; Note that not all ground controllables can actually drive, also the alarm state of the controllable might stop it from moving. --- (GROUND) Relocate controllable to a random point within a given radius; use e.g.for evasive actions; Note that not all ground controllables can actually drive, also the alarm state of the controllable might stop it from moving.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #number speed Speed of the controllable, default 20 -- @param #number speed (Optional) Speed of the controllable, default 20
-- @param #number radius Radius of the relocation zone, default 500 -- @param #number radius (Optional) Radius of the relocation zone, default 500
-- @param #boolean onroad If true, route on road (less problems with AI way finding), default true -- @param #boolean onroad (Optional) If true, route on road (less problems with AI way finding), default true
-- @param #boolean shortcut If true and onroad is set, take a shorter route - if available - off road, default false -- @param #boolean shortcut (Optional) If true and onroad is set, take a shorter route - if available - off road, default false
-- @param #string formation Formation string as in the mission editor, e.g. "Vee", "Diamond", "Line abreast", etc. Defaults to "Off Road" -- @param #string formation (Optional) Formation string as in the mission editor, e.g. "Vee", "Diamond", "Line abreast", etc. Defaults to "Off Road"
-- @param #boolean onland (optional) If true, try up to 50 times to get a coordinate on land.SurfaceType.LAND. Note - this descriptor value is not reliably implemented on all maps. -- @param #boolean onland (Optional) If true, try up to 50 times to get a coordinate on land.SurfaceType.LAND. Note - this descriptor value is not reliably implemented on all maps.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:RelocateGroundRandomInRadius( speed, radius, onroad, shortcut, formation, onland ) function CONTROLLABLE:RelocateGroundRandomInRadius( speed, radius, onroad, shortcut, formation, onland )
self:F2( { self.ControllableName } ) self:F2( { self.ControllableName } )
@@ -5871,8 +5852,8 @@ end
--- [GROUND] Create and enable a new IR Marker for the given controllable UNIT or GROUP. --- [GROUND] Create and enable a new IR Marker for the given controllable UNIT or GROUP.
-- @param #CONTROLLABLE self -- @param #CONTROLLABLE self
-- @param #boolean EnableImmediately (Optionally) If true start up the IR Marker immediately. Else you need to call `myobject:EnableIRMarker()` later on. -- @param #boolean EnableImmediately (Optional) If true start up the IR Marker immediately. Else you need to call `myobject:EnableIRMarker()` later on.
-- @param #number Runtime (Optionally) Run this IR Marker for the given number of seconds, then stop. Use in conjunction with EnableImmediately. Defaults to 60 seconds. -- @param #number Runtime (Optional) Run this IR Marker for the given number of seconds, then stop. Use in conjunction with EnableImmediately. Defaults to 60 seconds.
-- @return #CONTROLLABLE self -- @return #CONTROLLABLE self
function CONTROLLABLE:NewIRMarker(EnableImmediately, Runtime) function CONTROLLABLE:NewIRMarker(EnableImmediately, Runtime)
self:T2("NewIRMarker") self:T2("NewIRMarker")
+492 -12
View File
@@ -28,9 +28,9 @@
-- @field #string version. -- @field #string version.
-- @field #string CargoState. -- @field #string CargoState.
-- @field #table DCS#Vec3 LastPosition. -- @field #table DCS#Vec3 LastPosition.
-- @field #number Interval Check Interval. 20 secs default. -- @field #number Interval Check interval. 5 secs default.
-- @field #boolean testing -- @field #boolean testing
-- @field Core.Timer#TIMER timer Timmer to run intervals -- @field Core.Timer#TIMER timer Compatibility field; updates are handled by one class-wide scheduler.
-- @field #string Owner The playername who has created, loaded or unloaded this cargo. Depends on state. -- @field #string Owner The playername who has created, loaded or unloaded this cargo. Depends on state.
-- @extends Wrapper.Positionable#POSITIONABLE -- @extends Wrapper.Positionable#POSITIONABLE
@@ -50,7 +50,16 @@ DYNAMICCARGO = {
ClassName = "DYNAMICCARGO", ClassName = "DYNAMICCARGO",
verbose = 0, verbose = 0,
testing = false, testing = false,
Interval = 10, Interval = 5,
C130AttachDistance = 10,
C130DetachDistance = 14,
C130AirborneAGL = 8,
C130LandedAGL = 0.5,
C130StabilityEpsilon = 0.05,
C130RequireAirborne = true,
C130OwnerResolveMove2D = 10,
C130OwnerResolveNear2D = 4,
C130OwnerResolveMax3D = 250,
} }
@@ -110,6 +119,10 @@ DYNAMICCARGO.AircraftTypes = {
["CH-47Fbl1"] = "CH-47Fbl1", ["CH-47Fbl1"] = "CH-47Fbl1",
["Mi-8MTV2"] = "Mi-8MTV2", ["Mi-8MTV2"] = "Mi-8MTV2",
["Mi-8MT"] = "Mi-8MT", ["Mi-8MT"] = "Mi-8MT",
["UH-1H"] = "UH-1H",
["Mi-24P"] = "Mi-24P",
["UH-60L"] = "UH-60L",
["UH-60L_DAP"] = "UH-60L_DAP",
["C-130J-30"] = "C-130J-30", ["C-130J-30"] = "C-130J-30",
} }
@@ -135,17 +148,46 @@ DYNAMICCARGO.AircraftDimensions = {
["length"] = 15, ["length"] = 15,
["ropelength"] = 30, ["ropelength"] = 30,
}, },
["UH-1H"] = {
["width"] = 4,
["height"] = 4,
["length"] = 9,
["ropelength"] = 25,
},
["Mi-24P"] = {
["width"] = 4,
["height"] = 5,
["length"] = 11,
["ropelength"] = 25,
},
["UH-60L"] = {
["width"] = 4,
["height"] = 5,
["length"] = 10,
["ropelength"] = 25,
},
["UH-60L_DAP"] = {
["width"] = 4,
["height"] = 5,
["length"] = 10,
["ropelength"] = 25,
},
["C-130J-30"] = { ["C-130J-30"] = {
["width"] = 4, ["width"] = 4,
["height"] = 12, ["height"] = 12,
["length"] = 35, ["length"] = 35,
["ropelength"] = 0, ["ropelength"] = 0,
["attach"] = 10,
["detach"] = 14,
}, },
} }
--- DYNAMICCARGO class version. --- DYNAMICCARGO class version.
-- @field #string version -- @field #string version
DYNAMICCARGO.version="0.1.0" DYNAMICCARGO.version="0.1.0"
DYNAMICCARGO._TrackedCargo = DYNAMICCARGO._TrackedCargo or {}
DYNAMICCARGO._GlobalTimer = DYNAMICCARGO._GlobalTimer or nil
DYNAMICCARGO._GlobalTimerInterval = DYNAMICCARGO._GlobalTimerInterval or nil
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
-- TODO list -- TODO list
@@ -170,8 +212,17 @@ function DYNAMICCARGO:Register(CargoName)
self.StaticName = CargoName self.StaticName = CargoName
self.LastPosition = self:GetCoordinate() self.LastPosition = self:GetCoordinate()
self._spawnVec3 = self.LastPosition and self.LastPosition:GetVec3() or nil
self.CargoState = DYNAMICCARGO.State.NEW self.CargoState = DYNAMICCARGO.State.NEW
self._attached = false
self._detached = false
self._wasAirborne = false
self._landAglConfirm = nil
self._ownerResolved = false
self._carrierUnitName = nil
self._carrierGroupName = nil
self._carrierTypeName = nil
self.Interval = DYNAMICCARGO.Interval or 10 self.Interval = DYNAMICCARGO.Interval or 10
@@ -186,8 +237,9 @@ function DYNAMICCARGO:Register(CargoName)
self.Owner = string.match(CargoName,"^(.+)|%d%d:%d%d|PKG%d+") or "None" self.Owner = string.match(CargoName,"^(.+)|%d%d:%d%d|PKG%d+") or "None"
self.timer = TIMER:New(DYNAMICCARGO._UpdatePosition,self) -- Keep a compatibility field, while updates are driven by one class-wide scheduler.
self.timer:Start(self.Interval,self.Interval) self.timer = nil
DYNAMICCARGO._TrackCargo(self)
if not _DYNAMICCARGO_HELOS then if not _DYNAMICCARGO_HELOS then
_DYNAMICCARGO_HELOS = SET_CLIENT:New():FilterAlive():FilterFunction(DYNAMICCARGO._FilterHeloTypes):FilterStart() _DYNAMICCARGO_HELOS = SET_CLIENT:New():FilterAlive():FilterFunction(DYNAMICCARGO._FilterHeloTypes):FilterStart()
@@ -267,6 +319,55 @@ function DYNAMICCARGO:IsRemoved()
end end
end end
--- Returns true if this cargo is attached to a detected carrier.
-- @param #DYNAMICCARGO self
-- @return #boolean Outcome
function DYNAMICCARGO:IsAttached()
return self._attached == true
end
--- Returns true if this cargo was detached from a detected carrier.
-- @param #DYNAMICCARGO self
-- @return #boolean Outcome
function DYNAMICCARGO:IsDetached()
return self._detached == true
end
--- Returns true if this cargo has seen airborne transport in this cycle.
-- @param #DYNAMICCARGO self
-- @return #boolean Outcome
function DYNAMICCARGO:WasAirborneTransport()
return self._wasAirborne == true
end
--- Returns true if this cargo has reached landed stable confirmation.
-- @param #DYNAMICCARGO self
-- @return #boolean Outcome
function DYNAMICCARGO:IsLandedStable()
return self.CargoState == DYNAMICCARGO.State.UNLOADED and self._detached == true
end
--- Returns last known carrier unit name.
-- @param #DYNAMICCARGO self
-- @return #string Unit name
function DYNAMICCARGO:GetCarrierUnitName()
return self._carrierUnitName
end
--- Returns last known carrier type name.
-- @param #DYNAMICCARGO self
-- @return #string Type name
function DYNAMICCARGO:GetCarrierTypeName()
return self._carrierTypeName
end
--- Returns last known carrier group name.
-- @param #DYNAMICCARGO self
-- @return #string Group name
function DYNAMICCARGO:GetCarrierGroupName()
return self._carrierGroupName
end
--- [CTLD] Get number of crates this DYNAMICCARGO consists of. Always one. --- [CTLD] Get number of crates this DYNAMICCARGO consists of. Always one.
-- @param #DYNAMICCARGO self -- @param #DYNAMICCARGO self
-- @return #number crate number, always one -- @return #number crate number, always one
@@ -398,6 +499,372 @@ end
-- Private Functions -- Private Functions
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--- [Internal] Check whether an aircraft typename is a C-130J for special handling.
-- @param #DYNAMICCARGO self
-- @param #string TypeName
-- @return #boolean Outcome
function DYNAMICCARGO:_IsC130Type(TypeName)
return TypeName == "C-130J-30"
end
--- [Internal] Safe AGL calculation helper.
-- @param #DYNAMICCARGO self
-- @param Core.Point#COORDINATE Coord
-- @return #number AGL in meters
function DYNAMICCARGO:_GetAGL(Coord)
if not Coord then return -1 end
return (Coord.y or 0) - Coord:GetLandHeight()
end
--- [Internal] Resolve player name for a client.
-- @param #DYNAMICCARGO self
-- @param Wrapper.Client#CLIENT Client
-- @return #string Player name
function DYNAMICCARGO:_GetPlayerNameForClient(Client)
if not Client then return self.Owner or "None" end
return Client:GetPlayerName() or _DATABASE:_FindPlayerNameByUnitName(Client:GetName()) or self.Owner or "None"
end
--- [Internal] Store current carrier identity fields.
-- @param #DYNAMICCARGO self
-- @param Wrapper.Client#CLIENT Client
-- @param #string PlayerName
-- @return #DYNAMICCARGO self
function DYNAMICCARGO:_SetCarrierFromClient(Client, PlayerName)
if not Client then return self end
self._carrierUnitName = Client:GetName() or self._carrierUnitName
self._carrierTypeName = Client:GetTypeName() or self._carrierTypeName
local grp = Client:GetGroup()
if grp then
self._carrierGroupName = grp:GetName() or self._carrierGroupName
end
self.Owner = PlayerName or self:_GetPlayerNameForClient(Client)
return self
end
--- [Internal] Get scheduler interval for global dynamic cargo updates.
-- @return #number Interval in seconds
function DYNAMICCARGO._GetSchedulerInterval()
return DYNAMICCARGO.Interval or 5
end
--- [Internal] Count currently tracked dynamic cargo objects.
-- @return #number Count
function DYNAMICCARGO._CountTracked()
local n = 0
for _,_ in pairs(DYNAMICCARGO._TrackedCargo or {}) do
n = n + 1
end
return n
end
--- [Internal] Stop global scheduler when no tracked cargo remains.
function DYNAMICCARGO._StopGlobalSchedulerIfIdle()
if DYNAMICCARGO._CountTracked() > 0 then
return
end
if DYNAMICCARGO._GlobalTimer and DYNAMICCARGO._GlobalTimer:IsRunning() then
DYNAMICCARGO._GlobalTimer:Stop()
end
DYNAMICCARGO._GlobalTimer = nil
DYNAMICCARGO._GlobalTimerInterval = nil
end
--- [Internal] Ensure global scheduler is running for tracked cargo updates.
function DYNAMICCARGO._EnsureGlobalScheduler()
local interval = DYNAMICCARGO._GetSchedulerInterval()
if DYNAMICCARGO._GlobalTimer and DYNAMICCARGO._GlobalTimer:IsRunning() then
if DYNAMICCARGO._GlobalTimerInterval == interval then
return
end
DYNAMICCARGO._GlobalTimer:Stop()
DYNAMICCARGO._GlobalTimer = nil
DYNAMICCARGO._GlobalTimerInterval = nil
end
if DYNAMICCARGO._CountTracked() < 1 then
return
end
DYNAMICCARGO._GlobalTimer = TIMER:New(DYNAMICCARGO._UpdateAllTracked)
DYNAMICCARGO._GlobalTimer:Start(interval, interval)
DYNAMICCARGO._GlobalTimerInterval = interval
end
--- [Internal] Add one dynamic cargo object to global tracking.
-- @param #DYNAMICCARGO Cargo
function DYNAMICCARGO._TrackCargo(Cargo)
if not Cargo or not Cargo.StaticName then
return
end
DYNAMICCARGO._TrackedCargo = DYNAMICCARGO._TrackedCargo or {}
DYNAMICCARGO._TrackedCargo[Cargo.StaticName] = Cargo
DYNAMICCARGO._EnsureGlobalScheduler()
end
--- [Internal] Remove one dynamic cargo object from global tracking.
-- @param #string CargoName
function DYNAMICCARGO._UntrackCargo(CargoName)
if not CargoName or not DYNAMICCARGO._TrackedCargo then
DYNAMICCARGO._StopGlobalSchedulerIfIdle()
return
end
DYNAMICCARGO._TrackedCargo[CargoName] = nil
DYNAMICCARGO._StopGlobalSchedulerIfIdle()
end
--- [Internal] Update all tracked dynamic cargo objects in one scheduler tick.
function DYNAMICCARGO._UpdateAllTracked()
local tracked = DYNAMICCARGO._TrackedCargo or {}
local names = {}
for name,_ in pairs(tracked) do
names[#names + 1] = name
end
for _,name in ipairs(names) do
local cargo = tracked[name]
if cargo then
cargo:_UpdatePosition()
end
end
DYNAMICCARGO._StopGlobalSchedulerIfIdle()
end
--- [Internal] Find tracked client by unit name in current dynamic cargo helo set.
-- @param #DYNAMICCARGO self
-- @param #string UnitName
-- @return Wrapper.Client#CLIENT Client
function DYNAMICCARGO:_FindClientByUnitName(UnitName)
if not UnitName or UnitName == "" or not _DYNAMICCARGO_HELOS then return nil end
for _,_helo in pairs(_DYNAMICCARGO_HELOS:GetAliveSet() or {}) do
local helo = _helo -- Wrapper.Client#CLIENT
if helo and helo:IsAlive() and helo:GetName() == UnitName then
return helo
end
end
return nil
end
--- [Internal] Get best known carrier client from stored names/owner.
-- @param #DYNAMICCARGO self
-- @return Wrapper.Client#CLIENT Client
function DYNAMICCARGO:_GetKnownCarrierClient()
local client = nil
if self._carrierUnitName then
client = self:_FindClientByUnitName(self._carrierUnitName)
end
if (not client) and self.Owner and self.Owner ~= "None" then
local byPlayer = CLIENT:FindByPlayerName(self.Owner)
if byPlayer and byPlayer:IsAlive() then
client = byPlayer
end
end
return client
end
--- [Internal] Find nearest live C-130 client.
-- @param #DYNAMICCARGO self
-- @param Core.Point#COORDINATE Pos
-- @param #number Max3D Maximum 3D distance
-- @return Wrapper.Client#CLIENT Client
-- @return #string PlayerName
-- @return #number Dist2D
-- @return #number Dist3D
function DYNAMICCARGO:_FindNearestC130(Pos, Max3D)
if not Pos or not _DYNAMICCARGO_HELOS then return nil, nil, nil, nil end
local bestClient = nil
local bestName = nil
local best2D = math.huge
local best3D = math.huge
local bestOwnerMatch = false
local max3D = Max3D or DYNAMICCARGO.C130OwnerResolveMax3D
local preferredOwner = self.Owner
if preferredOwner == "" or preferredOwner == "None" then
preferredOwner = nil
end
for _,_helo in pairs(_DYNAMICCARGO_HELOS:GetAliveSet() or {}) do
local helo = _helo -- Wrapper.Client#CLIENT
if helo and helo:IsAlive() then
local typename = helo:GetTypeName()
if self:_IsC130Type(typename) then
local hpos = helo:GetCoordinate()
if hpos then
local d3 = hpos:Get3DDistance(Pos)
if d3 <= max3D then
local d2 = hpos:Get2DDistance(Pos)
local pname = self:_GetPlayerNameForClient(helo)
local ownerMatch = preferredOwner and pname and pname == preferredOwner or false
if (ownerMatch and not bestOwnerMatch) or ((ownerMatch == bestOwnerMatch) and d3 < best3D) then
bestClient = helo
bestName = pname
best2D = d2
best3D = d3
bestOwnerMatch = ownerMatch
end
end
end
end
end
end
return bestClient, bestName, best2D, best3D
end
--- [Internal] Resolve/rebind owner to nearest valid C-130 after movement from spawn.
-- @param #DYNAMICCARGO self
-- @param Core.Point#COORDINATE Pos
-- @return Wrapper.Client#CLIENT Client
function DYNAMICCARGO:_ResolveC130Owner(Pos)
if not Pos or not self._spawnVec3 then return nil end
local moved2D = UTILS.VecDist2D(Pos, self._spawnVec3)
if moved2D < (DYNAMICCARGO.C130OwnerResolveMove2D or 10) then
return nil
end
local max3D = DYNAMICCARGO.C130OwnerResolveMax3D or 250
local known = self:_GetKnownCarrierClient()
if known and known:IsAlive() and self:_IsC130Type(known:GetTypeName()) then
local kpos = known:GetCoordinate()
if kpos and kpos:Get3DDistance(Pos) <= max3D then
self:_SetCarrierFromClient(known)
return known
end
end
local nearest, playerName, d2 = self:_FindNearestC130(Pos, DYNAMICCARGO.C130OwnerResolveMax3D)
if nearest and d2 and d2 <= (DYNAMICCARGO.C130OwnerResolveNear2D or 4) then
self:_SetCarrierFromClient(nearest, playerName)
self._ownerResolved = true
self:T(self.lid.." C130 owner re-resolved to "..tostring(self._carrierUnitName).." / "..tostring(self.Owner))
return nearest
end
return nil
end
--- [Internal] Determine whether to run C-130 transport-state handling for this cargo tick.
-- @param #DYNAMICCARGO self
-- @param Core.Point#COORDINATE Pos
-- @return #boolean Outcome
function DYNAMICCARGO:_ShouldUseC130State(Pos)
if self:_IsC130Type(self._carrierTypeName) then
return true
end
local known = self:_GetKnownCarrierClient()
if known and self:_IsC130Type(known:GetTypeName()) then
self:_SetCarrierFromClient(known)
return true
end
if self._attached or self._detached or self._wasAirborne then
return true
end
if self.CargoState == DYNAMICCARGO.State.NEW or self.CargoState == DYNAMICCARGO.State.UNLOADED then
local nearest, _, d2 = self:_FindNearestC130(Pos, DYNAMICCARGO.C130AttachDistance + 50)
if nearest and d2 and d2 <= (DYNAMICCARGO.C130AttachDistance + 5) then
return true
end
end
return false
end
--- [Internal] C-130-specific transport state update.
-- @param #DYNAMICCARGO self
-- @param Core.Point#COORDINATE Pos
-- @return #DYNAMICCARGO self
function DYNAMICCARGO:_UpdatePositionC130(Pos)
local attachDist = DYNAMICCARGO.C130AttachDistance or 10
local detachDist = DYNAMICCARGO.C130DetachDistance or 14
local airborneAgl = DYNAMICCARGO.C130AirborneAGL or 8
local landedAgl = DYNAMICCARGO.C130LandedAGL or 0.5
local stableEps = DYNAMICCARGO.C130StabilityEpsilon or 0.05
local requireAirborne = DYNAMICCARGO.C130RequireAirborne ~= false
local cargoAgl = self:_GetAGL(Pos)
local carrier = self:_GetKnownCarrierClient()
if carrier and not self:_IsC130Type(carrier:GetTypeName()) then
carrier = nil
end
if not carrier then
carrier = self:_ResolveC130Owner(Pos)
end
-- Attach detection: grounded C-130 close to cargo.
if (self.CargoState == DYNAMICCARGO.State.NEW or self.CargoState == DYNAMICCARGO.State.UNLOADED) and (not self._attached) then
if not carrier then
local nearest, pname, d2 = self:_FindNearestC130(Pos, DYNAMICCARGO.C130OwnerResolveMax3D)
if nearest and d2 and d2 <= attachDist and not nearest:InAir() then
carrier = nearest
self:_SetCarrierFromClient(nearest, pname)
end
end
if carrier and carrier:IsAlive() then
local hpos = carrier:GetCoordinate()
if hpos and (not carrier:InAir()) and hpos:Get2DDistance(Pos) <= attachDist then
self._attached = true
self._detached = false
self._wasAirborne = false
self._landAglConfirm = nil
self:_SetCarrierFromClient(carrier)
if self.CargoState ~= DYNAMICCARGO.State.LOADED then
self.CargoState = DYNAMICCARGO.State.LOADED
self:T(self.lid.." C130 attach: "..tostring(self.Owner))
_DATABASE:CreateEventDynamicCargoLoaded(self)
end
end
end
end
if self.CargoState == DYNAMICCARGO.State.LOADED then
if not carrier then
carrier = self:_ResolveC130Owner(Pos)
end
local carrierInAir = false
local dist2D = math.huge
local carrierAgl = -1
if carrier and carrier:IsAlive() then
local hpos = carrier:GetCoordinate()
if hpos then
dist2D = hpos:Get2DDistance(Pos)
carrierAgl = self:_GetAGL(hpos)
end
carrierInAir = carrier:InAir()
self:_SetCarrierFromClient(carrier)
end
if cargoAgl >= airborneAgl or carrierAgl >= airborneAgl then
self._wasAirborne = true
end
-- Detach only when actually airborne and separated.
if self._attached and carrierInAir and dist2D > detachDist then
self._attached = false
self._detached = true
self._landAglConfirm = nil
self:T(self.lid.." C130 detach at d2="..tostring(UTILS.Round(dist2D,2)))
end
-- Fallback detach if carrier reference is stale but cargo already transitioned airborne.
if self._attached and (not carrier or not carrier:IsAlive()) and self._wasAirborne and cargoAgl <= airborneAgl then
self._attached = false
self._detached = true
self._landAglConfirm = nil
self:T(self.lid.." C130 detach fallback (carrier stale)")
end
local canUnload = self._detached and ((not requireAirborne) or self._wasAirborne)
if canUnload then
local moved3D = self.LastPosition and UTILS.VecDist3D(Pos, self.LastPosition) or math.huge
local stable = moved3D <= stableEps
if cargoAgl <= landedAgl and stable then
if self._landAglConfirm then
self.CargoState = DYNAMICCARGO.State.UNLOADED
self:T(self.lid.." C130 landed-stable unload by "..tostring(self.Owner))
_DATABASE:CreateEventDynamicCargoUnloaded(self)
else
self._landAglConfirm = true
end
else
self._landAglConfirm = nil
end
end
end
return self
end
--- [Internal] _Get helo hovering intel --- [Internal] _Get helo hovering intel
-- @param #DYNAMICCARGO self -- @param #DYNAMICCARGO self
-- @param Wrapper.Unit#UNIT Unit The Unit to test -- @param Wrapper.Unit#UNIT Unit The Unit to test
@@ -444,11 +911,12 @@ function DYNAMICCARGO:_GetPossibleHeloNearby(pos,loading)
local hpos = helo:GetCoordinate() local hpos = helo:GetCoordinate()
-- TODO Check unloading via sling load? -- TODO Check unloading via sling load?
local typename = helo:GetTypeName() local typename = helo:GetTypeName()
if not self:_IsC130Type(typename) then
local dimensions = DYNAMICCARGO.AircraftDimensions[typename] local dimensions = DYNAMICCARGO.AircraftDimensions[typename]
if hpos and typename and dimensions then
local hovering, height = self:_HeloHovering(helo,dimensions.ropelength) local hovering, height = self:_HeloHovering(helo,dimensions.ropelength)
local helolanded = not helo:InAir() local helolanded = not helo:InAir()
self:T(self.lid.." InAir: AGL/Hovering: "..hpos.y-hpos:GetLandHeight().."/"..tostring(hovering)) self:T(self.lid.." InAir: AGL/Hovering: "..hpos.y-hpos:GetLandHeight().."/"..tostring(hovering))
if hpos and typename and dimensions then
local delta2D = hpos:Get2DDistance(pos) local delta2D = hpos:Get2DDistance(pos)
local delta3D = hpos:Get3DDistance(pos) local delta3D = hpos:Get3DDistance(pos)
if self.testing then if self.testing then
@@ -476,6 +944,7 @@ function DYNAMICCARGO:_GetPossibleHeloNearby(pos,loading)
end end
end end
end end
end
return success,Helo,Playername return success,Helo,Playername
end end
@@ -490,17 +959,27 @@ function DYNAMICCARGO:_UpdatePosition()
self:T(string.format("Cargo position: x=%d, y=%d, z=%d",pos.x,pos.y,pos.z)) self:T(string.format("Cargo position: x=%d, y=%d, z=%d",pos.x,pos.y,pos.z))
self:T(string.format("Last position: x=%d, y=%d, z=%d",self.LastPosition.x,self.LastPosition.y,self.LastPosition.z)) self:T(string.format("Last position: x=%d, y=%d, z=%d",self.LastPosition.x,self.LastPosition.y,self.LastPosition.z))
end end
if UTILS.Round(UTILS.VecDist3D(pos,self.LastPosition),2) > 0.5 then -- This checks if the cargo has moved more than 0.5m since last check. If so then the cargo is loaded local moved = UTILS.Round(UTILS.VecDist3D(pos,self.LastPosition),2) > 0.5
if self:_ShouldUseC130State(pos) then
self:_UpdatePositionC130(pos)
self.LastPosition = pos
elseif moved then -- This checks if the cargo has moved more than 0.5m since last check. If so then the cargo is loaded
--------------- ---------------
-- LOAD Cargo -- LOAD Cargo
--------------- ---------------
if self.CargoState == DYNAMICCARGO.State.NEW or self.CargoState == DYNAMICCARGO.State.UNLOADED then if self.CargoState == DYNAMICCARGO.State.NEW or self.CargoState == DYNAMICCARGO.State.UNLOADED then
local isloaded, client, playername = self:_GetPossibleHeloNearby(pos,true) local isloaded, client, playername = self:_GetPossibleHeloNearby(pos,true)
if isloaded then
self:T(self.lid.." moved! NEW -> LOADED by "..tostring(playername)) self:T(self.lid.." moved! NEW -> LOADED by "..tostring(playername))
self.CargoState = DYNAMICCARGO.State.LOADED self.CargoState = DYNAMICCARGO.State.LOADED
self.Owner = playername self.Owner = playername
if client then
self:_SetCarrierFromClient(client, playername)
end
_DATABASE:CreateEventDynamicCargoLoaded(self) _DATABASE:CreateEventDynamicCargoLoaded(self)
end end
end
self.LastPosition = pos
--------------- ---------------
-- UNLOAD Cargo -- UNLOAD Cargo
--------------- ---------------
@@ -524,24 +1003,25 @@ function DYNAMICCARGO:_UpdatePosition()
self:T(self.lid.." moved! LOADED -> UNLOADED by "..tostring(playername)) self:T(self.lid.." moved! LOADED -> UNLOADED by "..tostring(playername))
self.CargoState = DYNAMICCARGO.State.UNLOADED self.CargoState = DYNAMICCARGO.State.UNLOADED
self.Owner = playername self.Owner = playername
if client then
self:_SetCarrierFromClient(client, playername)
end
_DATABASE:CreateEventDynamicCargoUnloaded(self) _DATABASE:CreateEventDynamicCargoUnloaded(self)
end end
end end
end end
self.LastPosition = pos
--end
else else
--------------- ---------------
-- REMOVED Cargo -- REMOVED Cargo
--------------- ---------------
if self.timer and self.timer:IsRunning() then if self.CargoState ~= DYNAMICCARGO.State.REMOVED then
self.timer:Stop() DYNAMICCARGO._UntrackCargo(self.StaticName)
self.timer=nil self.timer=nil
end
self:T(self.lid.." dead! " ..self.CargoState.."-> REMOVED") self:T(self.lid.." dead! " ..self.CargoState.."-> REMOVED")
self.CargoState = DYNAMICCARGO.State.REMOVED self.CargoState = DYNAMICCARGO.State.REMOVED
_DATABASE:CreateEventDynamicCargoRemoved(self) _DATABASE:CreateEventDynamicCargoRemoved(self)
end end
end
return self return self
end end
+1 -1
View File
@@ -604,7 +604,7 @@ end
-- See [hoggit documentation](https://wiki.hoggitworld.com/view/DCS_func_hasAttribute). -- See [hoggit documentation](https://wiki.hoggitworld.com/view/DCS_func_hasAttribute).
-- @param #GROUP self -- @param #GROUP self
-- @param #string attribute The name of the attribute the group is supposed to have. Valid attributes can be found in the "db_attributes.lua" file which is located at in "C:\Program Files\Eagle Dynamics\DCS World\Scripts\Database". -- @param #string attribute The name of the attribute the group is supposed to have. Valid attributes can be found in the "db_attributes.lua" file which is located at in "C:\Program Files\Eagle Dynamics\DCS World\Scripts\Database".
-- @param #boolean all If true, all units of the group must have the attribute in order to return true. Default is only one unit of a heterogenious group needs to have the attribute. -- @param #boolean all (Optional) If true, all units of the group must have the attribute in order to return true. Default is only one unit of a heterogenious group needs to have the attribute.
-- @return #boolean Group has this attribute. -- @return #boolean Group has this attribute.
function GROUP:HasAttribute(attribute, all) function GROUP:HasAttribute(attribute, all)
+1 -1
View File
@@ -586,7 +586,7 @@ end
--- Set text that is displayed in the marker panel. Note this does not show the marker. --- Set text that is displayed in the marker panel. Note this does not show the marker.
-- @param #MARKER self -- @param #MARKER self
-- @param #string Text Marker text. Default is an empty string "". -- @param #string (Optional) Text Marker text. Default is an empty string "".
-- @return #MARKER self -- @return #MARKER self
function MARKER:SetText( Text ) function MARKER:SetText( Text )
self.text = Text and tostring( Text ) or "" self.text = Text and tostring( Text ) or ""
+1 -1
View File
@@ -449,7 +449,7 @@ end
--- Set block time in seconds. --- Set block time in seconds.
-- @param #NET self -- @param #NET self
-- @param #number Seconds Numnber of seconds this block will last. Defaults to 600. -- @param #number Seconds (Optional) Numnber of seconds this block will last. Defaults to 600.
-- @return #NET self -- @return #NET self
function NET:SetBlockTime(Seconds) function NET:SetBlockTime(Seconds)
self.BlockTime = Seconds or 600 self.BlockTime = Seconds or 600
@@ -449,7 +449,7 @@ end
--- Triggers an explosion at the coordinates of the positionable. --- Triggers an explosion at the coordinates of the positionable.
-- @param #POSITIONABLE self -- @param #POSITIONABLE self
-- @param #number power Power of the explosion in kg TNT. Default 100 kg TNT. -- @param #number power (Optional) Power of the explosion in kg TNT. Default 100 kg TNT.
-- @param #number delay (Optional) Delay of explosion in seconds. -- @param #number delay (Optional) Delay of explosion in seconds.
-- @return #POSITIONABLE self -- @return #POSITIONABLE self
function POSITIONABLE:Explode(power, delay) function POSITIONABLE:Explode(power, delay)
@@ -477,9 +477,9 @@ end
--- Returns a COORDINATE object, which is offset with respect to the orientation of the POSITIONABLE. --- Returns a COORDINATE object, which is offset with respect to the orientation of the POSITIONABLE.
-- @param #POSITIONABLE self -- @param #POSITIONABLE self
-- @param #number x Offset in the direction "the nose" of the unit is pointing in meters. Default 0 m. -- @param #number x (Optional) Offset in the direction "the nose" of the unit is pointing in meters. Default 0 m.
-- @param #number y Offset "above" the unit in meters. Default 0 m. -- @param #number y (Optional) Offset "above" the unit in meters. Default 0 m.
-- @param #number z Offset in the direction "the wing" of the unit is pointing in meters. z>0 starboard, z<0 port. Default 0 m. -- @param #number z(Optional) Offset in the direction "the wing" of the unit is pointing in meters. z>0 starboard, z<0 port. Default 0 m.
-- @return Core.Point#COORDINATE The COORDINATE of the offset with respect to the orientation of the POSITIONABLE. -- @return Core.Point#COORDINATE The COORDINATE of the offset with respect to the orientation of the POSITIONABLE.
function POSITIONABLE:GetOffsetCoordinate( x, y, z ) function POSITIONABLE:GetOffsetCoordinate( x, y, z )
@@ -518,9 +518,9 @@ end
--- Returns a COORDINATE object, which is transformed to be relative to the POSITIONABLE. Inverse of @{#POSITIONABLE.GetOffsetCoordinate}. --- Returns a COORDINATE object, which is transformed to be relative to the POSITIONABLE. Inverse of @{#POSITIONABLE.GetOffsetCoordinate}.
-- @param #POSITIONABLE self -- @param #POSITIONABLE self
-- @param #number x Offset along the world x-axis in meters. Default 0 m. -- @param #number x (Optional) Offset along the world x-axis in meters. Default 0 m.
-- @param #number y Offset along the world y-axis in meters. Default 0 m. -- @param #number y (Optional) Offset along the world y-axis in meters. Default 0 m.
-- @param #number z Offset along the world z-axis in meters. Default 0 m. -- @param #number z (Optional) Offset along the world z-axis in meters. Default 0 m.
-- @return Core.Point#COORDINATE The relative COORDINATE with respect to the orientation of the POSITIONABLE. -- @return Core.Point#COORDINATE The relative COORDINATE with respect to the orientation of the POSITIONABLE.
function POSITIONABLE:GetRelativeCoordinate( x, y, z ) function POSITIONABLE:GetRelativeCoordinate( x, y, z )
+1 -1
View File
@@ -246,7 +246,7 @@ end
--- Spawn the @{Wrapper.Static} at a specific coordinate and heading. --- Spawn the @{Wrapper.Static} at a specific coordinate and heading.
-- @param #STATIC self -- @param #STATIC self
-- @param Core.Point#COORDINATE Coordinate The coordinate where to spawn the new Static. -- @param Core.Point#COORDINATE Coordinate The coordinate where to spawn the new Static.
-- @param #number Heading The heading of the static respawn in degrees. Default is 0 deg. -- @param #number Heading (Optional) The heading of the static respawn in degrees. Default is 0 deg.
-- @param #number Delay Delay in seconds before the static is spawned. -- @param #number Delay Delay in seconds before the static is spawned.
function STATIC:SpawnAt(Coordinate, Heading, Delay) function STATIC:SpawnAt(Coordinate, Heading, Delay)
+2 -2
View File
@@ -292,7 +292,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #STORAGE self -- @param #STORAGE self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #STORAGE self -- @return #STORAGE self
function STORAGE:SetVerbosity(VerbosityLevel) function STORAGE:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -816,7 +816,7 @@ end
-- @param #STORAGE self -- @param #STORAGE self
-- @param #string Path The path to use. Use double backslashes \\\\ on Windows filesystems. -- @param #string Path The path to use. Use double backslashes \\\\ on Windows filesystems.
-- @param #string Filename The name of the file. -- @param #string Filename The name of the file.
-- @param #number Interval The interval, start after this many seconds and repeat every interval seconds. Defaults to 300. -- @param #number Interval (Optional) The interval, start after this many seconds and repeat every interval seconds. Defaults to 300.
-- @param #boolean LoadOnce If LoadOnce is true or nil, we try to load saved storage first. -- @param #boolean LoadOnce If LoadOnce is true or nil, we try to load saved storage first.
-- @return #STORAGE self -- @return #STORAGE self
function STORAGE:StartAutoSave(Path,Filename,Interval,LoadOnce) function STORAGE:StartAutoSave(Path,Filename,Interval,LoadOnce)
+1 -1
View File
@@ -1445,7 +1445,7 @@ end
--- Triggers an explosion at the coordinates of the unit. --- Triggers an explosion at the coordinates of the unit.
-- @param #UNIT self -- @param #UNIT self
-- @param #number power Power of the explosion in kg TNT. Default 100 kg TNT. -- @param #number power (Optional) Power of the explosion in kg TNT. Default 100 kg TNT.
-- @param #number delay (Optional) Delay of explosion in seconds. -- @param #number delay (Optional) Delay of explosion in seconds.
-- @return #UNIT self -- @return #UNIT self
function UNIT:Explode(power, delay) function UNIT:Explode(power, delay)
+6 -6
View File
@@ -259,7 +259,7 @@ end
--- Set verbosity level. --- Set verbosity level.
-- @param #WEAPON self -- @param #WEAPON self
-- @param #number VerbosityLevel Level of output (higher=more). Default 0. -- @param #number VerbosityLevel (Optional) Level of output (higher=more). Default 0.
-- @return #WEAPON self -- @return #WEAPON self
function WEAPON:SetVerbosity(VerbosityLevel) function WEAPON:SetVerbosity(VerbosityLevel)
self.verbose=VerbosityLevel or 0 self.verbose=VerbosityLevel or 0
@@ -268,7 +268,7 @@ end
--- Set track position time step. --- Set track position time step.
-- @param #WEAPON self -- @param #WEAPON self
-- @param #number TimeStep Time step in seconds when the position is updated. Default 0.01 sec ==> 100 evaluations per second. -- @param #number TimeStep (Optional) Time step in seconds when the position is updated. Default 0.01 sec ==> 100 evaluations per second.
-- @return #WEAPON self -- @return #WEAPON self
function WEAPON:SetTimeStepTrack(TimeStep) function WEAPON:SetTimeStepTrack(TimeStep)
self.dtTrack=TimeStep or 0.01 self.dtTrack=TimeStep or 0.01
@@ -281,7 +281,7 @@ end
-- a good result on the impact point. -- a good result on the impact point.
-- It uses the DCS function [getIP](https://wiki.hoggitworld.com/view/DCS_func_getIP). -- It uses the DCS function [getIP](https://wiki.hoggitworld.com/view/DCS_func_getIP).
-- @param #WEAPON self -- @param #WEAPON self
-- @param #number Distance Distance in meters. Default is 50 m. Set to 0 to deactivate. -- @param #number Distance (Optional) Distance in meters. Default is 50 m. Set to 0 to deactivate.
-- @return #WEAPON self -- @return #WEAPON self
function WEAPON:SetDistanceInterceptPoint(Distance) function WEAPON:SetDistanceInterceptPoint(Distance)
self.distIP=Distance or 50 self.distIP=Distance or 50
@@ -307,7 +307,7 @@ end
--- Put smoke on impact point. This requires that the tracking has been started. --- Put smoke on impact point. This requires that the tracking has been started.
-- @param #WEAPON self -- @param #WEAPON self
-- @param #boolean Switch If `true` or nil, impact is smoked. -- @param #boolean Switch If `true` or nil, impact is smoked.
-- @param #number SmokeColor Color of smoke. Default is `SMOKECOLOR.Red`. -- @param #number SmokeColor (Optional) Color of smoke. Default is `SMOKECOLOR.Red`.
-- @return #WEAPON self -- @return #WEAPON self
function WEAPON:SetSmokeImpact(Switch, SmokeColor) function WEAPON:SetSmokeImpact(Switch, SmokeColor)
@@ -718,7 +718,7 @@ end
-- the (approximate) impact point. Of course, the smaller the time step, the better the position can be determined. However, this can hit the performance as many -- the (approximate) impact point. Of course, the smaller the time step, the better the position can be determined. However, this can hit the performance as many
-- calculations per second need to be carried out. -- calculations per second need to be carried out.
-- @param #WEAPON self -- @param #WEAPON self
-- @param #number Delay Delay in seconds before the tracking starts. Default 0.001 sec. -- @param #number Delay (Optional) Delay in seconds before the tracking starts. Default 0.001 sec.
-- @return #WEAPON self -- @return #WEAPON self
function WEAPON:StartTrack(Delay) function WEAPON:StartTrack(Delay)
@@ -904,7 +904,7 @@ end
--- Compute estimated intercept/impact point (IP) based on last known position and direction. --- Compute estimated intercept/impact point (IP) based on last known position and direction.
-- @param #WEAPON self -- @param #WEAPON self
-- @param #number Distance Distance in meters. Default 50 m. -- @param #number Distance (Optional) Distance in meters. Default 50 m.
-- @return DCS#Vec3 Estimated intercept/impact point. Can also return `nil`, if no IP can be determined. -- @return DCS#Vec3 Estimated intercept/impact point. Can also return `nil`, if no IP can be determined.
function WEAPON:_GetIP(Distance) function WEAPON:_GetIP(Distance)
+3
View File
@@ -98,6 +98,9 @@ Ops/Commander.lua
Ops/Chief.lua Ops/Chief.lua
Ops/CSAR.lua Ops/CSAR.lua
Ops/CTLD.lua Ops/CTLD.lua
Ops/CTLD_CARGO.lua
Ops/CTLD_Localization.lua
Ops/CTLD_Hercules.lua
Ops/Awacs.lua Ops/Awacs.lua
Ops/Operation.lua Ops/Operation.lua
Ops/FlightControl.lua Ops/FlightControl.lua