diff --git a/Moose Development/Moose/Core/Point.lua b/Moose Development/Moose/Core/Point.lua index 9c6628980..35cd570c9 100644 --- a/Moose Development/Moose/Core/Point.lua +++ b/Moose Development/Moose/Core/Point.lua @@ -54,227 +54,114 @@ -- @module Point ---- @type COORDINATE --- @extends Core.Base#BASE ---- # COORDINATE class, extends @{Base#BASE} --- --- The COORDINATE class defines a 2D coordinate in the simulator. The height coordinate (if needed) will be the land height + an optional added height specified. --- A COORDINATE can be expressed in LL or in MGRS. --- --- ## COORDINATE constructor --- --- A new COORDINATE instance can be created with: --- --- * @{Point#COORDINATE.New}(): a 2D point, taking an additional height parameter. --- * @{Point#COORDINATE.NewFromVec2}(): a 2D point created from a @{DCSTypes#Vec2}. --- --- ## Manupulate the X, Altitude, Y coordinates of the 2D point --- --- A COORDINATE class works in 2D space, with an altitude setting. It contains internally an X, Altitude, Y coordinate. --- Methods exist to manupulate these coordinates. --- --- The current X, Altitude, Y axis can be retrieved with the methods @{#COORDINATE.GetX}(), @{#COORDINATE.GetAlt}(), @{#COORDINATE.GetY}() respectively. --- The methods @{#COORDINATE.SetX}(), @{#COORDINATE.SetAlt}(), @{#COORDINATE.SetY}() change the respective axis with a new value. --- The current Lat(itude), Alt(itude), Lon(gitude) values can also be retrieved with the methods @{#COORDINATE.GetLat}(), @{#COORDINATE.GetAlt}(), @{#COORDINATE.GetLon}() respectively. --- The current axis values can be changed by using the methods @{#COORDINATE.AddX}(), @{#COORDINATE.AddAlt}(), @{#COORDINATE.AddY}() --- to add or substract a value from the current respective axis value. --- Note that the Set and Add methods return the current COORDINATE object, so these manipulation methods can be chained... For example: --- --- local Vec2 = PointVec2:AddX( 100 ):AddY( 2000 ):GetVec2() --- --- @field #COORDINATE -COORDINATE = { - ClassName = "COORDINATE", -} - ---- The POINT_VEC3 class --- @type POINT_VEC3 --- @field #number x The x coordinate in 3D space. --- @field #number y The y coordinate in 3D space. --- @field #number z The z coordiante in 3D space. --- @field Utilities.Utils#SMOKECOLOR SmokeColor --- @field Utilities.Utils#FLARECOLOR FlareColor --- @field #POINT_VEC3.RoutePointAltType RoutePointAltType --- @field #POINT_VEC3.RoutePointType RoutePointType --- @field #POINT_VEC3.RoutePointAction RoutePointAction --- @extends Core.Point#COORDINATE - - ---- # POINT_VEC3 class, extends @{Point#COORDINATE} --- --- POINT_VEC3 defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space. --- --- **Important Note:** Most of the functions in this section were taken from MIST, and reworked to OO concepts. --- In order to keep the credibility of the the author, --- I want to emphasize that the formulas embedded in the MIST framework were created by Grimes or previous authors, --- who you can find on the Eagle Dynamics Forums. --- --- --- ## POINT_VEC3 constructor --- --- A new POINT_VEC3 object can be created with: --- --- * @{#POINT_VEC3.New}(): a 3D point. --- * @{#POINT_VEC3.NewFromVec3}(): a 3D point created from a @{DCSTypes#Vec3}. --- --- --- ## Manupulate the X, Y, Z coordinates of the POINT_VEC3 --- --- A POINT_VEC3 class works in 3D space. It contains internally an X, Y, Z coordinate. --- Methods exist to manupulate these coordinates. --- --- The current X, Y, Z axis can be retrieved with the methods @{#POINT_VEC3.GetX}(), @{#POINT_VEC3.GetY}(), @{#POINT_VEC3.GetZ}() respectively. --- The methods @{#POINT_VEC3.SetX}(), @{#POINT_VEC3.SetY}(), @{#POINT_VEC3.SetZ}() change the respective axis with a new value. --- The current axis values can be changed by using the methods @{#POINT_VEC3.AddX}(), @{#POINT_VEC3.AddY}(), @{#POINT_VEC3.AddZ}() --- to add or substract a value from the current respective axis value. --- Note that the Set and Add methods return the current POINT_VEC3 object, so these manipulation methods can be chained... For example: --- --- local Vec3 = PointVec3:AddX( 100 ):AddZ( 150 ):GetVec3() --- --- --- ## Create waypoints for routes --- --- A POINT_VEC3 can prepare waypoints for Ground and Air groups to be embedded into a Route. --- --- * @{#POINT_VEC3.RoutePointAir}(): Build an air route point. --- * @{#POINT_VEC3.RoutePointGround}(): Build a ground route point. --- --- Route points can be used in the Route methods of the @{Group#GROUP} class. --- --- --- ## Smoke, flare, explode, illuminate --- --- At the point a smoke, flare, explosion and illumination bomb can be triggered. Use the following methods: --- --- ### Smoke --- --- * @{#POINT_VEC3.Smoke}(): To smoke the point in a certain color. --- * @{#POINT_VEC3.SmokeBlue}(): To smoke the point in blue. --- * @{#POINT_VEC3.SmokeRed}(): To smoke the point in red. --- * @{#POINT_VEC3.SmokeOrange}(): To smoke the point in orange. --- * @{#POINT_VEC3.SmokeWhite}(): To smoke the point in white. --- * @{#POINT_VEC3.SmokeGreen}(): To smoke the point in green. --- --- ### Flare --- --- * @{#POINT_VEC3.Flare}(): To flare the point in a certain color. --- * @{#POINT_VEC3.FlareRed}(): To flare the point in red. --- * @{#POINT_VEC3.FlareYellow}(): To flare the point in yellow. --- * @{#POINT_VEC3.FlareWhite}(): To flare the point in white. --- * @{#POINT_VEC3.FlareGreen}(): To flare the point in green. --- --- ### Explode --- --- * @{#POINT_VEC3.Explosion}(): To explode the point with a certain intensity. --- --- ### Illuminate --- --- * @{#POINT_VEC3.IlluminationBomb}(): To illuminate the point. --- --- --- ## 3D calculation methods --- --- Various calculation methods exist to use or manipulate 3D space. Find below a short description of each method: --- --- ### Distance --- --- * @{#POINT_VEC3.Get3DDistance}(): Obtain the distance from the current 3D point to the provided 3D point in 3D space. --- * @{#POINT_VEC3.Get2DDistance}(): Obtain the distance from the current 3D point to the provided 3D point in 2D space. --- --- ### Angle --- --- * @{#POINT_VEC3.GetAngleDegrees}(): Obtain the angle in degrees from the current 3D point with the provided 3D direction vector. --- * @{#POINT_VEC3.GetAngleRadians}(): Obtain the angle in radians from the current 3D point with the provided 3D direction vector. --- * @{#POINT_VEC3.GetDirectionVec3}(): Obtain the 3D direction vector from the current 3D point to the provided 3D point. --- --- ### Translation --- --- * @{#POINT_VEC3.Translate}(): Translate the current 3D point towards an other 3D point using the given Distance and Angle. --- --- ### Get the North correction of the current location --- --- * @{#POINT_VEC3.GetNorthCorrection}(): Obtains the north correction at the current 3D point. --- --- --- ## Point Randomization --- --- Various methods exist to calculate random locations around a given 3D point. --- --- * @{#POINT_VEC3.GetRandomPointVec2InRadius}(): Provides a random 2D point around the current 3D point, in the given inner to outer band. --- * @{#POINT_VEC3.GetRandomPointVec3InRadius}(): Provides a random 3D point around the current 3D point, in the given inner to outer band. --- * @{#POINT_VEC3.GetRandomVec2InRadius}(): Provides a random 2D vector around the current 3D point, in the given inner to outer band. --- * @{#POINT_VEC3.GetRandomVec3InRadius}(): Provides a random 3D vector around the current 3D point, in the given inner to outer band. --- --- --- ## Metric system --- --- * @{#POINT_VEC3.IsMetric}(): Returns if the 3D point is Metric or Nautical Miles. --- * @{#POINT_VEC3.SetMetric}(): Sets the 3D point to Metric or Nautical Miles. --- --- --- ## Coorinate text generation --- --- * @{#POINT_VEC3.ToStringBR}(): Generates a Bearing & Range text in the format of DDD for DI where DDD is degrees and DI is distance. --- * @{#POINT_VEC3.ToStringLL}(): Generates a Latutude & Longutude text. --- --- @field #POINT_VEC3 -POINT_VEC3 = { - ClassName = "POINT_VEC3", - Metric = true, - RoutePointAltType = { - BARO = "BARO", - }, - RoutePointType = { - TakeOffParking = "TakeOffParking", - TurningPoint = "Turning Point", - }, - RoutePointAction = { - FromParkingArea = "From Parking Area", - TurningPoint = "Turning Point", - }, -} - ---- @type POINT_VEC2 --- @field Dcs.DCSTypes#Distance x The x coordinate in meters. --- @field Dcs.DCSTypes#Distance y the y coordinate in meters. --- @extends Core.Point#COORDINATE - - - ---- # POINT_VEC2 class, extends @{Point#COORDINATE} --- --- The @{Point#POINT_VEC2} class defines a 2D point in the simulator. The height coordinate (if needed) will be the land height + an optional added height specified. --- --- ## POINT_VEC2 constructor --- --- A new POINT_VEC2 instance can be created with: --- --- * @{Point#POINT_VEC2.New}(): a 2D point, taking an additional height parameter. --- * @{Point#POINT_VEC2.NewFromVec2}(): a 2D point created from a @{DCSTypes#Vec2}. --- --- ## Manupulate the X, Altitude, Y coordinates of the 2D point --- --- A POINT_VEC2 class works in 2D space, with an altitude setting. It contains internally an X, Altitude, Y coordinate. --- Methods exist to manupulate these coordinates. --- --- The current X, Altitude, Y axis can be retrieved with the methods @{#POINT_VEC2.GetX}(), @{#POINT_VEC2.GetAlt}(), @{#POINT_VEC2.GetY}() respectively. --- The methods @{#POINT_VEC2.SetX}(), @{#POINT_VEC2.SetAlt}(), @{#POINT_VEC2.SetY}() change the respective axis with a new value. --- The current Lat(itude), Alt(itude), Lon(gitude) values can also be retrieved with the methods @{#POINT_VEC2.GetLat}(), @{#POINT_VEC2.GetAlt}(), @{#POINT_VEC2.GetLon}() respectively. --- The current axis values can be changed by using the methods @{#POINT_VEC2.AddX}(), @{#POINT_VEC2.AddAlt}(), @{#POINT_VEC2.AddY}() --- to add or substract a value from the current respective axis value. --- Note that the Set and Add methods return the current POINT_VEC2 object, so these manipulation methods can be chained... For example: --- --- local Vec2 = PointVec2:AddX( 100 ):AddY( 2000 ):GetVec2() --- --- @field #POINT_VEC2 -POINT_VEC2 = { - ClassName = "POINT_VEC2", -} do -- COORDINATE + --- @type COORDINATE + -- @extends Core.Base#BASE + + --- # COORDINATE class, extends @{Base#BASE} + -- + -- COORDINATE defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space. + -- + -- ## COORDINATE constructor + -- + -- A new COORDINATE object can be created with: + -- + -- * @{#COORDINATE.New}(): a 3D point. + -- * @{#COORDINATE.NewFromVec2}(): a 2D point created from a @{DCSTypes#Vec2}. + -- * @{#COORDINATE.NewFromVec3}(): a 3D point created from a @{DCSTypes#Vec3}. + -- + -- ## Create waypoints for routes + -- + -- A COORDINATE can prepare waypoints for Ground and Air groups to be embedded into a Route. + -- + -- * @{#COORDINATE.RoutePointAir}(): Build an air route point. + -- * @{#COORDINATE.RoutePointGround}(): Build a ground route point. + -- + -- Route points can be used in the Route methods of the @{Group#GROUP} class. + -- + -- + -- ## Smoke, flare, explode, illuminate + -- + -- At the point a smoke, flare, explosion and illumination bomb can be triggered. Use the following methods: + -- + -- ### Smoke + -- + -- * @{#COORDINATE.Smoke}(): To smoke the point in a certain color. + -- * @{#COORDINATE.SmokeBlue}(): To smoke the point in blue. + -- * @{#COORDINATE.SmokeRed}(): To smoke the point in red. + -- * @{#COORDINATE.SmokeOrange}(): To smoke the point in orange. + -- * @{#COORDINATE.SmokeWhite}(): To smoke the point in white. + -- * @{#COORDINATE.SmokeGreen}(): To smoke the point in green. + -- + -- ### Flare + -- + -- * @{#COORDINATE.Flare}(): To flare the point in a certain color. + -- * @{#COORDINATE.FlareRed}(): To flare the point in red. + -- * @{#COORDINATE.FlareYellow}(): To flare the point in yellow. + -- * @{#COORDINATE.FlareWhite}(): To flare the point in white. + -- * @{#COORDINATE.FlareGreen}(): To flare the point in green. + -- + -- ### Explode + -- + -- * @{#COORDINATE.Explosion}(): To explode the point with a certain intensity. + -- + -- ### Illuminate + -- + -- * @{#COORDINATE.IlluminationBomb}(): To illuminate the point. + -- + -- + -- ## 3D calculation methods + -- + -- Various calculation methods exist to use or manipulate 3D space. Find below a short description of each method: + -- + -- ### Distance + -- + -- * @{#COORDINATE.Get3DDistance}(): Obtain the distance from the current 3D point to the provided 3D point in 3D space. + -- * @{#COORDINATE.Get2DDistance}(): Obtain the distance from the current 3D point to the provided 3D point in 2D space. + -- + -- ### Angle + -- + -- * @{#COORDINATE.GetAngleDegrees}(): Obtain the angle in degrees from the current 3D point with the provided 3D direction vector. + -- * @{#COORDINATE.GetAngleRadians}(): Obtain the angle in radians from the current 3D point with the provided 3D direction vector. + -- * @{#COORDINATE.GetDirectionVec3}(): Obtain the 3D direction vector from the current 3D point to the provided 3D point. + -- + -- ### Translation + -- + -- * @{#COORDINATE.Translate}(): Translate the current 3D point towards an other 3D point using the given Distance and Angle. + -- + -- ### Get the North correction of the current location + -- + -- * @{#COORDINATE.GetNorthCorrection}(): Obtains the north correction at the current 3D point. + -- + -- + -- ## Point Randomization + -- + -- Various methods exist to calculate random locations around a given 3D point. + -- + -- * @{#COORDINATE.GetRandomVec2InRadius}(): Provides a random 2D vector around the current 3D point, in the given inner to outer band. + -- * @{#COORDINATE.GetRandomVec3InRadius}(): Provides a random 3D vector around the current 3D point, in the given inner to outer band. + -- + -- + -- ## Metric system + -- + -- * @{#COORDINATE.IsMetric}(): Returns if the 3D point is Metric or Nautical Miles. + -- * @{#COORDINATE.SetMetric}(): Sets the 3D point to Metric or Nautical Miles. + -- + -- + -- ## Coorinate text generation + -- + -- * @{#COORDINATE.ToStringBR}(): Generates a Bearing & Range text in the format of DDD for DI where DDD is degrees and DI is distance. + -- * @{#COORDINATE.ToStringLL}(): Generates a Latutude & Longutude text. + -- + -- @field #COORDINATE + COORDINATE = { + ClassName = "COORDINATE", + } + --- COORDINATE constructor. -- @param #COORDINATE self -- @param Dcs.DCSTypes#Distance x The x coordinate of the Vec3 point, pointing to the North. @@ -288,8 +175,6 @@ do -- COORDINATE self.y = y self.z = z - self:SetModeA2G() - return self end @@ -342,7 +227,83 @@ do -- COORDINATE function COORDINATE:GetVec2() return { x = self.x, y = self.z } end - + + --TODO: check this to replace + --- Calculate the distance from a reference @{DCSTypes#Vec2}. + -- @param #COORDINATE self + -- @param Dcs.DCSTypes#Vec2 Vec2Reference The reference @{DCSTypes#Vec2}. + -- @return Dcs.DCSTypes#Distance The distance from the reference @{DCSTypes#Vec2} in meters. + function COORDINATE:DistanceFromVec2( Vec2Reference ) + self:F2( Vec2Reference ) + + local Distance = ( ( Vec2Reference.x - self.x ) ^ 2 + ( Vec2Reference.y - self.z ) ^2 ) ^0.5 + + self:T2( Distance ) + return Distance + end + + + --- Add a Distance in meters from the COORDINATE orthonormal plane, with the given angle, and calculate the new COORDINATE. + -- @param #COORDINATE self + -- @param Dcs.DCSTypes#Distance Distance The Distance to be added in meters. + -- @param Dcs.DCSTypes#Angle Angle The Angle in degrees. + -- @return #COORDINATE The new calculated COORDINATE. + function COORDINATE:Translate( Distance, Angle ) + local SX = self.x + local SY = self.z + local Radians = Angle / 180 * math.pi + local TX = Distance * math.cos( Radians ) + SX + local TY = Distance * math.sin( Radians ) + SY + + return COORDINATE:NewFromVec2( { x = TX, y = TY } ) + end + + --- Return a random Vec2 within an Outer Radius and optionally NOT within an Inner Radius of the COORDINATE. + -- @param #COORDINATE self + -- @param Dcs.DCSTypes#Distance OuterRadius + -- @param Dcs.DCSTypes#Distance InnerRadius + -- @return Dcs.DCSTypes#Vec2 Vec2 + function COORDINATE:GetRandomVec2InRadius( OuterRadius, InnerRadius ) + self:F2( { OuterRadius, InnerRadius } ) + + local Theta = 2 * math.pi * math.random() + local Radials = math.random() + math.random() + if Radials > 1 then + Radials = 2 - Radials + end + + local RadialMultiplier + if InnerRadius and InnerRadius <= OuterRadius then + RadialMultiplier = ( OuterRadius - InnerRadius ) * Radials + InnerRadius + else + RadialMultiplier = OuterRadius * Radials + end + + local RandomVec2 + if OuterRadius > 0 then + RandomVec2 = { x = math.cos( Theta ) * RadialMultiplier + self.x, y = math.sin( Theta ) * RadialMultiplier + self.z } + else + RandomVec2 = { x = self.x, y = self.z } + end + + return RandomVec2 + end + + + --- Return a random Vec3 within an Outer Radius and optionally NOT within an Inner Radius of the COORDINATE. + -- @param #COORDINATE self + -- @param Dcs.DCSTypes#Distance OuterRadius + -- @param Dcs.DCSTypes#Distance InnerRadius + -- @return Dcs.DCSTypes#Vec3 Vec3 + function COORDINATE:GetRandomVec3InRadius( OuterRadius, InnerRadius ) + + local RandomVec2 = self:GetRandomVec2InRadius( OuterRadius, InnerRadius ) + local y = self.y + math.random( InnerRadius, OuterRadius ) + local RandomVec3 = { x = RandomVec2.x, y = y, z = RandomVec2.y } + + return RandomVec3 + end + function COORDINATE:SetHeading( Heading ) self.Heading = Heading @@ -706,7 +667,7 @@ do -- COORDINATE self:Flare( FLARECOLOR.Red, Azimuth ) end - --- Returns if a Coordinate has Line of Sight (LOS) with the ToPointVec3. + --- Returns if a Coordinate has Line of Sight (LOS) with the ToCoordinate. -- @param #COORDINATE self -- @param #COORDINATE ToCoordinate -- @return #boolean true If the ToCoordinate has LOS with the Coordinate, otherwise false. @@ -725,35 +686,6 @@ do -- COORDINATE end - --- Set the mode to A2G - -- @param #COORDINATE self - -- @return #COORDINATE - function COORDINATE:SetModeA2G() - self.Mode = "A2G" - end - - --- Is the mode to A2G - -- @param #COORDINATE self - -- @return #boolean - function COORDINATE:IsModeA2G() - return self.Mode == "A2G" - end - - --- Set the mode to A2A - -- @param #COORDINATE self - -- @return #COORDINATE - function COORDINATE:SetModeA2A() - self.Mode = "A2A" - end - - --- Is the mode to A2A - -- @param #COORDINATE self - -- @return #boolean - function COORDINATE:IsModeA2A() - return self.Mode == "A2A" - end - - --- Return a BR string from a COORDINATE to the COORDINATE. -- @param #COORDINATE self -- @param #COORDINATE TargetCoordinate The target COORDINATE. @@ -859,19 +791,16 @@ do -- COORDINATE if IsAir then if Settings:IsA2A_BRA() then local Coordinate = Controllable:GetCoordinate() - Coordinate:SetModeA2A() return self:ToStringBRA( Coordinate, Settings ) end if Settings:IsA2A_BULLS() then local Coordinate = Controllable:GetCoordinate() - Coordinate:SetModeA2A() return self:ToStringBULLS( Coordinate, Settings ) end else if Settings:IsA2G_BRA() then local Coordinate = Controllable:GetCoordinate() - Coordinate:SetModeA2A() return Controllable and self:ToStringBR( Coordinate, Settings ) or self:ToStringMGRS( Settings ) end if Settings:IsA2G_LL() then @@ -890,6 +819,80 @@ end do -- POINT_VEC3 + --- The POINT_VEC3 class + -- @type POINT_VEC3 + -- @field #number x The x coordinate in 3D space. + -- @field #number y The y coordinate in 3D space. + -- @field #number z The z coordiante in 3D space. + -- @field Utilities.Utils#SMOKECOLOR SmokeColor + -- @field Utilities.Utils#FLARECOLOR FlareColor + -- @field #POINT_VEC3.RoutePointAltType RoutePointAltType + -- @field #POINT_VEC3.RoutePointType RoutePointType + -- @field #POINT_VEC3.RoutePointAction RoutePointAction + -- @extends Core.Point#COORDINATE + + + --- # POINT_VEC3 class, extends @{Point#COORDINATE} + -- + -- POINT_VEC3 defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space. + -- + -- **Important Note:** Most of the functions in this section were taken from MIST, and reworked to OO concepts. + -- In order to keep the credibility of the the author, + -- I want to emphasize that the formulas embedded in the MIST framework were created by Grimes or previous authors, + -- who you can find on the Eagle Dynamics Forums. + -- + -- + -- ## POINT_VEC3 constructor + -- + -- A new POINT_VEC3 object can be created with: + -- + -- * @{#POINT_VEC3.New}(): a 3D point. + -- * @{#POINT_VEC3.NewFromVec3}(): a 3D point created from a @{DCSTypes#Vec3}. + -- + -- + -- ## Manupulate the X, Y, Z coordinates of the POINT_VEC3 + -- + -- A POINT_VEC3 class works in 3D space. It contains internally an X, Y, Z coordinate. + -- Methods exist to manupulate these coordinates. + -- + -- The current X, Y, Z axis can be retrieved with the methods @{#POINT_VEC3.GetX}(), @{#POINT_VEC3.GetY}(), @{#POINT_VEC3.GetZ}() respectively. + -- The methods @{#POINT_VEC3.SetX}(), @{#POINT_VEC3.SetY}(), @{#POINT_VEC3.SetZ}() change the respective axis with a new value. + -- The current axis values can be changed by using the methods @{#POINT_VEC3.AddX}(), @{#POINT_VEC3.AddY}(), @{#POINT_VEC3.AddZ}() + -- to add or substract a value from the current respective axis value. + -- Note that the Set and Add methods return the current POINT_VEC3 object, so these manipulation methods can be chained... For example: + -- + -- local Vec3 = PointVec3:AddX( 100 ):AddZ( 150 ):GetVec3() + -- + -- + -- ## 3D calculation methods + -- + -- Various calculation methods exist to use or manipulate 3D space. Find below a short description of each method: + -- + -- + -- ## Point Randomization + -- + -- Various methods exist to calculate random locations around a given 3D point. + -- + -- * @{#POINT_VEC3.GetRandomPointVec3InRadius}(): Provides a random 3D point around the current 3D point, in the given inner to outer band. + -- + -- + -- @field #POINT_VEC3 + POINT_VEC3 = { + ClassName = "POINT_VEC3", + Metric = true, + RoutePointAltType = { + BARO = "BARO", + }, + RoutePointType = { + TakeOffParking = "TakeOffParking", + TurningPoint = "Turning Point", + }, + RoutePointAction = { + FromParkingArea = "From Parking Area", + TurningPoint = "Turning Point", + }, + } + --- RoutePoint AltTypes -- @type POINT_VEC3.RoutePointAltType -- @field BARO "BARO" @@ -916,7 +919,7 @@ do -- POINT_VEC3 local self = BASE:Inherit( self, COORDINATE:New( x, y, z ) ) -- Core.Point#POINT_VEC3 self:F2( self ) - + return self end @@ -942,7 +945,7 @@ do -- POINT_VEC3 local self = BASE:Inherit( self, COORDINATE:NewFromVec3( Vec3 ) ) -- Core.Point#POINT_VEC3 self:F2( self ) - + return self end @@ -1023,20 +1026,6 @@ do -- POINT_VEC3 return self end - --- Return a random Vec3 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC3. - -- @param #POINT_VEC3 self - -- @param Dcs.DCSTypes#Distance OuterRadius - -- @param Dcs.DCSTypes#Distance InnerRadius - -- @return Dcs.DCSTypes#Vec3 Vec3 - function POINT_VEC3:GetRandomVec3InRadius( OuterRadius, InnerRadius ) - - local RandomVec2 = self:GetRandomVec2InRadius( OuterRadius, InnerRadius ) - local y = self:GetY() + math.random( InnerRadius, OuterRadius ) - local RandomVec3 = { x = RandomVec2.x, y = y, z = RandomVec2.y } - - return RandomVec3 - end - --- Return a random POINT_VEC3 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC3. -- @param #POINT_VEC3 self -- @param Dcs.DCSTypes#Distance OuterRadius @@ -1051,6 +1040,41 @@ end do -- POINT_VEC2 + --- @type POINT_VEC2 + -- @field Dcs.DCSTypes#Distance x The x coordinate in meters. + -- @field Dcs.DCSTypes#Distance y the y coordinate in meters. + -- @extends Core.Point#COORDINATE + + --- # POINT_VEC2 class, extends @{Point#COORDINATE} + -- + -- The @{Point#POINT_VEC2} class defines a 2D point in the simulator. The height coordinate (if needed) will be the land height + an optional added height specified. + -- + -- ## POINT_VEC2 constructor + -- + -- A new POINT_VEC2 instance can be created with: + -- + -- * @{Point#POINT_VEC2.New}(): a 2D point, taking an additional height parameter. + -- * @{Point#POINT_VEC2.NewFromVec2}(): a 2D point created from a @{DCSTypes#Vec2}. + -- + -- ## Manupulate the X, Altitude, Y coordinates of the 2D point + -- + -- A POINT_VEC2 class works in 2D space, with an altitude setting. It contains internally an X, Altitude, Y coordinate. + -- Methods exist to manupulate these coordinates. + -- + -- The current X, Altitude, Y axis can be retrieved with the methods @{#POINT_VEC2.GetX}(), @{#POINT_VEC2.GetAlt}(), @{#POINT_VEC2.GetY}() respectively. + -- The methods @{#POINT_VEC2.SetX}(), @{#POINT_VEC2.SetAlt}(), @{#POINT_VEC2.SetY}() change the respective axis with a new value. + -- The current Lat(itude), Alt(itude), Lon(gitude) values can also be retrieved with the methods @{#POINT_VEC2.GetLat}(), @{#POINT_VEC2.GetAlt}(), @{#POINT_VEC2.GetLon}() respectively. + -- The current axis values can be changed by using the methods @{#POINT_VEC2.AddX}(), @{#POINT_VEC2.AddAlt}(), @{#POINT_VEC2.AddY}() + -- to add or substract a value from the current respective axis value. + -- Note that the Set and Add methods return the current POINT_VEC2 object, so these manipulation methods can be chained... For example: + -- + -- local Vec2 = PointVec2:AddX( 100 ):AddY( 2000 ):GetVec2() + -- + -- @field #POINT_VEC2 + POINT_VEC2 = { + ClassName = "POINT_VEC2", + } + --- POINT_VEC2 constructor. @@ -1083,7 +1107,7 @@ do -- POINT_VEC2 LandHeightAdd = LandHeightAdd or 0 LandHeight = LandHeight + LandHeightAdd - local self = BASE:Inherit( self, COORDINATE:New( Vec2.x, LandHeight, Vec2.y ) ) -- Core.Point#POINT_VEC2 + local self = BASE:Inherit( self, COORDINATE:NewFromVec2( Vec2, LandHeightAdd ) ) -- Core.Point#POINT_VEC2 self:F2( self ) return self @@ -1210,36 +1234,6 @@ do -- POINT_VEC2 return self end - --- Return a random Vec2 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC2. - -- @param #POINT_VEC2 self - -- @param Dcs.DCSTypes#Distance OuterRadius - -- @param Dcs.DCSTypes#Distance InnerRadius - -- @return Dcs.DCSTypes#Vec2 Vec2 - function POINT_VEC2:GetRandomVec2InRadius( OuterRadius, InnerRadius ) - self:F2( { OuterRadius, InnerRadius } ) - - local Theta = 2 * math.pi * math.random() - local Radials = math.random() + math.random() - if Radials > 1 then - Radials = 2 - Radials - end - - local RadialMultiplier - if InnerRadius and InnerRadius <= OuterRadius then - RadialMultiplier = ( OuterRadius - InnerRadius ) * Radials + InnerRadius - else - RadialMultiplier = OuterRadius * Radials - end - - local RandomVec2 - if OuterRadius > 0 then - RandomVec2 = { x = math.cos( Theta ) * RadialMultiplier + self:GetX(), y = math.sin( Theta ) * RadialMultiplier + self:GetZ() } - else - RandomVec2 = { x = self:GetX(), y = self:GetZ() } - end - - return RandomVec2 - end --- Return a random POINT_VEC2 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC2. -- @param #POINT_VEC2 self @@ -1252,8 +1246,7 @@ do -- POINT_VEC2 return POINT_VEC2:NewFromVec2( self:GetRandomVec2InRadius( OuterRadius, InnerRadius ) ) end - --- TODO: Check this to replace + -- TODO: Check this to replace --- Calculate the distance from a reference @{#POINT_VEC2}. -- @param #POINT_VEC2 self -- @param #POINT_VEC2 PointVec2Reference The reference @{#POINT_VEC2}. @@ -1261,43 +1254,12 @@ do -- POINT_VEC2 function POINT_VEC2:DistanceFromPointVec2( PointVec2Reference ) self:F2( PointVec2Reference ) - local Distance = ( ( PointVec2Reference:GetX() - self:GetX() ) ^ 2 + ( PointVec2Reference:GetY() - self:GetY() ) ^2 ) ^0.5 + local Distance = ( ( PointVec2Reference.x - self.x ) ^ 2 + ( PointVec2Reference.z - self.z ) ^2 ) ^ 0.5 self:T2( Distance ) return Distance end ---TODO: check this to replace - - --- Calculate the distance from a reference @{DCSTypes#Vec2}. - -- @param #POINT_VEC2 self - -- @param Dcs.DCSTypes#Vec2 Vec2Reference The reference @{DCSTypes#Vec2}. - -- @return Dcs.DCSTypes#Distance The distance from the reference @{DCSTypes#Vec2} in meters. - function POINT_VEC2:DistanceFromVec2( Vec2Reference ) - self:F2( Vec2Reference ) - - local Distance = ( ( Vec2Reference.x - self:GetX() ) ^ 2 + ( Vec2Reference.y - self:GetY() ) ^2 ) ^0.5 - - self:T2( Distance ) - return Distance - end - - - --- Add a Distance in meters from the POINT_VEC2 orthonormal plane, with the given angle, and calculate the new POINT_VEC2. - -- @param #POINT_VEC2 self - -- @param Dcs.DCSTypes#Distance Distance The Distance to be added in meters. - -- @param Dcs.DCSTypes#Angle Angle The Angle in degrees. - -- @return #POINT_VEC2 The new calculated POINT_VEC2. - function POINT_VEC2:Translate( Distance, Angle ) - local SX = self:GetX() - local SY = self:GetY() - local Radians = Angle / 180 * math.pi - local TX = Distance * math.cos( Radians ) + SX - local TY = Distance * math.sin( Radians ) + SY - - return POINT_VEC2:New( TX, TY ) - end - end diff --git a/Moose Development/Moose/Core/Radio.lua b/Moose Development/Moose/Core/Radio.lua index 540c57fc9..bc6a8dd01 100644 --- a/Moose Development/Moose/Core/Radio.lua +++ b/Moose Development/Moose/Core/Radio.lua @@ -79,7 +79,7 @@ -- @field #string Subtitle Subtitle of the transmission -- @field #number SubtitleDuration Duration of the Subtitle in seconds -- @field #number Power Power of the antenna is Watts --- @field #boolean Loop +-- @field #boolean Loop (default true) -- @extends Core.Base#BASE RADIO = { ClassName = "RADIO", @@ -89,7 +89,7 @@ RADIO = { Subtitle = "", SubtitleDuration = 0, Power = 100, - Loop = 0, + Loop = true, } --- Create a new RADIO Object. This doesn't broadcast a transmission, though, use @{#RADIO.Broadcast} to actually broadcast @@ -101,6 +101,7 @@ RADIO = { function RADIO:New(Positionable) local self = BASE:Inherit( self, BASE:New() ) -- Core.Radio#RADIO + self.Loop = true -- default Loop to true (not sure the above RADIO definition actually is working) self:F(Positionable) if Positionable:GetPointVec2() then -- It's stupid, but the only way I found to make sure positionable is valid @@ -296,6 +297,7 @@ end -- @return #RADIO self function RADIO:Broadcast() self:F() + -- If the POSITIONABLE is actually a UNIT or a GROUP, use the more complicated DCS command system if self.Positionable.ClassName == "UNIT" or self.Positionable.ClassName == "GROUP" then self:T2("Broadcasting from a UNIT or a GROUP") diff --git a/Moose Development/Moose/Functional/Detection.lua b/Moose Development/Moose/Functional/Detection.lua index 9d58528fe..8ece18ed5 100644 --- a/Moose Development/Moose/Functional/Detection.lua +++ b/Moose Development/Moose/Functional/Detection.lua @@ -512,7 +512,7 @@ do -- DETECTION_BASE -- @param #string Event The Event string. -- @param #string To The To State string. function DETECTION_BASE:onafterDetect(From,Event,To) - self:E( {From,Event,To}) + self:E( { From, Event, To } ) local DetectDelay = 0.1 self.DetectionCount = 0 @@ -520,7 +520,7 @@ do -- DETECTION_BASE self:UnIdentifyAllDetectedObjects() -- Resets the DetectedObjectsIdentified table for DetectionGroupID, DetectionGroupData in pairs( self.DetectionSetGroup:GetSet() ) do - self:E( {DetectionGroupData}) + --self:E( { DetectionGroupData } ) self:__DetectionGroup( DetectDelay, DetectionGroupData ) -- Process each detection asynchronously. self.DetectionCount = self.DetectionCount + 1 DetectDelay = DetectDelay + 0.1 @@ -533,7 +533,7 @@ do -- DETECTION_BASE -- @param #string To The To State string. -- @param Wrapper.Group#GROUP DetectionGroup The Group detecting. function DETECTION_BASE:onafterDetectionGroup( From, Event, To, DetectionGroup ) - self:E( {From,Event,To}) + self:E( { From, Event, To } ) self.DetectionRun = self.DetectionRun + 1 @@ -1563,7 +1563,7 @@ do -- DETECTION_UNITS local DetectedUnit = DetectedUnitData -- Wrapper.Unit#UNIT local DetectedObject = nil - self:E( DetectedUnit ) + --self:E( DetectedUnit ) if DetectedUnit:IsAlive() then --self:E(DetectedUnit:GetName()) DetectedObject = self:GetDetectedObject( DetectedUnit:GetName() ) @@ -1924,8 +1924,8 @@ do -- DETECTION_TYPES local DetectedItemCoordinate = DetectedItemUnit:GetCoordinate() local DetectedItemCoordText = DetectedItemCoordinate:ToString( AttackGroup ) - self:E( { DetectedItemID, - DetectedItemCoordText } ) + --self:E( { DetectedItemID, + -- DetectedItemCoordText } ) local ReportSummary = string.format( "%s - %s", @@ -2365,7 +2365,7 @@ do -- DETECTION_AREAS self:IdentifyDetectedObject( DetectedObject ) AreaExists = true - DetectedItem.Zone:BoundZone( 12, self.CountryID, true) + --DetectedItem.Zone:BoundZone( 12, self.CountryID, true) -- Assign the Unit as the new center unit of the detected area. DetectedItem.Zone = ZONE_UNIT:New( DetectedUnit:GetName(), DetectedUnit, self.DetectionZoneRange ) @@ -2374,6 +2374,9 @@ do -- DETECTION_AREAS -- We don't need to add the DetectedObject to the area set, because it is already there ... break + else + DetectedSet:Remove( DetectedUnitName ) + self:AddChangeUnit( DetectedItem, "RU", DetectedUnit:GetTypeName() ) end end end @@ -2418,13 +2421,15 @@ do -- DETECTION_AREAS end end else - DetectedItem.Zone:BoundZone( 12, self.CountryID, true) + --DetectedItem.Zone:BoundZone( 12, self.CountryID, true) self:RemoveDetectedItem( DetectedItemID ) self:AddChangeItem( DetectedItem, "RA" ) end end end + + -- We iterated through the existing detection areas and: -- - We checked which units are still detected in each detection area. Those units were flagged as Identified. -- - We recentered the detection area to new center units where it was needed. @@ -2488,11 +2493,14 @@ do -- DETECTION_AREAS if DETECTION_AREAS._SmokeDetectedUnits or self._SmokeDetectedUnits then DetectedZone.ZoneUNIT:SmokeRed() end + + --DetectedSet:Flush() + DetectedSet:ForEachUnit( --- @param Wrapper.Unit#UNIT DetectedUnit function( DetectedUnit ) if DetectedUnit:IsAlive() then - self:T( "Detected Set #" .. DetectedItem.ItemID .. ":" .. DetectedUnit:GetName() ) + --self:T( "Detected Set #" .. DetectedItem.ItemID .. ":" .. DetectedUnit:GetName() ) if DETECTION_AREAS._FlareDetectedUnits or self._FlareDetectedUnits then DetectedUnit:FlareGreen() end diff --git a/Moose Development/Moose/Tasking/Task_A2A.lua b/Moose Development/Moose/Tasking/Task_A2A.lua index c5cb49ebd..aa9092ab1 100644 --- a/Moose Development/Moose/Tasking/Task_A2A.lua +++ b/Moose Development/Moose/Tasking/Task_A2A.lua @@ -243,8 +243,6 @@ do -- TASK_A2A -- @param Wrapper.Unit#UNIT TaskUnit function TASK_A2A:SetTargetCoordinate( TargetCoordinate, TaskUnit ) - TargetCoordinate:SetModeA2A() - local ProcessUnit = self:GetUnitProcess( TaskUnit ) local ActRouteTarget = ProcessUnit:GetProcess( "Engaging", "RouteToTargetPoint" ) -- Actions.Act_Route#ACT_ROUTE_POINT @@ -373,7 +371,6 @@ do -- TASK_A2A_INTERCEPT ) local TargetCoordinate = TargetSetUnit:GetFirst():GetCoordinate() - TargetCoordinate:SetModeA2A() self:SetInfo( "Coordinates", TargetCoordinate ) self:SetInfo( "ThreatLevel", "[" .. string.rep( "■", TargetSetUnit:CalculateThreatLevelA2G() ) .. "]" ) @@ -421,7 +418,6 @@ do -- TASK_A2A_ENGAGE ) local TargetCoordinate = TargetSetUnit:GetFirst():GetCoordinate() - TargetCoordinate:SetModeA2A() self:SetInfo( "Coordinates", TargetCoordinate ) self:SetInfo( "ThreatLevel", "[" .. string.rep( "■", TargetSetUnit:CalculateThreatLevelA2G() ) .. "]" ) diff --git a/Moose Development/Moose/Tasking/Task_A2A_Dispatcher.lua b/Moose Development/Moose/Tasking/Task_A2A_Dispatcher.lua index 865189a69..ca0f56050 100644 --- a/Moose Development/Moose/Tasking/Task_A2A_Dispatcher.lua +++ b/Moose Development/Moose/Tasking/Task_A2A_Dispatcher.lua @@ -157,7 +157,7 @@ do -- TASK_A2A_DISPATCHER -- @param #boolean DetectedItemID -- @param #boolean DetectedItemChange -- @return Tasking.Task#TASK - function TASK_A2A_DISPATCHER:EvaluateRemoveTask( Mission, Task, Detection, DetectedItem, DetectedItemID, DetectedItemChanged ) + function TASK_A2A_DISPATCHER:EvaluateRemoveTask( Mission, Task, Detection, DetectedItem, DetectedItemIndex, DetectedItemChanged ) if Task then @@ -165,7 +165,7 @@ do -- TASK_A2A_DISPATCHER local TaskName = Task:GetName() local TaskType = TaskName:match( "(%u+)%.%d+" ) - self:E( { TaskType = TaskType } ) + self:T2( { TaskType = TaskType } ) local Remove = false @@ -181,11 +181,18 @@ do -- TASK_A2A_DISPATCHER Remove = true end end + + local DetectedSet = DetectedItem.Set -- Core.Set#SET_UNIT + --DetectedSet:Flush() + --self:E( { DetectedSetCount = DetectedSet:Count() } ) + if DetectedSet:Count() == 0 then + Remove = true + end if DetectedItemChanged == true or Remove then - self:E( "Removing Tasking: " .. Task:GetTaskName() ) + --self:E( "Removing Tasking: " .. Task:GetTaskName() ) Mission:RemoveTask( Task ) - self.Tasks[DetectedItemID] = nil + self.Tasks[DetectedItemIndex] = nil end end end @@ -221,7 +228,7 @@ do -- TASK_A2A_DISPATCHER end - self:E( { FriendliesCount = FriendliesCount } ) + --self:E( { FriendliesCount = FriendliesCount } ) local FriendlyTypesReport = REPORT:New() @@ -254,7 +261,7 @@ do -- TASK_A2A_DISPATCHER for PlayerUnitName, PlayerUnitData in pairs( PlayersNearBy ) do local PlayerUnit = PlayerUnitData -- Wrapper.Unit#UNIT local PlayerName = PlayerUnit:GetPlayerName() - self:E( { PlayerName = PlayerName, PlayerUnit = PlayerUnit } ) + --self:E( { PlayerName = PlayerName, PlayerUnit = PlayerUnit } ) if PlayerUnit:IsAirPlane() and PlayerName ~= nil then local FriendlyUnitThreatLevel = PlayerUnit:GetThreatLevel() PlayersCount = PlayersCount + 1 @@ -267,7 +274,7 @@ do -- TASK_A2A_DISPATCHER end - self:E( { PlayersCount = PlayersCount } ) + --self:E( { PlayersCount = PlayersCount } ) local PlayerTypesReport = REPORT:New() @@ -300,25 +307,42 @@ do -- TASK_A2A_DISPATCHER if Mission:IsIDLE() or Mission:IsENGAGED() then local TaskReport = REPORT:New() + + -- Checking the task queue for the dispatcher, and removing any obsolete task! + for TaskIndex, TaskData in pairs( self.Tasks ) do + local Task = TaskData -- Tasking.Task#TASK + if Task:IsStatePlanned() then + local DetectedItem = Detection:GetDetectedItem( TaskIndex ) + if not DetectedItem then + local TaskText = Task:GetName() + for TaskGroupID, TaskGroup in pairs( self.SetGroup:GetSet() ) do + Mission:GetCommandCenter():MessageToGroup( string.format( "Obsolete A2A task %s for %s removed.", TaskText, Mission:GetName() ), TaskGroup ) + end + Mission:RemoveTask( Task ) + self.Tasks[TaskIndex] = nil + end + end + end - --- First we need to the detected targets. + -- Now that all obsolete tasks are removed, loop through the detected targets. for DetectedItemID, DetectedItem in pairs( Detection:GetDetectedItems() ) do local DetectedItem = DetectedItem -- Functional.Detection#DETECTION_BASE.DetectedItem local DetectedSet = DetectedItem.Set -- Core.Set#SET_UNIT + local DetectedCount = DetectedSet:Count() local DetectedZone = DetectedItem.Zone - self:E( { "Targets in DetectedItem", DetectedItem.ItemID, DetectedSet:Count(), tostring( DetectedItem ) } ) - DetectedSet:Flush() + --self:E( { "Targets in DetectedItem", DetectedItem.ItemID, DetectedSet:Count(), tostring( DetectedItem ) } ) + --DetectedSet:Flush() local DetectedID = DetectedItem.ID - local DetectedIndex = DetectedItem.Index + local TaskIndex = DetectedItem.Index local DetectedItemChanged = DetectedItem.Changed - local Task = self.Tasks[DetectedID] - Task = self:EvaluateRemoveTask( Mission, Task, Detection, DetectedItem, DetectedID, DetectedItemChanged ) -- Task will be removed if it is planned and changed. + local Task = self.Tasks[TaskIndex] + Task = self:EvaluateRemoveTask( Mission, Task, Detection, DetectedItem, TaskIndex, DetectedItemChanged ) -- Task will be removed if it is planned and changed. -- Evaluate INTERCEPT - if not Task then + if not Task and DetectedCount > 0 then local TargetSetUnit = self:EvaluateENGAGE( DetectedItem ) -- Returns a SetUnit if there are targets to be INTERCEPTed... if TargetSetUnit then Task = TASK_A2A_ENGAGE:New( Mission, self.SetGroup, string.format( "ENGAGE.%03d", DetectedID ), TargetSetUnit ) @@ -330,7 +354,7 @@ do -- TASK_A2A_DISPATCHER end if Task then - self.Tasks[DetectedID] = Task + self.Tasks[TaskIndex] = Task Task:SetTargetZone( DetectedZone, DetectedSet:GetFirst():GetAltitude(), DetectedSet:GetFirst():GetHeading() ) Task:SetDispatcher( self ) Mission:AddTask( Task ) @@ -342,11 +366,12 @@ do -- TASK_A2A_DISPATCHER end - local FriendliesCount, FriendliesReport = self:GetFriendliesNearBy( DetectedItem ) - Task:SetInfo( "Friendlies", string.format( "%d ( %s )", FriendliesCount, FriendliesReport:Text( "," ) ) ) - - local PlayersCount, PlayersReport = self:GetPlayerFriendliesNearBy( DetectedItem ) - Task:SetInfo( "Players", string.format( "%d ( %s )", PlayersCount, PlayersReport:Text( "," ) ) ) + if Task then + local FriendliesCount, FriendliesReport = self:GetFriendliesNearBy( DetectedItem ) + Task:SetInfo( "Friendlies", string.format( "%d ( %s )", FriendliesCount, FriendliesReport:Text( "," ) ) ) + local PlayersCount, PlayersReport = self:GetPlayerFriendliesNearBy( DetectedItem ) + Task:SetInfo( "Players", string.format( "%d ( %s )", PlayersCount, PlayersReport:Text( "," ) ) ) + end -- OK, so the tasking has been done, now delete the changes reported for the area. Detection:AcceptChanges( DetectedItem ) diff --git a/Moose Development/Moose/Tasking/Task_A2G.lua b/Moose Development/Moose/Tasking/Task_A2G.lua index 56c43d091..9ad9ca03e 100644 --- a/Moose Development/Moose/Tasking/Task_A2G.lua +++ b/Moose Development/Moose/Tasking/Task_A2G.lua @@ -381,7 +381,6 @@ do -- TASK_SEAD ) local TargetCoordinate = TargetSetUnit:GetFirst():GetCoordinate() - TargetCoordinate:SetModeA2G() self:SetInfo( "Coordinates", TargetCoordinate ) self:SetInfo( "ThreatLevel", "[" .. string.rep( "■", TargetSetUnit:CalculateThreatLevelA2G() ) .. "]" ) @@ -424,7 +423,6 @@ do -- TASK_BAI ) local TargetCoordinate = TargetSetUnit:GetFirst():GetCoordinate() - TargetCoordinate:SetModeA2G() self:SetInfo( "Coordinates", TargetCoordinate ) self:SetInfo( "ThreatLevel", "[" .. string.rep( "■", TargetSetUnit:CalculateThreatLevelA2G() ) .. "]" ) @@ -468,7 +466,6 @@ do -- TASK_CAS ) local TargetCoordinate = TargetSetUnit:GetFirst():GetCoordinate() - TargetCoordinate:SetModeA2G() self:SetInfo( "Coordinates", TargetCoordinate ) self:SetInfo( "ThreatLevel", "[" .. string.rep( "■", TargetSetUnit:CalculateThreatLevelA2G() ) .. "]" ) diff --git a/Moose Development/Moose/Tasking/Task_A2G_Dispatcher.lua b/Moose Development/Moose/Tasking/Task_A2G_Dispatcher.lua index 4d77cee7b..488c7a256 100644 --- a/Moose Development/Moose/Tasking/Task_A2G_Dispatcher.lua +++ b/Moose Development/Moose/Tasking/Task_A2G_Dispatcher.lua @@ -185,13 +185,13 @@ do -- TASK_A2G_DISPATCHER -- @param #boolean DetectedItemID -- @param #boolean DetectedItemChange -- @return Tasking.Task#TASK - function TASK_A2G_DISPATCHER:EvaluateRemoveTask( Mission, Task, DetectedItemID, DetectedItemChanged ) + function TASK_A2G_DISPATCHER:EvaluateRemoveTask( Mission, Task, TaskIndex, DetectedItemChanged ) if Task then if Task:IsStatePlanned() and DetectedItemChanged == true then self:E( "Removing Tasking: " .. Task:GetTaskName() ) Mission:RemoveTask( Task ) - self.Tasks[DetectedItemID] = nil + self.Tasks[TaskIndex] = nil end end @@ -216,6 +216,22 @@ do -- TASK_A2G_DISPATCHER local TaskReport = REPORT:New() + -- Checking the task queue for the dispatcher, and removing any obsolete task! + for TaskIndex, TaskData in pairs( self.Tasks ) do + local Task = TaskData -- Tasking.Task#TASK + if Task:IsStatePlanned() then + local DetectedItem = Detection:GetDetectedItem( TaskIndex ) + if not DetectedItem then + local TaskText = Task:GetName() + for TaskGroupID, TaskGroup in pairs( self.SetGroup:GetSet() ) do + Mission:GetCommandCenter():MessageToGroup( string.format( "Obsolete A2G task %s for %s removed.", TaskText, Mission:GetName() ), TaskGroup ) + end + Mission:RemoveTask( Task ) + self.Tasks[TaskIndex] = nil + end + end + end + --- First we need to the detected targets. for DetectedItemID, DetectedItem in pairs( Detection:GetDetectedItems() ) do @@ -226,11 +242,11 @@ do -- TASK_A2G_DISPATCHER DetectedSet:Flush() local DetectedItemID = DetectedItem.ID - local DetectedItemIndex = DetectedItem.Index + local TaskIndex = DetectedItem.Index local DetectedItemChanged = DetectedItem.Changed - local Task = self.Tasks[DetectedItemID] - Task = self:EvaluateRemoveTask( Mission, Task, DetectedItemID, DetectedItemChanged ) -- Task will be removed if it is planned and changed. + local Task = self.Tasks[TaskIndex] + Task = self:EvaluateRemoveTask( Mission, Task, TaskIndex, DetectedItemChanged ) -- Task will be removed if it is planned and changed. -- Evaluate SEAD if not Task then @@ -256,11 +272,11 @@ do -- TASK_A2G_DISPATCHER end if Task then - self.Tasks[DetectedItemID] = Task + self.Tasks[TaskIndex] = Task Task:SetTargetZone( DetectedZone ) Task:SetDispatcher( self ) Task:SetInfo( "ThreatLevel", DetectedSet:CalculateThreatLevelA2G() ) - Task:SetInfo( "Detection", Detection:DetectedItemReportSummary( DetectedItemIndex ) ) + Task:SetInfo( "Detection", Detection:DetectedItemReportSummary( TaskIndex ) ) Task:SetInfo( "Changes", Detection:GetChangeText( DetectedItem ) ) Mission:AddTask( Task ) else diff --git a/Moose Development/Moose/Tasking/Task_CARGO.lua b/Moose Development/Moose/Tasking/Task_CARGO.lua index 22a331949..86263764e 100644 --- a/Moose Development/Moose/Tasking/Task_CARGO.lua +++ b/Moose Development/Moose/Tasking/Task_CARGO.lua @@ -174,6 +174,7 @@ do -- TASK_CARGO self.SetCargo = SetCargo self.TaskType = TaskType + self.SmokeColor = SMOKECOLOR.Red self.DeployZones = {} -- setmetatable( {}, { __mode = "v" } ) -- weak table on value @@ -327,6 +328,13 @@ do -- TASK_CARGO self:__RouteToDeploy( 1.0, DeployZone ) end + + + --- + --#TASK_CAROG_TRANSPORT self + --#Wrapper.Unit#UNIT + + --- Route to Cargo -- @param #FSM_PROCESS self -- @param Wrapper.Unit#UNIT TaskUnit @@ -347,16 +355,16 @@ do -- TASK_CARGO end + --- -- @param #FSM_PROCESS self -- @param Wrapper.Unit#UNIT TaskUnit -- @param Tasking.Task_Cargo#TASK_CARGO Task function Fsm:onafterArriveAtPickup( TaskUnit, Task ) self:E( { TaskUnit = TaskUnit, Task = Task and Task:GetClassNameAndID() } ) - if self.Cargo:IsAlive() then + TaskUnit:Smoke( Task:GetSmokeColor(), 15 ) if TaskUnit:IsAir() then - self.Cargo.CargoObject:GetUnit(1):SmokeRed() self:__Land( -0.1, "Pickup" ) else self:__SelectAction( -0.1 ) @@ -606,6 +614,26 @@ do -- TASK_CARGO end + + ---@param Color Might be SMOKECOLOR.Blue, SMOKECOLOR.Red SMOKECOLOR.Orange, SMOKECOLOR.White or SMOKECOLOR.Green + function TASK_CARGO:SetSmokeColor(SmokeColor) + -- Makes sure Coloe is set + if SmokeColor == nil then + self.SmokeColor = SMOKECOLOR.Red -- Make sure a default color is exist + + elseif type(SmokeColor) == "number" then + self:F2(SmokeColor) + if SmokeColor > 0 and SmokeColor <=5 then -- Make sure number is within ragne, assuming first enum is one + self.SmokeColor = SMOKECOLOR.SmokeColor + end + end + end + + --@return SmokeColor + function TASK_CARGO:GetSmokeColor() + return self.SmokeColor + end + --- @param #TASK_CARGO self function TASK_CARGO:GetPlannedMenuText() return self:GetStateString() .. " - " .. self:GetTaskName() .. " ( " .. self.TargetSetUnit:GetUnitTypesText() .. " )" @@ -911,6 +939,11 @@ do -- TASK_CARGO_TRANSPORT return CargoDeployed end + + --- + + + end diff --git a/Utils/Slate Documentation Generator/bin/TreeHierarchy.csv b/Utils/Slate Documentation Generator/bin/TreeHierarchy.csv index 94fc57631..c5a17961d 100644 --- a/Utils/Slate Documentation Generator/bin/TreeHierarchy.csv +++ b/Utils/Slate Documentation Generator/bin/TreeHierarchy.csv @@ -1,35 +1,41 @@ +@K=function, @M=Task_A2A, @N=onafterRouteToRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=4756, +@K=function, @M=Task_A2A, @N=OnAfterArriveAtRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=5417, +@K=function, @M=Task_A2A, @N=onafterEngage, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=5814, +@K=function, @M=Task_A2A, @N=onafterRouteToTarget, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=6136, +@K=function, @M=Task_A2A, @N=onafterRouteToTargets, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2A.lua, @C=7017, @K=function, @M=Task_A2G, @N=onafterRouteToRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=5157, -@K=function, @M=Task_A2G, @N=OnAfterArriveAtRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=5817, -@K=function, @M=Task_A2G, @N=onafterEngage, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=6214, -@K=function, @M=Task_A2G, @N=onafterRouteToTarget, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=6536, -@K=function, @M=Task_A2G, @N=onafterRouteToTargets, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=7408, -@K=function, @M=Task_Cargo, @N=onafterSelectAction, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=10439, -@K=function, @M=Task_Cargo, @N=OnLeaveWaitingForCommand, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=13084, -@K=function, @M=Task_Cargo, @N=onafterRouteToPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=13860, -@K=function, @M=Task_Cargo, @N=onafterArriveAtPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=14479, -@K=function, @M=Task_Cargo, @N=onafterRouteToDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15020, -@K=function, @M=Task_Cargo, @N=onafterArriveAtDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15467, -@K=function, @M=Task_Cargo, @N=onafterLand, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15897, -@K=function, @M=Task_Cargo, @N=onafterLanded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=16856, -@K=function, @M=Task_Cargo, @N=onafterPrepareBoarding, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=17622, -@K=function, @M=Task_Cargo, @N=onafterBoard, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=18082, -@K=function, @M=Task_Cargo, @N=onafterBoarded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=19023, -@K=function, @M=Task_Cargo, @N=onafterPrepareUnBoarding, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=19706, -@K=function, @M=Task_Cargo, @N=onafterUnBoard, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=20666, -@K=function, @M=Task_Cargo, @N=onafterUnBoarded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=21541, -@K=function, @M=Designate, @N=OnBeforeLaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12232, -@K=function, @M=Designate, @N=OnAfterLaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12480, -@K=function, @M=Designate, @N=LaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12701, -@K=function, @M=Designate, @N=__LaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12824, -@K=function, @M=Designate, @N=OnBeforeLaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13114, -@K=function, @M=Designate, @N=OnAfterLaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13364, -@K=function, @M=Designate, @N=LaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13587, -@K=function, @M=Designate, @N=__LaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13712, -@K=function, @M=Designate, @N=OnBeforeSmoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13944, -@K=function, @M=Designate, @N=OnAfterSmoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14190, -@K=function, @M=Designate, @N=Smoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14409, -@K=function, @M=Designate, @N=__Smoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14530, -@K=function, @M=Designate, @N=OnBeforeStatus, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=15628, -@K=function, @M=Designate, @N=OnAfterStatus, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=15876, -@K=function, @M=Designate, @N=Status, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=16097, -@K=function, @M=Designate, @N=__Status, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=16220, +@K=function, @M=Task_A2G, @N=OnAfterArriveAtRendezVous, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=5818, +@K=function, @M=Task_A2G, @N=onafterEngage, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=6215, +@K=function, @M=Task_A2G, @N=onafterRouteToTarget, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=6537, +@K=function, @M=Task_A2G, @N=onafterRouteToTargets, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_A2G.lua, @C=7416, +@K=function, @M=Task_Cargo, @N=onafterSelectAction, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=10673, +@K=function, @M=Task_Cargo, @N=OnLeaveWaitingForCommand, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=13702, +@K=function, @M=Task_Cargo, @N=onafterRouteToPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=14474, +@K=function, @M=Task_Cargo, @N=onafterArriveAtPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15093, +@K=function, @M=Task_Cargo, @N=onafterCancelRouteToPickup, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15634, +@K=function, @M=Task_Cargo, @N=onafterRouteToDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=15971, +@K=function, @M=Task_Cargo, @N=onafterArriveAtDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=16418, +@K=function, @M=Task_Cargo, @N=onafterCancelRouteToDeploy, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=16846, +@K=function, @M=Task_Cargo, @N=onafterLanded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=18133, +@K=function, @M=Task_Cargo, @N=onafterPrepareBoarding, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=18899, +@K=function, @M=Task_Cargo, @N=onafterBoard, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=19359, +@K=function, @M=Task_Cargo, @N=onafterBoarded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=20300, +@K=function, @M=Task_Cargo, @N=onafterPrepareUnBoarding, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=20983, +@K=function, @M=Task_Cargo, @N=onafterUnBoard, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=21943, +@K=function, @M=Task_Cargo, @N=onafterUnBoarded, @P=Fsm, @F=../../../MOOSE/Moose Development/Moose\Tasking\Task_CARGO.lua, @C=22962, +@K=function, @M=Designate, @N=OnBeforeLaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12218, +@K=function, @M=Designate, @N=OnAfterLaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12466, +@K=function, @M=Designate, @N=LaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12687, +@K=function, @M=Designate, @N=__LaseOn, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=12810, +@K=function, @M=Designate, @N=OnBeforeLaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13094, +@K=function, @M=Designate, @N=OnAfterLaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13344, +@K=function, @M=Designate, @N=LaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13567, +@K=function, @M=Designate, @N=__LaseOff, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13692, +@K=function, @M=Designate, @N=OnBeforeSmoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=13906, +@K=function, @M=Designate, @N=OnAfterSmoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14152, +@K=function, @M=Designate, @N=Smoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14371, +@K=function, @M=Designate, @N=__Smoke, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=14492, +@K=function, @M=Designate, @N=OnBeforeStatus, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=15578, +@K=function, @M=Designate, @N=OnAfterStatus, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=15826, +@K=function, @M=Designate, @N=Status, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=16047, +@K=function, @M=Designate, @N=__Status, @P=DESIGNATE , @F=../../../MOOSE/Moose Development/Moose\Functional\Designate.lua, @C=16170, diff --git a/docs/Documentation/AI_BAI.html b/docs/Documentation/AI_BAI.html index a778055c0..5c91e2d34 100644 --- a/docs/Documentation/AI_BAI.html +++ b/docs/Documentation/AI_BAI.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/AI_Balancer.html b/docs/Documentation/AI_Balancer.html index c33e7f6ec..79bfc515b 100644 --- a/docs/Documentation/AI_Balancer.html +++ b/docs/Documentation/AI_Balancer.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/AI_Cap.html b/docs/Documentation/AI_Cap.html index 50a719558..8536cb291 100644 --- a/docs/Documentation/AI_Cap.html +++ b/docs/Documentation/AI_Cap.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/AI_Cas.html b/docs/Documentation/AI_Cas.html index d8c87f024..677dbe72c 100644 --- a/docs/Documentation/AI_Cas.html +++ b/docs/Documentation/AI_Cas.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/AI_Formation.html b/docs/Documentation/AI_Formation.html index 2809b48df..f80dc8eab 100644 --- a/docs/Documentation/AI_Formation.html +++ b/docs/Documentation/AI_Formation.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/AI_Patrol.html b/docs/Documentation/AI_Patrol.html index a349f1b11..72b9c5689 100644 --- a/docs/Documentation/AI_Patrol.html +++ b/docs/Documentation/AI_Patrol.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -953,6 +956,9 @@ Use the method AIPATROLZONE.M + +

    This table contains the targets detected during patrol.

    +
    diff --git a/docs/Documentation/Account.html b/docs/Documentation/Account.html index 5609f0458..4b5401289 100644 --- a/docs/Documentation/Account.html +++ b/docs/Documentation/Account.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Airbase.html b/docs/Documentation/Airbase.html index dd2f0550d..4607bb108 100644 --- a/docs/Documentation/Airbase.html +++ b/docs/Documentation/Airbase.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/AirbasePolice.html b/docs/Documentation/AirbasePolice.html index 9e5241f98..cb727ef32 100644 --- a/docs/Documentation/AirbasePolice.html +++ b/docs/Documentation/AirbasePolice.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Assign.html b/docs/Documentation/Assign.html index 24c1ac926..d02174fb7 100644 --- a/docs/Documentation/Assign.html +++ b/docs/Documentation/Assign.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Base.html b/docs/Documentation/Base.html index 13e421b67..f64ed2f97 100644 --- a/docs/Documentation/Base.html +++ b/docs/Documentation/Base.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -263,7 +266,7 @@ YYYY-MM-DD: CLASS:NewFunction( Params ) added

    - BASE:GetState(Object, Key, Value) + BASE:GetState(Object, Key)

    Get a Value given a Key from the Object.

    @@ -1152,7 +1155,7 @@ is the Child class from which the Parent class needs to be retrieved.

    -BASE:GetState(Object, Key, Value) +BASE:GetState(Object, Key)
    @@ -1175,12 +1178,6 @@ The object that holds the Value set by the Key.

    Key : The key that is used to retrieve the value. Note that the key can be a #string, but it can also be any other type!

    - -
  • - -

    Value : -The value to is stored in the Object.

    -
  • Return value

    diff --git a/docs/Documentation/Cargo.html b/docs/Documentation/Cargo.html index 8b2fbef53..875f99a43 100644 --- a/docs/Documentation/Cargo.html +++ b/docs/Documentation/Cargo.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/CleanUp.html b/docs/Documentation/CleanUp.html index fd65272a9..489617a1e 100644 --- a/docs/Documentation/CleanUp.html +++ b/docs/Documentation/CleanUp.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Client.html b/docs/Documentation/Client.html index bb434479a..27e7e6a3a 100644 --- a/docs/Documentation/Client.html +++ b/docs/Documentation/Client.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/CommandCenter.html b/docs/Documentation/CommandCenter.html index 2b0eff299..3f64c4468 100644 --- a/docs/Documentation/CommandCenter.html +++ b/docs/Documentation/CommandCenter.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Controllable.html b/docs/Documentation/Controllable.html index f5b5395af..64d62a028 100644 --- a/docs/Documentation/Controllable.html +++ b/docs/Documentation/Controllable.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -381,6 +384,12 @@ This is different from the EnRoute tasks, where the targets of the task need to CONTROLLABLE:GetWayPoints()

    Get the current WayPoints set with the WayPoint functions( Note that the WayPoints can be nil, although there ARE waypoints).

    + + + + CONTROLLABLE:IsAirPlane() + +

    Returns if the Controllable contains AirPlanes.

    @@ -1467,6 +1476,24 @@ WayPoints If WayPoints is given, then return the WayPoints structure.

    + +CONTROLLABLE:IsAirPlane() + +
    +
    + +

    Returns if the Controllable contains AirPlanes.

    + +

    Return value

    + +

    #boolean: +true if Controllable contains AirPlanes.

    + +
    +
    +
    +
    + CONTROLLABLE:IsTargetDetected(DCSObject, DetectVisual, DetectOptical, DetectRadar, DetectIRST, DetectRWR, DetectDLINK) diff --git a/docs/Documentation/DCSAirbase.html b/docs/Documentation/DCSAirbase.html index 2af4af8a7..3ac796e64 100644 --- a/docs/Documentation/DCSAirbase.html +++ b/docs/Documentation/DCSAirbase.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSCoalitionObject.html b/docs/Documentation/DCSCoalitionObject.html index db3a4f6e7..5bdce602d 100644 --- a/docs/Documentation/DCSCoalitionObject.html +++ b/docs/Documentation/DCSCoalitionObject.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSCommand.html b/docs/Documentation/DCSCommand.html index ba3c6f68b..0d0452176 100644 --- a/docs/Documentation/DCSCommand.html +++ b/docs/Documentation/DCSCommand.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSController.html b/docs/Documentation/DCSController.html index 7bb78517e..69031cbe2 100644 --- a/docs/Documentation/DCSController.html +++ b/docs/Documentation/DCSController.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSGroup.html b/docs/Documentation/DCSGroup.html index 0e46e13f7..1880115ad 100644 --- a/docs/Documentation/DCSGroup.html +++ b/docs/Documentation/DCSGroup.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSObject.html b/docs/Documentation/DCSObject.html index 16726539b..c7ce85731 100644 --- a/docs/Documentation/DCSObject.html +++ b/docs/Documentation/DCSObject.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSTask.html b/docs/Documentation/DCSTask.html index 2c2a21004..970c60afc 100644 --- a/docs/Documentation/DCSTask.html +++ b/docs/Documentation/DCSTask.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSTypes.html b/docs/Documentation/DCSTypes.html index 09159ce8a..c792b366b 100644 --- a/docs/Documentation/DCSTypes.html +++ b/docs/Documentation/DCSTypes.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSUnit.html b/docs/Documentation/DCSUnit.html index 313ba5531..a6ef53171 100644 --- a/docs/Documentation/DCSUnit.html +++ b/docs/Documentation/DCSUnit.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSVec3.html b/docs/Documentation/DCSVec3.html index c06367600..25e1cdbc1 100644 --- a/docs/Documentation/DCSVec3.html +++ b/docs/Documentation/DCSVec3.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSWorld.html b/docs/Documentation/DCSWorld.html index 3ac33e80e..54a7c9322 100644 --- a/docs/Documentation/DCSWorld.html +++ b/docs/Documentation/DCSWorld.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCSZone.html b/docs/Documentation/DCSZone.html index fcfe71bef..4cdf096a3 100644 --- a/docs/Documentation/DCSZone.html +++ b/docs/Documentation/DCSZone.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCScountry.html b/docs/Documentation/DCScountry.html index 36b19f191..cf5c3702d 100644 --- a/docs/Documentation/DCScountry.html +++ b/docs/Documentation/DCScountry.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCStimer.html b/docs/Documentation/DCStimer.html index 035f72735..0486c6e93 100644 --- a/docs/Documentation/DCStimer.html +++ b/docs/Documentation/DCStimer.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/DCStrigger.html b/docs/Documentation/DCStrigger.html index 3c76851aa..45355f827 100644 --- a/docs/Documentation/DCStrigger.html +++ b/docs/Documentation/DCStrigger.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Database.html b/docs/Documentation/Database.html index 1953c3339..074b166d3 100644 --- a/docs/Documentation/Database.html +++ b/docs/Documentation/Database.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -145,6 +148,12 @@ The following iterator methods are currently available within the DATABASE:

    DATABASE + + + + PlayerCheckSchedule + + @@ -241,7 +250,7 @@ The following iterator methods are currently available within the DATABASE:

    - DATABASE:DeletePlayer(PlayerName) + DATABASE:DeletePlayer(UnitName, PlayerName)

    Deletes a player from the DATABASE based on the Player Name.

    @@ -313,21 +322,27 @@ The following iterator methods are currently available within the DATABASE:

    - DATABASE:ForEachGroup(IteratorFunction, ...) + DATABASE:ForEachGroup(IteratorFunction, FinalizeFunction, ...)

    Iterate the DATABASE and call an iterator function for each alive GROUP, providing the GROUP and optional parameters.

    - DATABASE:ForEachPlayer(IteratorFunction, ...) + DATABASE:ForEachPlayer(IteratorFunction, FinalizeFunction, ...)

    Iterate the DATABASE and call an iterator function for each ALIVE player, providing the player name and optional parameters.

    - DATABASE:ForEachPlayerJoined(IteratorFunction, ...) + DATABASE:ForEachPlayerJoined(IteratorFunction, FinalizeFunction, ...)

    Iterate the DATABASE and call an iterator function for each player who has joined the mission, providing the Unit of the player and optional parameters.

    + + + + DATABASE:ForEachPlayerUnit(IteratorFunction, FinalizeFunction, ...) + +

    Iterate the DATABASE and call an iterator function for each ALIVE player UNIT, providing the player UNIT and optional parameters.

    @@ -394,6 +409,12 @@ The following iterator methods are currently available within the DATABASE:

    DATABASE:GetGroupTemplateFromUnitName(UnitName) + + + + DATABASE:GetPlayerSettings(PlayerName) + +

    Gets the player settings

    @@ -442,18 +463,36 @@ The following iterator methods are currently available within the DATABASE:

    DATABASE.PLAYERS + + + + DATABASE.PLAYERSETTINGS + + DATABASE.PLAYERSJOINED + + + + DATABASE.PLAYERUNITS + + DATABASE.STATICS + + + + DATABASE:SetPlayerSettings(PlayerName, Settings) + +

    Sets the player settings

    @@ -579,6 +618,20 @@ The following iterator methods are currently available within the DATABASE:

    +
    +
    +
    +
    + + + +PlayerCheckSchedule + +
    +
    + + +

    Type Database

    @@ -879,17 +932,22 @@ The name of the airbase

    -DATABASE:DeletePlayer(PlayerName) +DATABASE:DeletePlayer(UnitName, PlayerName)

    Deletes a player from the DATABASE based on the Player Name.

    -

    Parameter

    +

    Parameters

    +

    Return value

    + +

    #DATABASE: +self

    + +
    + +
    +
    + + +DATABASE:ForEachPlayerUnit(IteratorFunction, FinalizeFunction, ...) + +
    +
    + +

    Iterate the DATABASE and call an iterator function for each ALIVE player UNIT, providing the player UNIT and optional parameters.

    + +

    Parameters

    +
    +
    +
    +
    + + + +DATABASE.PLAYERSETTINGS + +
    +
    + + +
    @@ -1712,6 +1862,20 @@ DBObject = DATABASE:New() + +
    +
    +
    + + + +DATABASE.PLAYERUNITS + +
    +
    + + +
    @@ -1726,6 +1890,37 @@ DBObject = DATABASE:New() + +
    +
    +
    + + +DATABASE:SetPlayerSettings(PlayerName, Settings) + +
    +
    + +

    Sets the player settings

    + +

    Parameters

    + +

    Return value

    + +

    Core.Settings#SETTINGS:

    + +
    @@ -1830,6 +2025,7 @@ self

    + #number DATABASE.UNITS_Position diff --git a/docs/Documentation/Designate.html b/docs/Documentation/Designate.html index d8950ff85..bf0481cec 100644 --- a/docs/Documentation/Designate.html +++ b/docs/Documentation/Designate.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Detection.html b/docs/Documentation/Detection.html index b60e01592..5cbd9bb85 100644 --- a/docs/Documentation/Detection.html +++ b/docs/Documentation/Detection.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -197,13 +200,13 @@ DETECTION uses the in-built detection capabilities of DCS World, but adds new fu - DETECTION_AREAS:DetectedItemMenu(Index) + DETECTION_AREAS:DetectedItemMenu(Index, AttackGroup)

    Menu of a detected item using a given numeric index.

    - DETECTION_AREAS:DetectedItemReportSummary(Index) + DETECTION_AREAS:DetectedItemReportSummary(Index, AttackGroup)

    Report summary of a detected item using a given numeric index.

    @@ -215,7 +218,7 @@ DETECTION uses the in-built detection capabilities of DCS World, but adds new fu - DETECTION_AREAS:DetectedReportDetailed() + DETECTION_AREAS:DetectedReportDetailed(AttackGroup)

    Report detailed of a detection result.

    @@ -248,12 +251,6 @@ DETECTION uses the in-built detection capabilities of DCS World, but adds new fu DETECTION_AREAS:GetTreatLevelA2G(DetectedItem)

    Returns the A2G threat level of the units in the DetectedItem

    - - - - DETECTION_AREAS:IsFriendliesNearBy(DetectedItem) - -

    Returns if there are friendlies nearby the FAC units ...

    @@ -441,13 +438,13 @@ DETECTION uses the in-built detection capabilities of DCS World, but adds new fu - DETECTION_BASE:DetectedItemMenu(Index) + DETECTION_BASE:DetectedItemMenu(Index, AttackGroup)

    Menu of a detected item using a given numeric index.

    - DETECTION_BASE:DetectedItemReportSummary(Index) + DETECTION_BASE:DetectedItemReportSummary(Index, AttackGroup)

    Report summary of a detected item using a given numeric index.

    @@ -471,7 +468,7 @@ DETECTION uses the in-built detection capabilities of DCS World, but adds new fu - DETECTION_BASE:DetectedReportDetailed() + DETECTION_BASE:DetectedReportDetailed(AttackGroup)

    Report detailed of a detectedion result.

    @@ -533,6 +530,12 @@ The different values of Unit.Category can be:

    Multiple Unit.Category entries can be given as a table and then these will be evaluated as an OR expression.

    + + + + DETECTION_BASE.FriendliesRange + + @@ -545,12 +548,24 @@ The different values of Unit.Category can be:

    DETECTION_BASE:GetDetectedItem(Index)

    Get a detected item using a given numeric index.

    + + + + DETECTION_BASE:GetDetectedItemCoordinate(Index) + +

    Get the COORDINATE of a detection item using a given numeric index.

    DETECTION_BASE:GetDetectedItemID(Index)

    Get a detected ItemID using a given numeric index.

    + + + + DETECTION_BASE:GetDetectedItemZone(Index) + +

    Get the Zone#ZONE_UNIT of a detection area using a given numeric index.

    @@ -575,18 +590,24 @@ The different values of Unit.Category can be:

    DETECTION_BASE:GetDetectedSet(Index)

    Get the Set#SET_UNIT of a detecttion area using a given numeric index.

    - - - - DETECTION_BASE:GetDetectedZone(Index) - -

    Get the Zone#ZONE_UNIT of a detection area using a given numeric index.

    DETECTION_BASE:GetDetectionSetGroup()

    Get the detection Groups.

    + + + + DETECTION_BASE:GetFriendliesNearBy(DetectedItem) + +

    Returns friendly units nearby the FAC units ...

    + + + + DETECTION_BASE:GetPlayersNearBy(DetectedItem) + +

    Returns friendly units nearby the FAC units ...

    @@ -641,6 +662,12 @@ The different values of Unit.Category can be:

    DETECTION_BASE:IsFriendliesNearBy(DetectedItem)

    Returns if there are friendlies nearby the FAC units ...

    + + + + DETECTION_BASE:IsPlayersNearBy(DetectedItem) + +

    Returns if there are friendlies nearby the FAC units ...

    @@ -785,6 +812,12 @@ The different values of Unit.Category can be:

    DETECTION_BASE:SetDistanceProbability(DistanceProbability)

    Upon a visual detection, the further away a detected object is, the less likely it is to be detected properly.

    + + + + DETECTION_BASE:SetFriendliesRange(FriendliesRange) + +

    Set the radius in meters to validate if friendlies are nearby.

    @@ -1004,19 +1037,19 @@ The different values of Unit.Category can be:

    - DETECTION_TYPES:DetectedItemMenu(Index, DetectedTypeName) + DETECTION_TYPES:DetectedItemMenu(Index, DetectedTypeName, AttackGroup)

    Menu of a DetectedItem using a given numeric index.

    - DETECTION_TYPES:DetectedItemReportSummary(Index, DetectedTypeName) + DETECTION_TYPES:DetectedItemReportSummary(Index, DetectedTypeName, AttackGroup)

    Report summary of a DetectedItem using a given numeric index.

    - DETECTION_TYPES:DetectedReportDetailed() + DETECTION_TYPES:DetectedReportDetailed(AttackGroup)

    Report detailed of a detection result.

    @@ -1086,19 +1119,19 @@ The different values of Unit.Category can be:

    - DETECTION_UNITS:DetectedItemMenu(Index) + DETECTION_UNITS:DetectedItemMenu(Index, AttackGroup)

    Menu of a DetectedItem using a given numeric index.

    - DETECTION_UNITS:DetectedItemReportSummary(Index) + DETECTION_UNITS:DetectedItemReportSummary(Index, AttackGroup)

    Report summary of a DetectedItem using a given numeric index.

    - DETECTION_UNITS:DetectedReportDetailed() + DETECTION_UNITS:DetectedReportDetailed(AttackGroup)

    Report detailed of a detection result.

    @@ -1385,6 +1418,11 @@ An example of how to use the method is shown below.

    Detection:Start() +

    Detection of Friendlies Nearby

    + +

    Use the method Detection#DETECTION_BASE.SetFriendliesRange() to set the range what will indicate when friendlies are nearby +a DetectedItem. The default range is 6000 meters. For air detections, it is advisory to use about 30.000 meters.

    +

    DETECTION_BASE is a Finite State Machine

    Various Events and State Transitions can be tailored using DETECTION_BASE.

    @@ -1556,19 +1594,24 @@ self

    -DETECTION_AREAS:DetectedItemMenu(Index) +DETECTION_AREAS:DetectedItemMenu(Index, AttackGroup)

    Menu of a detected item using a given numeric index.

    -

    Parameter

    +

    Parameters

    • Index :

      +
    • +
    • + +

      AttackGroup :

      +

    Return value

    @@ -1582,19 +1625,24 @@ self

    -DETECTION_AREAS:DetectedItemReportSummary(Index) +DETECTION_AREAS:DetectedItemReportSummary(Index, AttackGroup)

    Report summary of a detected item using a given numeric index.

    -

    Parameter

    +

    Parameters

    • Index :

      +
    • +
    • + +

      AttackGroup :

      +

    Return value

    @@ -1622,13 +1670,21 @@ self

    -DETECTION_AREAS:DetectedReportDetailed() +DETECTION_AREAS:DetectedReportDetailed(AttackGroup)

    Report detailed of a detection result.

    +

    Parameter

    +
      +
    • + +

      AttackGroup :

      + +
    • +

    Return value

    #string:

    @@ -1741,32 +1797,6 @@ a scale from 0 to 10.

    - -DETECTION_AREAS:IsFriendliesNearBy(DetectedItem) - -
    -
    - -

    Returns if there are friendlies nearby the FAC units ...

    - -

    Parameter

    -
      -
    • - -

      DetectedItem :

      - -
    • -
    -

    Return value

    - -

    #boolean: -trhe if there are friendlies nearby

    - -
    -
    -
    -
    - DETECTION_AREAS:NearestFAC(DetectedItem) @@ -2324,6 +2354,7 @@ The index of the DetectedItem.

    + #number DETECTION_BASE.DetectedItemCount @@ -2337,6 +2368,7 @@ The index of the DetectedItem.

    + #number DETECTION_BASE.DetectedItemMax @@ -2351,19 +2383,24 @@ The index of the DetectedItem.

    -DETECTION_BASE:DetectedItemMenu(Index) +DETECTION_BASE:DetectedItemMenu(Index, AttackGroup)

    Menu of a detected item using a given numeric index.

    -

    Parameter

    +

    Parameters

    • Index :

      +
    • +
    • + +

      AttackGroup :

      +

    Return value

    @@ -2377,19 +2414,24 @@ The index of the DetectedItem.

    -DETECTION_BASE:DetectedItemReportSummary(Index) +DETECTION_BASE:DetectedItemReportSummary(Index, AttackGroup)

    Report summary of a detected item using a given numeric index.

    -

    Parameter

    +

    Parameters

    • Index :

      +
    • +
    • + +

      AttackGroup :

      +

    Return value

    @@ -2445,13 +2487,21 @@ The index of the DetectedItem.

    -DETECTION_BASE:DetectedReportDetailed() +DETECTION_BASE:DetectedReportDetailed(AttackGroup)

    Report detailed of a detectedion result.

    +

    Parameter

    +
      +
    • + +

      AttackGroup :

      + +
    • +

    Return value

    #string:

    @@ -2476,7 +2526,7 @@ The index of the DetectedItem.

    - + #number DETECTION_BASE.DetectionInterval @@ -2611,6 +2661,20 @@ cs.DCSUnit#Unit> FilterCategories The Categories entries

    #DETECTION_BASE: self

    +
    +
    +
    +
    + + + +DETECTION_BASE.FriendliesRange + +
    +
    + + +
    @@ -2663,6 +2727,32 @@ DetectedItemID

    #DETECTION_BASE.DetectedItem:

    +
    +
    +
    +
    + + +DETECTION_BASE:GetDetectedItemCoordinate(Index) + +
    +
    + +

    Get the COORDINATE of a detection item using a given numeric index.

    + +

    Parameter

    +
      +
    • + +

      #number Index :

      + +
    • +
    +

    Return value

    + +

    Core.Point#COORDINATE:

    + +
    @@ -2694,6 +2784,32 @@ DetectedItemID

    + +DETECTION_BASE:GetDetectedItemZone(Index) + +
    +
    + +

    Get the Zone#ZONE_UNIT of a detection area using a given numeric index.

    + +

    Parameter

    +
      +
    • + +

      #number Index :

      + +
    • +
    +

    Return value

    + +

    Core.Zone#ZONE_UNIT: +DetectedZone

    + +
    +
    +
    +
    + DETECTION_BASE:GetDetectedItems() @@ -2782,32 +2898,6 @@ DetectedSet

    - -DETECTION_BASE:GetDetectedZone(Index) - -
    -
    - -

    Get the Zone#ZONE_UNIT of a detection area using a given numeric index.

    - -

    Parameter

    -
      -
    • - -

      #number Index :

      - -
    • -
    -

    Return value

    - -

    Core.Zone#ZONE_UNIT: -DetectedZone

    - -
    -
    -
    -
    - DETECTION_BASE:GetDetectionSetGroup() @@ -2821,6 +2911,58 @@ DetectedZone

    Core.Set#SET_GROUP:

    + +
    +
    +
    + + +DETECTION_BASE:GetFriendliesNearBy(DetectedItem) + +
    +
    + +

    Returns friendly units nearby the FAC units ...

    + +

    Parameter

    +
      +
    • + +

      DetectedItem :

      + +
    • +
    +

    Return value

    + +

    #map:

    +

    string,Wrapper.Unit#UNIT> The map of Friendly UNITs.

    + +
    +
    +
    +
    + + +DETECTION_BASE:GetPlayersNearBy(DetectedItem) + +
    +
    + +

    Returns friendly units nearby the FAC units ...

    + +

    Parameter

    +
      +
    • + +

      DetectedItem :

      + +
    • +
    +

    Return value

    + +

    #map:

    +

    string,Wrapper.Unit#UNIT> The map of Friendly UNITs.

    +
    @@ -3055,6 +3197,32 @@ trhe if there are friendlies nearby

    + +DETECTION_BASE:IsPlayersNearBy(DetectedItem) + +
    +
    + +

    Returns if there are friendlies nearby the FAC units ...

    + +

    Parameter

    +
      +
    • + +

      DetectedItem :

      + +
    • +
    +

    Return value

    + +

    #boolean: +trhe if there are friendlies nearby

    + +
    +
    +
    +
    + DETECTION_BASE:New(DetectionSetGroup) @@ -3790,6 +3958,33 @@ self

    + +DETECTION_BASE:SetFriendliesRange(FriendliesRange) + +
    +
    + +

    Set the radius in meters to validate if friendlies are nearby.

    + +

    Parameter

    +
      +
    • + +

      #number FriendliesRange : +Radius to use when checking if Friendlies are nearby.

      + +
    • +
    +

    Return value

    + +

    #DETECTION_BASE: +self

    + +
    +
    +
    +
    + DETECTION_BASE:SetRejectZones(RejectZones) @@ -4430,7 +4625,7 @@ self

    -DETECTION_TYPES:DetectedItemMenu(Index, DetectedTypeName) +DETECTION_TYPES:DetectedItemMenu(Index, DetectedTypeName, AttackGroup)
    @@ -4448,6 +4643,11 @@ self

    DetectedTypeName :

    + +
  • + +

    AttackGroup :

    +
  • Return value

    @@ -4461,7 +4661,7 @@ self

    -DETECTION_TYPES:DetectedItemReportSummary(Index, DetectedTypeName) +DETECTION_TYPES:DetectedItemReportSummary(Index, DetectedTypeName, AttackGroup)
    @@ -4479,6 +4679,11 @@ self

    DetectedTypeName :

    + +
  • + +

    AttackGroup :

    +
  • Return value

    @@ -4492,13 +4697,21 @@ self

    -DETECTION_TYPES:DetectedReportDetailed() +DETECTION_TYPES:DetectedReportDetailed(AttackGroup)

    Report detailed of a detection result.

    +

    Parameter

    +
      +
    • + +

      AttackGroup :

      + +
    • +

    Return value

    #string:

    @@ -4647,7 +4860,7 @@ self

    Type DETECTION_UNITS

    -

    2) DETECTION_UNITS class, extends Detection#DETECTION_BASE

    +

    DETECTION_UNITS class, extends Detection#DETECTION_BASE

    The DETECTION_UNITS class will detect units within the battle zone.

    @@ -4696,19 +4909,24 @@ self

    -DETECTION_UNITS:DetectedItemMenu(Index) +DETECTION_UNITS:DetectedItemMenu(Index, AttackGroup)

    Menu of a DetectedItem using a given numeric index.

    -

    Parameter

    +

    Parameters

    • Index :

      +
    • +
    • + +

      AttackGroup :

      +

    Return value

    @@ -4722,19 +4940,24 @@ self

    -DETECTION_UNITS:DetectedItemReportSummary(Index) +DETECTION_UNITS:DetectedItemReportSummary(Index, AttackGroup)

    Report summary of a DetectedItem using a given numeric index.

    -

    Parameter

    +

    Parameters

    • Index :

      +
    • +
    • + +

      AttackGroup :

      +

    Return value

    @@ -4748,13 +4971,21 @@ self

    -DETECTION_UNITS:DetectedReportDetailed() +DETECTION_UNITS:DetectedReportDetailed(AttackGroup)

    Report detailed of a detection result.

    +

    Parameter

    +
      +
    • + +

      AttackGroup :

      + +
    • +

    Return value

    #string:

    @@ -4904,6 +5135,8 @@ self

    Type list

    +

    Type map

    + diff --git a/docs/Documentation/DetectionManager.html b/docs/Documentation/DetectionManager.html index dc5177289..691620d5b 100644 --- a/docs/Documentation/DetectionManager.html +++ b/docs/Documentation/DetectionManager.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Escort.html b/docs/Documentation/Escort.html index 39517ecf7..ce7a2d565 100644 --- a/docs/Documentation/Escort.html +++ b/docs/Documentation/Escort.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Event.html b/docs/Documentation/Event.html index 8c2d52ea1..7efd063d1 100644 --- a/docs/Documentation/Event.html +++ b/docs/Documentation/Event.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Fsm.html b/docs/Documentation/Fsm.html index 9f6365bca..1b1039138 100644 --- a/docs/Documentation/Fsm.html +++ b/docs/Documentation/Fsm.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -1624,7 +1627,7 @@ A string defining the start state.

    - + #string FSM._StartState @@ -1923,7 +1926,6 @@ A string defining the start state.

    - FSM.current diff --git a/docs/Documentation/Group.html b/docs/Documentation/Group.html index 061abb9d6..13a3699cd 100644 --- a/docs/Documentation/Group.html +++ b/docs/Documentation/Group.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -240,6 +243,12 @@ GROUP:GetCoalition()

    Returns the coalition of the DCS Group.

    + + + + GROUP:GetCoordinate() + +

    Returns a COORDINATE object indicating the point of the first UNIT of the GROUP within the mission.

    @@ -858,6 +867,34 @@ The coalition side of the DCS Group.

    + +GROUP:GetCoordinate() + +
    +
    + +

    Returns a COORDINATE object indicating the point of the first UNIT of the GROUP within the mission.

    + +

    Return values

    +
      +
    1. + +

      Core.Point#COORDINATE: +The COORDINATE of the GROUP.

      + +
    2. +
    3. + +

      #nil: +The POSITIONABLE is not existing or alive.

      + +
    4. +
    +
    +
    +
    +
    + GROUP:GetCountry() diff --git a/docs/Documentation/Identifiable.html b/docs/Documentation/Identifiable.html index 7db00fa30..61afa0732 100644 --- a/docs/Documentation/Identifiable.html +++ b/docs/Documentation/Identifiable.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Menu.html b/docs/Documentation/Menu.html index 0bc1432fb..bea9ba7f9 100644 --- a/docs/Documentation/Menu.html +++ b/docs/Documentation/Menu.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Message.html b/docs/Documentation/Message.html index 2855c184e..c590dd63e 100644 --- a/docs/Documentation/Message.html +++ b/docs/Documentation/Message.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/MissileTrainer.html b/docs/Documentation/MissileTrainer.html index 69072fd29..ab8c725e6 100644 --- a/docs/Documentation/MissileTrainer.html +++ b/docs/Documentation/MissileTrainer.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Mission.html b/docs/Documentation/Mission.html index 22c3cdf97..127fc4288 100644 --- a/docs/Documentation/Mission.html +++ b/docs/Documentation/Mission.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -181,7 +184,7 @@ A CLIENT needs to be registered within the MISSION:GetMenu() + MISSION:GetMenu(TaskGroup)

    Gets the mission menu for the coalition.

    @@ -274,6 +277,12 @@ A CLIENT needs to be registered within the MISSION:JoinUnit(PlayerUnit, PlayerGroup)

    Add a Unit to join the Mission.

    + + + + MISSION:MenuReportBriefing(ReportGroup) + + @@ -430,6 +439,12 @@ A CLIENT needs to be registered within the MISSION:RemoveTaskMenu(Task)

    Removes a Task menu.

    + + + + MISSION:ReportBriefing() + +

    Create a briefing report of the Mission.

    @@ -439,7 +454,7 @@ A CLIENT needs to be registered within the MISSION:ReportOverview(TaskStatus) + MISSION:ReportOverview(ReportGroup, TaskStatus)

    Create a overview report of the Mission (multiple lines).

    @@ -520,12 +535,6 @@ A CLIENT needs to be registered within the MISSION:__Stop(Delay)

    Asynchronous Event Trigger for Event Stop.

    - - - - MISSION:onbeforeComplete(From, Event, To) - - @@ -799,13 +808,21 @@ The CLIENT or UNIT of the Player crashing.

    -MISSION:GetMenu() +MISSION:GetMenu(TaskGroup)

    Gets the mission menu for the coalition.

    +

    Parameter

    +
      +
    • + +

      TaskGroup :

      + +
    • +

    Return value

    Core.Menu#MENU_COALITION: @@ -1177,6 +1194,27 @@ true if Unit is part of a Task in the Mission.

    + +MISSION:MenuReportBriefing(ReportGroup) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      ReportGroup :

      + +
    • +
    +
    +
    +
    +
    + MISSION:MenuReportOverview(TaskStatus, ReportGroup) @@ -1991,6 +2029,24 @@ The cleaned Task reference.

    #MISSION: self

    +
    +
    +
    +
    + + +MISSION:ReportBriefing() + +
    +
    + +

    Create a briefing report of the Mission.

    + +

    Return value

    + +

    #string:

    + +
    @@ -2015,17 +2071,22 @@ self

    -MISSION:ReportOverview(TaskStatus) +MISSION:ReportOverview(ReportGroup, TaskStatus)

    Create a overview report of the Mission (multiple lines).

    -

    Parameter

    +

    Parameters

    diff --git a/docs/Documentation/Object.html b/docs/Documentation/Object.html index 1b5902a84..700110791 100644 --- a/docs/Documentation/Object.html +++ b/docs/Documentation/Object.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Point.html b/docs/Documentation/Point.html index 6da90c9fd..dee30da78 100644 --- a/docs/Documentation/Point.html +++ b/docs/Documentation/Point.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -132,8 +135,8 @@

    Hereby the change log:

    -

    2017-03-03: POINT_VEC3:Explosion( ExplosionIntensity ) added.
    -2017-03-03: POINT_VEC3:IlluminationBomb() added.

    +

    2017-03-03: POINT_VEC3:Explosion( ExplosionIntensity ) added. +2017-03-03: POINT_VEC3:IlluminationBomb() added.

    2017-02-18: POINT_VEC3:NewFromVec2( Vec2, LandHeightAdd ) added.

    @@ -162,15 +165,15 @@ COORDINATE -

    COORDINATE class, extends Point#COORDINATE

    +

    COORDINATE class, extends Base#BASE

    -

    The COORDINATE class defines a 2D coordinate in the simulator.

    +

    COORDINATE defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space.

    POINT_VEC2 -

    POINT_VEC2 class, extends Point#POINT_VEC3

    +

    POINT_VEC2 class, extends Point#COORDINATE

    The Point#POINT_VEC2 class defines a 2D point in the simulator.

    @@ -178,7 +181,7 @@ POINT_VEC3 -

    POINT_VEC3 class, extends Base#BASE

    +

    POINT_VEC3 class, extends Point#COORDINATE

    POINT_VEC3 defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space.

    @@ -187,55 +190,169 @@

    Type COORDINATE

    - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -253,34 +370,136 @@ - + + + + + + + + + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + +
    COORDINATE:CoordinateMenu(RootMenu)COORDINATE:DistanceFromVec2(Vec2Reference)
    COORDINATE.LL_AccuracyCOORDINATE:Explosion(ExplosionIntensity) +

    Creates an explosion at the point of a certain intensity.

    +
    COORDINATE:Flare(FlareColor, (, Azimuth) +

    Flares the point in a color.

    +
    COORDINATE:FlareGreen((, Azimuth) +

    Flare the COORDINATE Green.

    +
    COORDINATE:FlareRed(Azimuth) +

    Flare the COORDINATE Red.

    +
    COORDINATE:FlareWhite((, Azimuth) +

    Flare the COORDINATE White.

    +
    COORDINATE:FlareYellow((, Azimuth) +

    Flare the COORDINATE Yellow.

    +
    COORDINATE:Get2DDistance(TargetCoordinate) +

    Return the 2D distance in meters between the target COORDINATE and the COORDINATE.

    +
    COORDINATE:Get3DDistance(TargetCoordinate) +

    Return the 3D distance in meters between the target COORDINATE and the COORDINATE.

    +
    COORDINATE:GetAltitudeText(Settings) +

    Return the altitude text of the COORDINATE.

    +
    COORDINATE:GetAngleDegrees(DirectionVec3) +

    Return an angle in degrees from the COORDINATE using a direction vector in Vec3 format.

    +
    COORDINATE:GetAngleRadians(DirectionVec3) +

    Return an angle in radians from the COORDINATE using a direction vector in Vec3 format.

    +
    COORDINATE:GetBRAText(AngleRadians, Distance, Settings) +

    Provides a Bearing / Range / Altitude string

    +
    COORDINATE:GetBRText(AngleRadians, Distance, Settings) +

    Provides a Bearing / Range string

    +
    COORDINATE:GetBearingText(AngleRadians, Precision, Settings) +

    Provides a bearing text in degrees.

    +
    COORDINATE:GetDirectionVec3(TargetCoordinate) +

    Return a direction vector Vec3 from COORDINATE to the COORDINATE.

    +
    COORDINATE:GetDistanceText(Distance, Settings) +

    Provides a distance text expressed in the units of measurement.

    +
    COORDINATE:GetNorthCorrectionRadians() +

    Get a correction in radians of the real magnetic north of the COORDINATE.

    +
    COORDINATE:GetRandomVec2InRadius(OuterRadius, InnerRadius) +

    Return a random Vec2 within an Outer Radius and optionally NOT within an Inner Radius of the COORDINATE.

    +
    COORDINATE:GetRandomVec3InRadius(OuterRadius, InnerRadius) +

    Return a random Vec3 within an Outer Radius and optionally NOT within an Inner Radius of the COORDINATE.

    +
    COORDINATE:GetVec2() +

    Return the coordinates of the COORDINATE in Vec2 format.

    +
    COORDINATE:GetVec3() +

    Return the coordinates of the COORDINATE in Vec3 format.

    +
    COORDINATE:IlluminationBomb() +

    Creates an illumination bomb at the point.

    +
    COORDINATE:IsLOS(ToCoordinate) +

    Returns if a Coordinate has Line of Sight (LOS) with the ToCoordinate.

    +
    COORDINATE:IsModeA2A() +

    Is the mode to A2A

    +
    COORDINATE:IsModeA2G() +

    Is the mode to A2G

    +
    COORDINATE.Mode
    COORDINATE.LL_DMS - -
    COORDINATE.MGRS_Accuracy - -
    COORDINATE:MenuLL_Accuracy(LL_Accuracy) - -
    COORDINATE:MenuLL_DMS(LL_DMS) - -
    COORDINATE:MenuMGRS_Accuracy(MGRS_Accuracy) - -
    COORDINATE:MenuSystem(System) - -
    COORDINATE:New(x, y, LandHeightAdd)COORDINATE:New(x, y, z)

    COORDINATE constructor.

    COORDINATE.SystemCOORDINATE:RoutePointAir(AltType, Type, Action, Speed, SpeedLocked) +

    Build an air type route point.

    +
    COORDINATE:RoutePointGround(Speed, Formation) +

    Build an ground type route point.

    +
    COORDINATE:SetHeading(Heading)
    COORDINATE.SystemMenuCOORDINATE:SetModeA2A() - +

    Set the mode to A2A

    COORDINATE:ToString()COORDINATE:SetModeA2G() +

    Set the mode to A2G

    +
    COORDINATE:Smoke(SmokeColor) +

    Smokes the point in a color.

    +
    COORDINATE:SmokeBlue() +

    Smoke the COORDINATE Blue.

    +
    COORDINATE:SmokeGreen() +

    Smoke the COORDINATE Green.

    +
    COORDINATE:SmokeOrange() +

    Smoke the COORDINATE Orange.

    +
    COORDINATE:SmokeRed() +

    Smoke the COORDINATE Red.

    +
    COORDINATE:SmokeWhite() +

    Smoke the COORDINATE White.

    +
    COORDINATE:ToString(Controllable, Settings)

    Provides a coordinate string of the point, based on a coordinate format system: * Uses default settings in COORDINATE.

    COORDINATE:ToStringLL(LL_Accuracy, LL_DMS)COORDINATE:ToStringAspect(TargetCoordinate) +

    Return an aspect string from a COORDINATE to the Angle of the object.

    +
    COORDINATE:ToStringBR(TargetCoordinate, FromCoordinate, Settings) +

    Return a BR string from a COORDINATE to the COORDINATE.

    +
    COORDINATE:ToStringBRA(TargetCoordinate, FromCoordinate, Settings) +

    Return a BRAA string from a COORDINATE to the COORDINATE.

    +
    COORDINATE:ToStringBULLS(Coalition, Settings) +

    Return a BULLS string from a COORDINATE to the BULLS of the coalition.

    +
    COORDINATE:ToStringLL(Settings)

    Provides a Lat Lon string

    COORDINATE:ToStringMGRS(MGRS_Accuracy)COORDINATE:ToStringMGRS(Settings)

    Provides a MGRS string

    +
    COORDINATE:Translate(Distance, Angle) +

    Add a Distance in meters from the COORDINATE orthonormal plane, with the given angle, and calculate the new COORDINATE.

    +
    COORDINATE.x + +
    COORDINATE.y + +
    COORDINATE.z +
    @@ -308,25 +527,13 @@ POINT_VEC2:DistanceFromPointVec2(PointVec2Reference) -

    Calculate the distance from a reference #POINT_VEC2.

    - - - - POINT_VEC2:DistanceFromVec2(Vec2Reference) - -

    Calculate the distance from a reference DCSTypes#Vec2.

    + POINT_VEC2:GetAlt()

    Return the altitude (height) of the land at the POINT_VEC2.

    - - - - POINT_VEC2:GetAltitudeText() - -

    Return no text for the altitude of the POINT_VEC2.

    @@ -339,6 +546,12 @@ POINT_VEC2:GetLon()

    Return the Lon(gitude) coordinate of the POINTVEC2 (ie: (parent)POINTVEC3.z).

    + + + + POINT_VEC2:GetRandomPointVec2InRadius(OuterRadius, InnerRadius) + +

    Return a random POINTVEC2 within an Outer Radius and optionally NOT within an Inner Radius of the POINTVEC2.

    @@ -399,12 +612,6 @@ POINT_VEC2:SetY(y)

    Set the y coordinate of the POINT_VEC2.

    - - - - POINT_VEC2:Translate(Distance, Angle) - -

    Add a Distance in meters from the POINTVEC2 orthonormal plane, with the given angle, and calculate the new POINTVEC2.

    @@ -445,132 +652,18 @@ POINT_VEC3:AddZ(z)

    Add to the z coordinate of the POINT_VEC3.

    - - - - POINT_VEC3:Explosion(ExplosionIntensity) - -

    Creates an explosion at the point of a certain intensity.

    - - - - POINT_VEC3:Flare(FlareColor, (, Azimuth) - -

    Flares the point in a color.

    POINT_VEC3.FlareColor - - - - POINT_VEC3:FlareGreen((, Azimuth) - -

    Flare the POINT_VEC3 Green.

    - - - - POINT_VEC3:FlareRed(Azimuth) - -

    Flare the POINT_VEC3 Red.

    - - - - POINT_VEC3:FlareWhite((, Azimuth) - -

    Flare the POINT_VEC3 White.

    - - - - POINT_VEC3:FlareYellow((, Azimuth) - -

    Flare the POINT_VEC3 Yellow.

    - - - - POINT_VEC3:Get2DDistance(TargetPointVec3) - -

    Return the 2D distance in meters between the target POINTVEC3 and the POINTVEC3.

    - - - - POINT_VEC3:Get3DDistance(TargetPointVec3) - -

    Return the 3D distance in meters between the target POINTVEC3 and the POINTVEC3.

    - - - - POINT_VEC3:GetAltitudeText() - -

    Return the altitude text of the POINT_VEC3.

    - - - - POINT_VEC3:GetAngleDegrees(DirectionVec3) - -

    Return an angle in degrees from the POINT_VEC3 using a direction vector in Vec3 format.

    - - - - POINT_VEC3:GetAngleRadians(DirectionVec3) - -

    Return an angle in radians from the POINT_VEC3 using a direction vector in Vec3 format.

    - - - - POINT_VEC3:GetBRText(TargetPointVec3) - -

    Return a BR string from a POINTVEC3 to the POINTVEC3.

    - - - - POINT_VEC3:GetDirectionVec3(TargetPointVec3) - -

    Return a direction vector Vec3 from POINTVEC3 to the POINTVEC3.

    - - - - POINT_VEC3:GetNorthCorrectionRadians() - -

    Get a correction in radians of the real magnetic north of the POINT_VEC3.

    - - - - POINT_VEC3:GetRandomPointVec2InRadius(OuterRadius, InnerRadius) - -

    Return a random POINTVEC2 within an Outer Radius and optionally NOT within an Inner Radius of the POINTVEC3.

    POINT_VEC3:GetRandomPointVec3InRadius(OuterRadius, InnerRadius)

    Return a random POINTVEC3 within an Outer Radius and optionally NOT within an Inner Radius of the POINTVEC3.

    - - - - POINT_VEC3:GetRandomVec2InRadius(OuterRadius, InnerRadius) - -

    Return a random Vec2 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC3.

    - - - - POINT_VEC3:GetRandomVec3InRadius(OuterRadius, InnerRadius) - -

    Return a random Vec3 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC3.

    - - - - POINT_VEC3:GetVec2() - -

    Return the coordinates of the POINT_VEC3 in Vec2 format.

    - - - - POINT_VEC3:GetVec3() - -

    Return the coordinates of the POINT_VEC3 in Vec3 format.

    @@ -589,30 +682,6 @@ POINT_VEC3:GetZ()

    Return the z coordinate of the POINT_VEC3.

    - - - - POINT_VEC3:IlluminationBomb() - -

    Creates an illumination bomb at the point.

    - - - - POINT_VEC3:IsLOS(ToPointVec3) - -

    Returns if a PointVec3 has Line of Sight (LOS) with the ToPointVec3.

    - - - - POINT_VEC3:IsMetric() - -

    Gets if the POINT_VEC3 is metric or NM.

    - - - - POINT_VEC3.Metric - - @@ -637,36 +706,18 @@ POINT_VEC3.RoutePointAction - - - - POINT_VEC3:RoutePointAir(AltType, Type, Action, Speed, SpeedLocked) - -

    Build an air type route point.

    POINT_VEC3.RoutePointAltType - - - - POINT_VEC3:RoutePointGround(Speed, Formation) - -

    Build an ground type route point.

    POINT_VEC3.RoutePointType - - - - POINT_VEC3:SetMetric(Metric) - -

    Sets the POINT_VEC3 metric or NM.

    @@ -685,60 +736,12 @@ POINT_VEC3:SetZ(z)

    Set the z coordinate of the POINT_VEC3.

    - - - - POINT_VEC3:Smoke(SmokeColor) - -

    Smokes the point in a color.

    - - - - POINT_VEC3:SmokeBlue() - -

    Smoke the POINT_VEC3 Blue.

    POINT_VEC3.SmokeColor - - - - POINT_VEC3:SmokeGreen() - -

    Smoke the POINT_VEC3 Green.

    - - - - POINT_VEC3:SmokeOrange() - -

    Smoke the POINT_VEC3 Orange.

    - - - - POINT_VEC3:SmokeRed() - -

    Smoke the POINT_VEC3 Red.

    - - - - POINT_VEC3:SmokeWhite() - -

    Smoke the POINT_VEC3 White.

    - - - - POINT_VEC3:ToStringBR(AngleRadians, Distance) - -

    Provides a Bearing / Range string

    - - - - POINT_VEC3:Translate(Distance, Angle) - -

    Add a Distance in meters from the POINTVEC3 horizontal plane, with the given angle, and calculate the new POINTVEC3.

    @@ -814,38 +817,129 @@
    -

    COORDINATE class, extends Point#COORDINATE

    +

    COORDINATE class, extends Base#BASE

    -

    The COORDINATE class defines a 2D coordinate in the simulator.

    +

    COORDINATE defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space.

    -

    The height coordinate (if needed) will be the land height + an optional added height specified. -A COORDINATE can be expressed in LL or in MGRS.

    COORDINATE constructor

    -

    A new COORDINATE instance can be created with:

    +

    A new COORDINATE object can be created with:

    -

    Manupulate the X, Altitude, Y coordinates of the 2D point

    +

    Create waypoints for routes

    -

    A COORDINATE class works in 2D space, with an altitude setting. It contains internally an X, Altitude, Y coordinate. -Methods exist to manupulate these coordinates.

    +

    A COORDINATE can prepare waypoints for Ground and Air groups to be embedded into a Route.

    -

    The current X, Altitude, Y axis can be retrieved with the methods COORDINATE.GetX(), COORDINATE.GetAlt(), COORDINATE.GetY() respectively. -The methods COORDINATE.SetX(), COORDINATE.SetAlt(), COORDINATE.SetY() change the respective axis with a new value. -The current Lat(itude), Alt(itude), Lon(gitude) values can also be retrieved with the methods COORDINATE.GetLat(), COORDINATE.GetAlt(), COORDINATE.GetLon() respectively. -The current axis values can be changed by using the methods COORDINATE.AddX(), COORDINATE.AddAlt(), COORDINATE.AddY() -to add or substract a value from the current respective axis value. -Note that the Set and Add methods return the current COORDINATE object, so these manipulation methods can be chained... For example:

    + + +

    Route points can be used in the Route methods of the Group#GROUP class.

    + + +

    Smoke, flare, explode, illuminate

    + +

    At the point a smoke, flare, explosion and illumination bomb can be triggered. Use the following methods:

    + +

    Smoke

    + + + +

    Flare

    + + + +

    Explode

    + + + +

    Illuminate

    + + + + +

    3D calculation methods

    + +

    Various calculation methods exist to use or manipulate 3D space. Find below a short description of each method:

    + +

    Distance

    + + + +

    Angle

    + + + +

    Translation

    + +
      +
    • COORDINATE.Translate(): Translate the current 3D point towards an other 3D point using the given Distance and Angle.
    • +
    + +

    Get the North correction of the current location

    + + + + +

    Point Randomization

    + +

    Various methods exist to calculate random locations around a given 3D point.

    + + + + +

    Metric system

    + + + + +

    Coorinate text generation

    + + -
     local Vec2 = PointVec2:AddX( 100 ):AddY( 2000 ):GetVec2()
    - 
    -
    @@ -859,7 +953,7 @@ Note that the Set and Add methods return the current COORDINATE object, so these
    -

    POINT_VEC2 class, extends Point#POINT_VEC3

    +

    POINT_VEC2 class, extends Point#COORDINATE

    The Point#POINT_VEC2 class defines a 2D point in the simulator.

    @@ -888,9 +982,9 @@ to add or substract a value from the current respective axis value. Note that the Set and Add methods return the current POINT_VEC2 object, so these manipulation methods can be chained... For example:

     local Vec2 = PointVec2:AddX( 100 ):AddY( 2000 ):GetVec2()
    - 
     
    +
    @@ -903,15 +997,15 @@ Note that the Set and Add methods return the current POINT_VEC2 object, so these
    -

    POINT_VEC3 class, extends Base#BASE

    +

    POINT_VEC3 class, extends Point#COORDINATE

    POINT_VEC3 defines a 3D point in the simulator and with its methods, you can use or manipulate the point in 3D space.

    Important Note: Most of the functions in this section were taken from MIST, and reworked to OO concepts. -In order to keep the credibility of the the author, -I want to emphasize that the formulas embedded in the MIST framework were created by Grimes or previous authors, +In order to keep the credibility of the the author, +I want to emphasize that the formulas embedded in the MIST framework were created by Grimes or previous authors, who you can find on the Eagle Dynamics Forums.

    @@ -940,115 +1034,20 @@ Note that the Set and Add methods return the current POINT_VEC3 object, so these -

    Create waypoints for routes

    - -

    A POINT_VEC3 can prepare waypoints for Ground and Air groups to be embedded into a Route.

    - - - -

    Route points can be used in the Route methods of the Group#GROUP class.

    - - -

    Smoke, flare, explode, illuminate

    - -

    At the point a smoke, flare, explosion and illumination bomb can be triggered. Use the following methods:

    - -

    Smoke

    - - - -

    Flare

    - - - -

    Explode

    - - - -

    Illuminate

    - - - -

    3D calculation methods

    Various calculation methods exist to use or manipulate 3D space. Find below a short description of each method:

    -

    Distance

    - - - -

    Angle

    - - - -

    Translation

    - -
      -
    • POINT_VEC3.Translate(): Translate the current 3D point towards an other 3D point using the given Distance and Angle.
    • -
    - -

    Get the North correction of the current location

    - - -

    Point Randomization

    Various methods exist to calculate random locations around a given 3D point.

    -

    Metric system

    - - - - -

    Coorinate text generation

    - -
    @@ -1059,160 +1058,703 @@ Note that the Set and Add methods return the current POINT_VEC3 object, so these
    - -COORDINATE:CoordinateMenu(RootMenu) + +COORDINATE:DistanceFromVec2(Vec2Reference)
    + +

    TODO: check this to replace +- Calculate the distance from a reference DCSTypes#Vec2. + @param #COORDINATE self + @param Dcs.DCSTypes#Vec2 Vec2Reference The reference DCSTypes#Vec2. + @return Dcs.DCSTypes#Distance The distance from the reference DCSTypes#Vec2 in meters.

    +

    Parameter

    • -

      RootMenu :

      +

      Vec2Reference :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:Explosion(ExplosionIntensity) + +
    +
    + +

    Creates an explosion at the point of a certain intensity.

    + +

    Parameter

    +
      +
    • + +

      #number ExplosionIntensity :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:Flare(FlareColor, (, Azimuth) + +
    +
    + +

    Flares the point in a color.

    + +

    Parameters

    + +
    +
    +
    +
    + + +COORDINATE:FlareGreen((, Azimuth) + +
    +
    + +

    Flare the COORDINATE Green.

    + +

    Parameters

    +
      +
    • + +

      Dcs.DCSTypes#Azimuth ( : +ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0.

      + +
    • +
    • + +

      Azimuth :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:FlareRed(Azimuth) + +
    +
    + +

    Flare the COORDINATE Red.

    + +

    Parameter

    +
      +
    • + +

      Azimuth :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:FlareWhite((, Azimuth) + +
    +
    + +

    Flare the COORDINATE White.

    + +

    Parameters

    +
      +
    • + +

      Dcs.DCSTypes#Azimuth ( : +ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0.

      + +
    • +
    • + +

      Azimuth :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:FlareYellow((, Azimuth) + +
    +
    + +

    Flare the COORDINATE Yellow.

    + +

    Parameters

    +
      +
    • + +

      Dcs.DCSTypes#Azimuth ( : +ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0.

      + +
    • +
    • + +

      Azimuth :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:Get2DDistance(TargetCoordinate) + +
    +
    + +

    Return the 2D distance in meters between the target COORDINATE and the COORDINATE.

    + +

    Parameter

    +
      +
    • + +

      #COORDINATE TargetCoordinate : +The target COORDINATE.

      + +
    • +
    +

    Return value

    + +

    Dcs.DCSTypes#Distance: +Distance The distance in meters.

    + +
    +
    +
    +
    + + +COORDINATE:Get3DDistance(TargetCoordinate) + +
    +
    + +

    Return the 3D distance in meters between the target COORDINATE and the COORDINATE.

    + +

    Parameter

    +
      +
    • + +

      #COORDINATE TargetCoordinate : +The target COORDINATE.

      + +
    • +
    +

    Return value

    + +

    Dcs.DCSTypes#Distance: +Distance The distance in meters.

    + +
    +
    +
    +
    + + +COORDINATE:GetAltitudeText(Settings) + +
    +
    + +

    Return the altitude text of the COORDINATE.

    + +

    Parameter

    +
      +
    • + +

      Settings :

    Return value

    #string: -The coordinate Text in the configured coordinate system.

    +Altitude text.

    - #number - -COORDINATE.LL_Accuracy + +COORDINATE:GetAngleDegrees(DirectionVec3)
    - - -
    -
    -
    -
    - - #boolean - -COORDINATE.LL_DMS - -
    -
    - - - -
    -
    -
    -
    - - #number - -COORDINATE.MGRS_Accuracy - -
    -
    - - - -
    -
    -
    -
    - - -COORDINATE:MenuLL_Accuracy(LL_Accuracy) - -
    -
    - - +

    Return an angle in degrees from the COORDINATE using a direction vector in Vec3 format.

    Parameter

    • -

      LL_Accuracy :

      +

      Dcs.DCSTypes#Vec3 DirectionVec3 : +The direction vector in Vec3 format.

    +

    Return value

    + +

    #number: +DirectionRadians The angle in degrees.

    +
    - -COORDINATE:MenuLL_DMS(LL_DMS) + +COORDINATE:GetAngleRadians(DirectionVec3) + +
    +
    + +

    Return an angle in radians from the COORDINATE using a direction vector in Vec3 format.

    + +

    Parameter

    + +

    Return value

    + +

    #number: +DirectionRadians The angle in radians.

    + +
    +
    +
    +
    + + +COORDINATE:GetBRAText(AngleRadians, Distance, Settings) + +
    +
    + +

    Provides a Bearing / Range / Altitude string

    + +

    Parameters

    +
      +
    • + +

      #number AngleRadians : +The angle in randians

      + +
    • +
    • + +

      #number Distance : +The distance

      + +
    • +
    • + +

      Core.Settings#SETTINGS Settings :

      + +
    • +
    +

    Return value

    + +

    #string: +The BRA Text

    + +
    +
    +
    +
    + + +COORDINATE:GetBRText(AngleRadians, Distance, Settings) + +
    +
    + +

    Provides a Bearing / Range string

    + +

    Parameters

    +
      +
    • + +

      #number AngleRadians : +The angle in randians

      + +
    • +
    • + +

      #number Distance : +The distance

      + +
    • +
    • + +

      Core.Settings#SETTINGS Settings :

      + +
    • +
    +

    Return value

    + +

    #string: +The BR Text

    + +
    +
    +
    +
    + + +COORDINATE:GetBearingText(AngleRadians, Precision, Settings) + +
    +
    + +

    Provides a bearing text in degrees.

    + +

    Parameters

    +
      +
    • + +

      #number AngleRadians : +The angle in randians.

      + +
    • +
    • + +

      #number Precision : +The precision.

      + +
    • +
    • + +

      Core.Settings#SETTINGS Settings :

      + +
    • +
    +

    Return value

    + +

    #string: +The bearing text in degrees.

    + +
    +
    +
    +
    + + +COORDINATE:GetDirectionVec3(TargetCoordinate) + +
    +
    + +

    Return a direction vector Vec3 from COORDINATE to the COORDINATE.

    + +

    Parameter

    +
      +
    • + +

      #COORDINATE TargetCoordinate : +The target COORDINATE.

      + +
    • +
    +

    Return value

    + +

    Dcs.DCSTypes#Vec3: +DirectionVec3 The direction vector in Vec3 format.

    + +
    +
    +
    +
    + + +COORDINATE:GetDistanceText(Distance, Settings) + +
    +
    + +

    Provides a distance text expressed in the units of measurement.

    + +

    Parameters

    + +

    Return value

    + +

    #string: +The distance text expressed in the units of measurement.

    + +
    +
    +
    +
    + + +COORDINATE:GetNorthCorrectionRadians() + +
    +
    + +

    Get a correction in radians of the real magnetic north of the COORDINATE.

    + +

    Return value

    + +

    #number: +CorrectionRadians The correction in radians.

    + +
    +
    +
    +
    + + +COORDINATE:GetRandomVec2InRadius(OuterRadius, InnerRadius) + +
    +
    + +

    Return a random Vec2 within an Outer Radius and optionally NOT within an Inner Radius of the COORDINATE.

    + +

    Parameters

    + +

    Return value

    + +

    Dcs.DCSTypes#Vec2: +Vec2

    + +
    +
    +
    +
    + + +COORDINATE:GetRandomVec3InRadius(OuterRadius, InnerRadius) + +
    +
    + +

    Return a random Vec3 within an Outer Radius and optionally NOT within an Inner Radius of the COORDINATE.

    + +

    Parameters

    + +

    Return value

    + +

    Dcs.DCSTypes#Vec3: +Vec3

    + +
    +
    +
    +
    + + +COORDINATE:GetVec2() + +
    +
    + +

    Return the coordinates of the COORDINATE in Vec2 format.

    + +

    Return value

    + +

    Dcs.DCSTypes#Vec2: +The Vec2 format coordinate.

    + +
    +
    +
    +
    + + +COORDINATE:GetVec3() + +
    +
    + +

    Return the coordinates of the COORDINATE in Vec3 format.

    + +

    Return value

    + +

    Dcs.DCSTypes#Vec3: +The Vec3 format coordinate.

    + +
    +
    +
    +
    + + +COORDINATE:IlluminationBomb() + +
    +
    + +

    Creates an illumination bomb at the point.

    + +
    +
    +
    +
    + + +COORDINATE:IsLOS(ToCoordinate) + +
    +
    + +

    Returns if a Coordinate has Line of Sight (LOS) with the ToCoordinate.

    + +

    Parameter

    + +

    Return value

    + +

    #boolean: +true If the ToCoordinate has LOS with the Coordinate, otherwise false.

    + +
    +
    +
    +
    + + +COORDINATE:IsModeA2A() + +
    +
    + +

    Is the mode to A2A

    + +

    Return value

    + +

    #boolean:

    + + +
    +
    +
    +
    + + +COORDINATE:IsModeA2G() + +
    +
    + +

    Is the mode to A2G

    + +

    Return value

    + +

    #boolean:

    + + +
    +
    +
    +
    + + #string + +COORDINATE.Mode
    -

    Parameter

    -
      -
    • - -

      LL_DMS :

      - -
    • -
    -
    -
    -
    -
    - - -COORDINATE:MenuMGRS_Accuracy(MGRS_Accuracy) - -
    -
    - - - -

    Parameter

    -
      -
    • - -

      MGRS_Accuracy :

      - -
    • -
    -
    -
    -
    -
    - - -COORDINATE:MenuSystem(System) - -
    -
    - - - -

    Parameter

    -
      -
    • - -

      System :

      - -
    • -
    -COORDINATE:New(x, y, LandHeightAdd) +COORDINATE:New(x, y, z)
    @@ -1235,8 +1777,8 @@ The y coordinate of the Vec3 point, pointing to the Right.

  • -

    Dcs.DCSTypes#Distance LandHeightAdd : -(optional) The default height if required to be evaluated will be the land height of the x, y coordinate. You can specify an extra height to be added to the land height.

    +

    Dcs.DCSTypes#Distance z : +The z coordinate of the Vec3 point, pointing to the Right.

  • @@ -1275,8 +1817,8 @@ The Vec2 point.

    Return value

    -

    Core.Point#COORDINATE: -self

    +

    Core.Point#COORDINATE:

    +
    @@ -1302,21 +1844,7 @@ The Vec3 point.

    Return value

    -

    Core.Point#COORDINATE: -self

    - - -
    -
    -
    - - #string - -COORDINATE.System - -
    -
    - +

    Core.Point#COORDINATE:

    @@ -1324,21 +1852,235 @@ self

    - -COORDINATE.SystemMenu + +COORDINATE:RoutePointAir(AltType, Type, Action, Speed, SpeedLocked) + +
    +
    + +

    Build an air type route point.

    + +

    Parameters

    + +

    Return value

    + +

    #table: +The route point.

    + +
    +
    +
    +
    + + +COORDINATE:RoutePointGround(Speed, Formation) + +
    +
    + +

    Build an ground type route point.

    + +

    Parameters

    + +

    Return value

    + +

    #table: +The route point.

    + +
    +
    +
    +
    + + +COORDINATE:SetHeading(Heading)
    +

    Parameter

    +
      +
    • + +

      Heading :

      + +
    • +
    +
    +
    +
    +
    + + +COORDINATE:SetModeA2A() + +
    +
    + +

    Set the mode to A2A

    + +

    Return value

    + +

    #COORDINATE:

    + + +
    +
    +
    +
    + + +COORDINATE:SetModeA2G() + +
    +
    + +

    Set the mode to A2G

    + +

    Return value

    + +

    #COORDINATE:

    + + +
    +
    +
    +
    + + +COORDINATE:Smoke(SmokeColor) + +
    +
    + +

    Smokes the point in a color.

    + +

    Parameter

    + +
    +
    +
    +
    + + +COORDINATE:SmokeBlue() + +
    +
    + +

    Smoke the COORDINATE Blue.

    + +
    +
    +
    +
    + + +COORDINATE:SmokeGreen() + +
    +
    + +

    Smoke the COORDINATE Green.

    + +
    +
    +
    +
    + + +COORDINATE:SmokeOrange() + +
    +
    + +

    Smoke the COORDINATE Orange.

    + +
    +
    +
    +
    + + +COORDINATE:SmokeRed() + +
    +
    + +

    Smoke the COORDINATE Red.

    + +
    +
    +
    +
    + + +COORDINATE:SmokeWhite() + +
    +
    + +

    Smoke the COORDINATE White.

    +
    -COORDINATE:ToString() +COORDINATE:ToString(Controllable, Settings)
    @@ -1351,7 +2093,19 @@ self

  • Can be overridden if for a GROUP containing x clients, a menu was selected to override the default.
  • +

    Parameters

    +

    Return value

    #string: @@ -1362,26 +2116,153 @@ The coordinate Text in the configured coordinate system.

    + +COORDINATE:ToStringAspect(TargetCoordinate) + +
    +
    + +

    Return an aspect string from a COORDINATE to the Angle of the object.

    + +

    Parameter

    +
      +
    • + +

      #COORDINATE TargetCoordinate : +The target COORDINATE.

      + +
    • +
    +

    Return value

    + +

    #string: +The Aspect string, which is Hot, Cold or Flanking.

    + +
    +
    +
    +
    + + +COORDINATE:ToStringBR(TargetCoordinate, FromCoordinate, Settings) + +
    +
    + +

    Return a BR string from a COORDINATE to the COORDINATE.

    + +

    Parameters

    +
      +
    • + +

      #COORDINATE TargetCoordinate : +The target COORDINATE.

      + +
    • +
    • + +

      FromCoordinate :

      + +
    • +
    • + +

      Settings :

      + +
    • +
    +

    Return value

    + +

    #string: +The BR text.

    + +
    +
    +
    +
    + + +COORDINATE:ToStringBRA(TargetCoordinate, FromCoordinate, Settings) + +
    +
    + +

    Return a BRAA string from a COORDINATE to the COORDINATE.

    + +

    Parameters

    +
      +
    • + +

      #COORDINATE TargetCoordinate : +The target COORDINATE.

      + +
    • +
    • + +

      FromCoordinate :

      + +
    • +
    • + +

      Settings :

      + +
    • +
    +

    Return value

    + +

    #string: +The BR text.

    + +
    +
    +
    +
    + + +COORDINATE:ToStringBULLS(Coalition, Settings) + +
    +
    + +

    Return a BULLS string from a COORDINATE to the BULLS of the coalition.

    + +

    Parameters

    + +

    Return value

    + +

    #string: +The BR text.

    + +
    +
    +
    +
    + -COORDINATE:ToStringLL(LL_Accuracy, LL_DMS) +COORDINATE:ToStringLL(Settings)

    Provides a Lat Lon string

    -

    Parameters

    +

    Parameter

    • -

      #number LL_Accuracy : -The accurancy of significant numbers behind the comma... So Accurancy of 2 is 0.01.

      - -
    • -
    • - -

      #boolean LL_DMS : -true = Degrees, Minutes, Seconds; false = Degrees, Minutes

      +

      Core.Settings#SETTINGS Settings : +(optional) Settings

    @@ -1396,7 +2277,7 @@ The LL Text

    -COORDINATE:ToStringMGRS(MGRS_Accuracy) +COORDINATE:ToStringMGRS(Settings)
    @@ -1407,14 +2288,8 @@ The LL Text

    • -

      #number MGRS_Accuracy : -of the 5 digit code. -Precision depends on the Accuracy choosen: - * 0 = no digits - precision level 100 km - * 1 = 1 digits - precision level 10 km - * 2 = 2 digits - precision level 1 km - * 3 = 3 digits - precision level 100 m - * 4 = 4 digits - precision level 10 m.

      +

      Core.Settings#SETTINGS Settings : +(optional) Settings

    @@ -1425,7 +2300,88 @@ The MGRS Text

    +
    +
    + +COORDINATE:Translate(Distance, Angle) + +
    +
    + +

    Add a Distance in meters from the COORDINATE orthonormal plane, with the given angle, and calculate the new COORDINATE.

    + +

    Parameters

    + +

    Return value

    + +

    #COORDINATE: +The new calculated COORDINATE.

    + +
    +
    +
    +
    + + + +COORDINATE.x + +
    +
    + + + +
    +
    +
    +
    + + + +COORDINATE.y + +
    +
    + + + +
    +
    +
    +
    + + + +COORDINATE.z + +
    +
    + + + +
    +
    + +

    Type COORDINATE.RoutePointAction

    + +

    Type COORDINATE.RoutePointAltType

    + +

    Type COORDINATE.RoutePointType

    +

    Type POINT_VEC2

    Field(s)

    @@ -1518,49 +2474,23 @@ The y coordinate.

    -

    Calculate the distance from a reference #POINT_VEC2.

    -

    Parameter

    - -

    Return value

    - -

    Dcs.DCSTypes#Distance: -The distance from the reference #POINT_VEC2 in meters.

    - -
    -
    -
    -
    - - -POINT_VEC2:DistanceFromVec2(Vec2Reference) - -
    -
    -

    Calculate the distance from a reference DCSTypes#Vec2.

    +

    TODO: Check this to replace +- Calculate the distance from a reference #POINT_VEC2. + @param #POINTVEC2 self + @param #POINTVEC2 PointVec2Reference The reference #POINT_VEC2. + @return Dcs.DCSTypes#Distance The distance from the reference #POINT_VEC2 in meters.

    Parameter

    -

    Return value

    - -

    Dcs.DCSTypes#Distance: -The distance from the reference DCSTypes#Vec2 in meters.

    -
    @@ -1584,24 +2514,6 @@ The land altitude.

    - -POINT_VEC2:GetAltitudeText() - -
    -
    - -

    Return no text for the altitude of the POINT_VEC2.

    - -

    Return value

    - -

    #string: -Empty string.

    - -
    -
    -
    -
    - POINT_VEC2:GetLat() @@ -1633,6 +2545,37 @@ The x coodinate.

    #number: The y coodinate.

    + +
    +
    +
    + + +POINT_VEC2:GetRandomPointVec2InRadius(OuterRadius, InnerRadius) + +
    +
    + +

    Return a random POINTVEC2 within an Outer Radius and optionally NOT within an Inner Radius of the POINTVEC2.

    + +

    Parameters

    + +

    Return value

    + +

    #POINT_VEC2:

    + +
    @@ -1907,39 +2850,6 @@ The y coordinate.

    #POINT_VEC2:

    - -
    -
    -
    - - -POINT_VEC2:Translate(Distance, Angle) - -
    -
    - -

    Add a Distance in meters from the POINTVEC2 orthonormal plane, with the given angle, and calculate the new POINTVEC2.

    - -

    Parameters

    - -

    Return value

    - -

    #POINT_VEC2: -The new calculated POINT_VEC2.

    -
    @@ -1973,7 +2883,6 @@ The new calculated POINT_VEC2.

    - POINT_VEC2.z @@ -2069,59 +2978,6 @@ The z coordinate value to add to the current z coodinate.

    #POINT_VEC3:

    - -
    -
    -
    - - -POINT_VEC3:Explosion(ExplosionIntensity) - -
    -
    - -

    Creates an explosion at the point of a certain intensity.

    - -

    Parameter

    -
      -
    • - -

      #number ExplosionIntensity :

      - -
    • -
    -
    -
    -
    -
    - - -POINT_VEC3:Flare(FlareColor, (, Azimuth) - -
    -
    - -

    Flares the point in a color.

    - -

    Parameters

    -
    @@ -2136,337 +2992,6 @@ ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0. -
    -
    -
    - - -POINT_VEC3:FlareGreen((, Azimuth) - -
    -
    - -

    Flare the POINT_VEC3 Green.

    - -

    Parameters

    -
      -
    • - -

      Dcs.DCSTypes#Azimuth ( : -ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0.

      - -
    • -
    • - -

      Azimuth :

      - -
    • -
    -
    -
    -
    -
    - - -POINT_VEC3:FlareRed(Azimuth) - -
    -
    - -

    Flare the POINT_VEC3 Red.

    - -

    Parameter

    -
      -
    • - -

      Azimuth :

      - -
    • -
    -
    -
    -
    -
    - - -POINT_VEC3:FlareWhite((, Azimuth) - -
    -
    - -

    Flare the POINT_VEC3 White.

    - -

    Parameters

    -
      -
    • - -

      Dcs.DCSTypes#Azimuth ( : -ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0.

      - -
    • -
    • - -

      Azimuth :

      - -
    • -
    -
    -
    -
    -
    - - -POINT_VEC3:FlareYellow((, Azimuth) - -
    -
    - -

    Flare the POINT_VEC3 Yellow.

    - -

    Parameters

    -
      -
    • - -

      Dcs.DCSTypes#Azimuth ( : -ptional) Azimuth The azimuth of the flare direction. The default azimuth is 0.

      - -
    • -
    • - -

      Azimuth :

      - -
    • -
    -
    -
    -
    -
    - - -POINT_VEC3:Get2DDistance(TargetPointVec3) - -
    -
    - -

    Return the 2D distance in meters between the target POINTVEC3 and the POINTVEC3.

    - -

    Parameter

    -
      -
    • - -

      #POINT_VEC3 TargetPointVec3 : -The target POINT_VEC3.

      - -
    • -
    -

    Return value

    - -

    Dcs.DCSTypes#Distance: -Distance The distance in meters.

    - -
    -
    -
    -
    - - -POINT_VEC3:Get3DDistance(TargetPointVec3) - -
    -
    - -

    Return the 3D distance in meters between the target POINTVEC3 and the POINTVEC3.

    - -

    Parameter

    -
      -
    • - -

      #POINT_VEC3 TargetPointVec3 : -The target POINT_VEC3.

      - -
    • -
    -

    Return value

    - -

    Dcs.DCSTypes#Distance: -Distance The distance in meters.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetAltitudeText() - -
    -
    - -

    Return the altitude text of the POINT_VEC3.

    - -

    Return value

    - -

    #string: -Altitude text.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetAngleDegrees(DirectionVec3) - -
    -
    - -

    Return an angle in degrees from the POINT_VEC3 using a direction vector in Vec3 format.

    - -

    Parameter

    - -

    Return value

    - -

    #number: -DirectionRadians The angle in degrees.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetAngleRadians(DirectionVec3) - -
    -
    - -

    Return an angle in radians from the POINT_VEC3 using a direction vector in Vec3 format.

    - -

    Parameter

    - -

    Return value

    - -

    #number: -DirectionRadians The angle in radians.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetBRText(TargetPointVec3) - -
    -
    - -

    Return a BR string from a POINTVEC3 to the POINTVEC3.

    - -

    Parameter

    -
      -
    • - -

      #POINT_VEC3 TargetPointVec3 : -The target POINT_VEC3.

      - -
    • -
    -

    Return value

    - -

    #string: -The BR text.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetDirectionVec3(TargetPointVec3) - -
    -
    - -

    Return a direction vector Vec3 from POINTVEC3 to the POINTVEC3.

    - -

    Parameter

    -
      -
    • - -

      #POINT_VEC3 TargetPointVec3 : -The target POINT_VEC3.

      - -
    • -
    -

    Return value

    - -

    Dcs.DCSTypes#Vec3: -DirectionVec3 The direction vector in Vec3 format.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetNorthCorrectionRadians() - -
    -
    - -

    Get a correction in radians of the real magnetic north of the POINT_VEC3.

    - -

    Return value

    - -

    #number: -CorrectionRadians The correction in radians.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetRandomPointVec2InRadius(OuterRadius, InnerRadius) - -
    -
    - -

    Return a random POINTVEC2 within an Outer Radius and optionally NOT within an Inner Radius of the POINTVEC3.

    - -

    Parameters

    - -

    Return value

    - -

    #POINT_VEC2:

    - -
    @@ -2498,104 +3023,6 @@ CorrectionRadians The correction in radians.

    #POINT_VEC3:

    - -
    -
    -
    - - -POINT_VEC3:GetRandomVec2InRadius(OuterRadius, InnerRadius) - -
    -
    - -

    Return a random Vec2 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC3.

    - -

    Parameters

    - -

    Return value

    - -

    Dcs.DCSTypes#Vec2: -Vec2

    - -
    -
    -
    -
    - - -POINT_VEC3:GetRandomVec3InRadius(OuterRadius, InnerRadius) - -
    -
    - -

    Return a random Vec3 within an Outer Radius and optionally NOT within an Inner Radius of the POINT_VEC3.

    - -

    Parameters

    - -

    Return value

    - -

    Dcs.DCSTypes#Vec3: -Vec3

    - -
    -
    -
    -
    - - -POINT_VEC3:GetVec2() - -
    -
    - -

    Return the coordinates of the POINT_VEC3 in Vec2 format.

    - -

    Return value

    - -

    Dcs.DCSTypes#Vec2: -The Vec2 coodinate.

    - -
    -
    -
    -
    - - -POINT_VEC3:GetVec3() - -
    -
    - -

    Return the coordinates of the POINT_VEC3 in Vec3 format.

    - -

    Return value

    - -

    Dcs.DCSTypes#Vec3: -The Vec3 coodinate.

    -
    @@ -2650,77 +3077,6 @@ The y coodinate.

    #number: The z coodinate.

    - -
    -
    -
    - - -POINT_VEC3:IlluminationBomb() - -
    -
    - -

    Creates an illumination bomb at the point.

    - -
    -
    -
    -
    - - -POINT_VEC3:IsLOS(ToPointVec3) - -
    -
    - -

    Returns if a PointVec3 has Line of Sight (LOS) with the ToPointVec3.

    - -

    Parameter

    - -

    Return value

    - -

    #boolean: -true If the ToPointVec3 has LOS with the PointVec3, otherwise false.

    - -
    -
    -
    -
    - - -POINT_VEC3:IsMetric() - -
    -
    - -

    Gets if the POINT_VEC3 is metric or NM.

    - -

    Return value

    - -

    #boolean: -Metric true means metric, false means NM.

    - -
    -
    -
    -
    - - - -POINT_VEC3.Metric - -
    -
    - - -
    @@ -2757,8 +3113,8 @@ The z coordinate of the Vec3 point, pointing to the Right.

    Return value

    -

    Core.Point#POINT_VEC3: -self

    +

    Core.Point#POINT_VEC3:

    +
    @@ -2783,7 +3139,8 @@ The Vec2 point.

  • -

    LandHeightAdd :

    +

    Dcs.DCSTypes#Distance LandHeightAdd : +(optional) Add a landheight.

  • @@ -2833,57 +3190,6 @@ self

    - -
    -
    -
    - - -POINT_VEC3:RoutePointAir(AltType, Type, Action, Speed, SpeedLocked) - -
    -
    - -

    Build an air type route point.

    - -

    Parameters

    - -

    Return value

    - -

    #table: -The route point.

    -
    @@ -2898,39 +3204,6 @@ The route point.

    - -
    -
    -
    - - -POINT_VEC3:RoutePointGround(Speed, Formation) - -
    -
    - -

    Build an ground type route point.

    - -

    Parameters

    - -

    Return value

    - -

    #table: -The route point.

    -
    @@ -2945,28 +3218,6 @@ The route point.

    - -
    -
    -
    - - -POINT_VEC3:SetMetric(Metric) - -
    -
    - -

    Sets the POINT_VEC3 metric or NM.

    - -

    Parameter

    -
      -
    • - -

      #boolean Metric : -true means metric, false means NM.

      - -
    • -
    @@ -3048,40 +3299,6 @@ The z coordinate.

    #POINT_VEC3:

    - -
    -
    -
    - - -POINT_VEC3:Smoke(SmokeColor) - -
    -
    - -

    Smokes the point in a color.

    - -

    Parameter

    - -
    -
    -
    -
    - - -POINT_VEC3:SmokeBlue() - -
    -
    - -

    Smoke the POINT_VEC3 Blue.

    -
    @@ -3096,124 +3313,6 @@ The z coordinate.

    - -
    -
    -
    - - -POINT_VEC3:SmokeGreen() - -
    -
    - -

    Smoke the POINT_VEC3 Green.

    - -
    -
    -
    -
    - - -POINT_VEC3:SmokeOrange() - -
    -
    - -

    Smoke the POINT_VEC3 Orange.

    - -
    -
    -
    -
    - - -POINT_VEC3:SmokeRed() - -
    -
    - -

    Smoke the POINT_VEC3 Red.

    - -
    -
    -
    -
    - - -POINT_VEC3:SmokeWhite() - -
    -
    - -

    Smoke the POINT_VEC3 White.

    - -
    -
    -
    -
    - - -POINT_VEC3:ToStringBR(AngleRadians, Distance) - -
    -
    - -

    Provides a Bearing / Range string

    - -

    Parameters

    -
      -
    • - -

      #number AngleRadians : -The angle in randians

      - -
    • -
    • - -

      #number Distance : -The distance

      - -
    • -
    -

    Return value

    - -

    #string: -The BR Text

    - -
    -
    -
    -
    - - -POINT_VEC3:Translate(Distance, Angle) - -
    -
    - -

    Add a Distance in meters from the POINTVEC3 horizontal plane, with the given angle, and calculate the new POINTVEC3.

    - -

    Parameters

    - -

    Return value

    - -

    #POINT_VEC3: -The new calculated POINT_VEC3.

    -
    diff --git a/docs/Documentation/Positionable.html b/docs/Documentation/Positionable.html index e9d8defe0..26999f404 100644 --- a/docs/Documentation/Positionable.html +++ b/docs/Documentation/Positionable.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Process_JTAC.html b/docs/Documentation/Process_JTAC.html index 1dbc2c736..be64e486d 100644 --- a/docs/Documentation/Process_JTAC.html +++ b/docs/Documentation/Process_JTAC.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Process_Pickup.html b/docs/Documentation/Process_Pickup.html index 2a3293148..4b57e65f0 100644 --- a/docs/Documentation/Process_Pickup.html +++ b/docs/Documentation/Process_Pickup.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Radio.html b/docs/Documentation/Radio.html index 540e4f3b5..93a2ea611 100644 --- a/docs/Documentation/Radio.html +++ b/docs/Documentation/Radio.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Route.html b/docs/Documentation/Route.html index 324486bf7..70f8fc1d6 100644 --- a/docs/Documentation/Route.html +++ b/docs/Documentation/Route.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -210,12 +213,30 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil ACT_ROUTE.ClassName + + + + ACT_ROUTE.Coordinate + + ACT_ROUTE.DisplayCount + + + + ACT_ROUTE:GetRouteText(Controllable) + +

    Get the routing text to be displayed.

    + + + + ACT_ROUTE:MenuCancel() + + @@ -228,6 +249,24 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil ACT_ROUTE.ProcessUnit + + + + ACT_ROUTE.RouteMode + + + + + + ACT_ROUTE:SetMenuCancel(MenuGroup, MenuText, ParentMenu, MenuTime) + +

    Set a Cancel Menu item.

    + + + + ACT_ROUTE:SetRouteMode(RouteMode) + +

    Set the route mode.

    @@ -268,6 +307,12 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil ACT_ROUTE_POINT.ClassName + + + + ACT_ROUTE_POINT.Coordinate + + @@ -295,33 +340,27 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil - ACT_ROUTE_POINT:GetPointVec2() + ACT_ROUTE_POINT:GetCoordinate() -

    Get PointVec2

    +

    Get Coordinate

    ACT_ROUTE_POINT:GetRange() -

    Get Range around PointVec2

    +

    Get Range around Coordinate

    ACT_ROUTE_POINT:Init(FsmRoute) - - - - - ACT_ROUTE_POINT:New(The, Range, Zone, PointVec2) -

    Creates a new routing state machine.

    - ACT_ROUTE_POINT.PointVec2 + ACT_ROUTE_POINT:New(The, Range, Zone, Coordinate) - +

    Creates a new routing state machine.

    @@ -331,15 +370,15 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil - ACT_ROUTE_POINT:SetPointVec2(PointVec2) + ACT_ROUTE_POINT:SetCoordinate(Coordinate) -

    Set PointVec2

    +

    Set Coordinate

    ACT_ROUTE_POINT:SetRange(Range) -

    Set Range around PointVec2

    +

    Set Range around Coordinate

    @@ -349,7 +388,7 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil - ACT_ROUTE_POINT:onenterReporting(ProcessUnit, Event, From, To) + ACT_ROUTE_POINT:onafterReport(ProcessUnit, Event, From, To)

    StateMachine callback function

    @@ -365,6 +404,12 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil

    Type ACT_ROUTE_ZONE

    + + + + + + + + @@ -419,7 +470,7 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil - + @@ -437,7 +488,7 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil - + @@ -512,6 +563,20 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil + + +
    +
    + + Core.Point#COORDINATE + +ACT_ROUTE.Coordinate + +
    +
    + + +
    @@ -526,6 +591,48 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil + +
    +
    +
    + + +ACT_ROUTE:GetRouteText(Controllable) + +
    +
    + +

    Get the routing text to be displayed.

    + + +

    The route mode determines the text displayed.

    + +

    Parameter

    + +

    Return value

    + +

    #string:

    + + +
    +
    +
    +
    + + +ACT_ROUTE:MenuCancel() + +
    +
    + + +
    @@ -561,6 +668,96 @@ self

    + +
    +
    +
    + + + +ACT_ROUTE.RouteMode + +
    +
    + + + +
    +
    +
    +
    + + +ACT_ROUTE:SetMenuCancel(MenuGroup, MenuText, ParentMenu, MenuTime) + +
    +
    + +

    Set a Cancel Menu item.

    + +

    Parameters

    +
      +
    • + +

      MenuGroup :

      + +
    • +
    • + +

      MenuText :

      + +
    • +
    • + +

      ParentMenu :

      + +
    • +
    • + +

      MenuTime :

      + +
    • +
    +

    Return value

    + +

    #ACT_ROUTE:

    + + +
    +
    +
    +
    + + +ACT_ROUTE:SetRouteMode(RouteMode) + +
    +
    + +

    Set the route mode.

    + + +

    There are 2 route modes supported:

    + +
      +
    • SetRouteMode( "B" ): Route mode is Bearing and Range.
    • +
    • SetRouteMode( "C" ): Route mode is LL or MGRS according coordinate system setup.
    • +
    + + +

    Parameter

    +
      +
    • + +

      RouteMode :

      + +
    • +
    +

    Return value

    + +

    #ACT_ROUTE:

    + +
    @@ -707,6 +904,20 @@ self

    + +
    +
    +
    + + + +ACT_ROUTE_POINT.Coordinate + +
    +
    + + +
    @@ -771,18 +982,18 @@ self

    - -ACT_ROUTE_POINT:GetPointVec2() + +ACT_ROUTE_POINT:GetCoordinate()
    -

    Get PointVec2

    +

    Get Coordinate

    Return value

    -

    Core.Point#POINT_VEC2: -PointVec2 The PointVec2 to route to.

    +

    Core.Point#COORDINATE: +Coordinate The Coordinate to route to.

    @@ -795,7 +1006,7 @@ PointVec2 The PointVec2 to route to.

    -

    Get Range around PointVec2

    +

    Get Range around Coordinate

    Return value

    @@ -813,7 +1024,10 @@ The Range to consider the arrival. Default is 10000 meters.

    +

    Creates a new routing state machine.

    + +

    The task will route a controllable to a Coordinate until the controllable is within the Range.

    Parameter

    -
    -
    - - - -ACT_ROUTE_POINT.PointVec2 - -
    -
    - - -
    @@ -896,20 +1096,20 @@ The Distance to Target.

    - -ACT_ROUTE_POINT:SetPointVec2(PointVec2) + +ACT_ROUTE_POINT:SetCoordinate(Coordinate)
    -

    Set PointVec2

    +

    Set Coordinate

    Parameter

    @@ -924,7 +1124,7 @@ The PointVec2 to route to.

    -

    Set Range around PointVec2

    +

    Set Range around Coordinate

    Parameter

    ACT_ROUTE_ZONE.Altitude + +
    ACT_ROUTE_ZONE.ClassName @@ -398,6 +443,12 @@ Upon arrival at the zone, a confirmation of arrival is sent, and the process wil ACT_ROUTE_ZONE:GetZone()

    Get Zone

    +
    ACT_ROUTE_ZONE.Heading +
    ACT_ROUTE_ZONE:SetZone(Zone)ACT_ROUTE_ZONE:SetZone(Zone, Altitude, Heading)

    Set Zone

    ACT_ROUTE_ZONE:onenterReporting(ProcessUnit, Event, From, To)ACT_ROUTE_ZONE:onafterReport(ProcessUnit, Event, From, To)

    StateMachine callback function

    + + + + +
    SETTINGS +

    SETTINGS class, extends Base#BASE

    + +
    +

    Type SETTINGS

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    SETTINGS:A2AMenuSystem(A2ASystem) + +
    SETTINGS.A2ASystem + +
    SETTINGS:A2GMenuSystem(A2GSystem) + +
    SETTINGS.A2GSystem + +
    SETTINGS.DefaultMenu + +
    SETTINGS:GetLL_Accuracy() +

    Gets the SETTINGS LL accuracy.

    +
    SETTINGS:GetLL_DMS() +

    Gets the SETTINGS LL DMS.

    +
    SETTINGS:GetMGRS_Accuracy() +

    Gets the SETTINGS MGRS accuracy.

    +
    SETTINGS:IsA2A_BRA() +

    Is BRA

    +
    SETTINGS:IsA2A_BULLS() +

    Is BULLS

    +
    SETTINGS:IsA2G_BRA() +

    Is BRA

    +
    SETTINGS:IsA2G_LL() +

    Is LL

    +
    SETTINGS:IsA2G_MGRS() +

    Is MGRS

    +
    SETTINGS:IsImperial() +

    Gets if the SETTINGS is imperial.

    +
    SETTINGS:IsMetric() +

    Gets if the SETTINGS is metric.

    +
    SETTINGS.LL_Accuracy + +
    SETTINGS.LL_DMS + +
    SETTINGS.MGRS_Accuracy + +
    SETTINGS:MenuGroupA2ASystem(PlayerUnit, PlayerGroup, PlayerName, A2ASystem) + +
    SETTINGS:MenuGroupA2GSystem(PlayerUnit, PlayerGroup, PlayerName, A2GSystem) + +
    SETTINGS:MenuGroupLL_AccuracySystem(PlayerUnit, PlayerGroup, PlayerName, LL_Accuracy) + +
    SETTINGS:MenuGroupLL_DMSSystem(PlayerUnit, PlayerGroup, PlayerName, LL_DMS) + +
    SETTINGS:MenuGroupMGRS_AccuracySystem(PlayerUnit, PlayerGroup, PlayerName, MGRS_Accuracy) + +
    SETTINGS:MenuGroupMWSystem(PlayerUnit, PlayerGroup, PlayerName, MW) + +
    SETTINGS:MenuLL_Accuracy(LL_Accuracy) + +
    SETTINGS:MenuLL_DMS(LL_DMS) + +
    SETTINGS:MenuMGRS_Accuracy(MGRS_Accuracy) + +
    SETTINGS:MenuMWSystem(MW) + +
    SETTINGS.MenuText + +
    SETTINGS.Metric + +
    SETTINGS.Metrics + +
    SETTINGS.PlayerMenu + +
    SETTINGS:RemovePlayerMenu(RootMenu, PlayerUnit) + +
    SETTINGS:Set(PlayerName) +

    SETTINGS constructor.

    +
    SETTINGS:SetA2A_BRA() +

    Sets A2A BRA

    +
    SETTINGS:SetA2A_BULLS() +

    Sets A2A BULLS

    +
    SETTINGS:SetA2G_BRA() +

    Sets A2G BRA

    +
    SETTINGS:SetA2G_LL() +

    Sets A2G LL

    +
    SETTINGS:SetA2G_MGRS() +

    Sets A2G MGRS

    +
    SETTINGS:SetImperial() +

    Sets the SETTINGS imperial.

    +
    SETTINGS:SetLL_Accuracy(LL_Accuracy) +

    Sets the SETTINGS LL accuracy.

    +
    SETTINGS:SetLL_DMS(LL_DMS) +

    Sets the SETTINGS LL DMS.

    +
    SETTINGS:SetMGRS_Accuracy(MGRS_Accuracy) +

    Sets the SETTINGS MGRS accuracy.

    +
    SETTINGS:SetMetric() +

    Sets the SETTINGS metric.

    +
    SETTINGS:SetPlayerMenu(RootMenu, PlayerUnit, MenuText) + +
    SETTINGS:SetSystemMenu(RootMenu, MenuText) + +
    SETTINGS.SettingsMenu + +
    + +

    Global(s)

    +
    +
    + + #SETTINGS + +SETTINGS + +
    +
    + +

    SETTINGS class, extends Base#BASE

    + + +
    +
    +

    Type Settings

    + +

    Type SETTINGS

    +

    Field(s)

    +
    +
    + + +SETTINGS:A2AMenuSystem(A2ASystem) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      A2ASystem :

      + +
    • +
    +
    +
    +
    +
    + + #string + +SETTINGS.A2ASystem + +
    +
    + + + +
    +
    +
    +
    + + +SETTINGS:A2GMenuSystem(A2GSystem) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      A2GSystem :

      + +
    • +
    +
    +
    +
    +
    + + #string + +SETTINGS.A2GSystem + +
    +
    + + + +
    +
    +
    +
    + + +SETTINGS.DefaultMenu + +
    +
    + + + +
    +
    +
    +
    + + +SETTINGS:GetLL_Accuracy() + +
    +
    + +

    Gets the SETTINGS LL accuracy.

    + +

    Return value

    + +

    #number:

    + + +
    +
    +
    +
    + + +SETTINGS:GetLL_DMS() + +
    +
    + +

    Gets the SETTINGS LL DMS.

    + +

    Return value

    + +

    #number:

    + + +
    +
    +
    +
    + + +SETTINGS:GetMGRS_Accuracy() + +
    +
    + +

    Gets the SETTINGS MGRS accuracy.

    + +

    Return value

    + +

    #number:

    + + +
    +
    +
    +
    + + +SETTINGS:IsA2A_BRA() + +
    +
    + +

    Is BRA

    + +

    Return value

    + +

    #boolean: +true if BRA

    + +
    +
    +
    +
    + + +SETTINGS:IsA2A_BULLS() + +
    +
    + +

    Is BULLS

    + +

    Return value

    + +

    #boolean: +true if BULLS

    + +
    +
    +
    +
    + + +SETTINGS:IsA2G_BRA() + +
    +
    + +

    Is BRA

    + +

    Return value

    + +

    #boolean: +true if BRA

    + +
    +
    +
    +
    + + +SETTINGS:IsA2G_LL() + +
    +
    + +

    Is LL

    + +

    Return value

    + +

    #boolean: +true if LL

    + +
    +
    +
    +
    + + +SETTINGS:IsA2G_MGRS() + +
    +
    + +

    Is MGRS

    + +

    Return value

    + +

    #boolean: +true if MGRS

    + +
    +
    +
    +
    + + +SETTINGS:IsImperial() + +
    +
    + +

    Gets if the SETTINGS is imperial.

    + +

    Return value

    + +

    #boolean: +true if imperial.

    + +
    +
    +
    +
    + + +SETTINGS:IsMetric() + +
    +
    + +

    Gets if the SETTINGS is metric.

    + +

    Return value

    + +

    #boolean: +true if metric.

    + +
    +
    +
    +
    + + #number + +SETTINGS.LL_Accuracy + +
    +
    + + + +
    +
    +
    +
    + + #boolean + +SETTINGS.LL_DMS + +
    +
    + + + +
    +
    +
    +
    + + #number + +SETTINGS.MGRS_Accuracy + +
    +
    + + + +
    +
    +
    +
    + + +SETTINGS:MenuGroupA2ASystem(PlayerUnit, PlayerGroup, PlayerName, A2ASystem) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      PlayerUnit :

      + +
    • +
    • + +

      PlayerGroup :

      + +
    • +
    • + +

      PlayerName :

      + +
    • +
    • + +

      A2ASystem :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuGroupA2GSystem(PlayerUnit, PlayerGroup, PlayerName, A2GSystem) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      PlayerUnit :

      + +
    • +
    • + +

      PlayerGroup :

      + +
    • +
    • + +

      PlayerName :

      + +
    • +
    • + +

      A2GSystem :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuGroupLL_AccuracySystem(PlayerUnit, PlayerGroup, PlayerName, LL_Accuracy) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      PlayerUnit :

      + +
    • +
    • + +

      PlayerGroup :

      + +
    • +
    • + +

      PlayerName :

      + +
    • +
    • + +

      LL_Accuracy :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuGroupLL_DMSSystem(PlayerUnit, PlayerGroup, PlayerName, LL_DMS) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      PlayerUnit :

      + +
    • +
    • + +

      PlayerGroup :

      + +
    • +
    • + +

      PlayerName :

      + +
    • +
    • + +

      LL_DMS :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuGroupMGRS_AccuracySystem(PlayerUnit, PlayerGroup, PlayerName, MGRS_Accuracy) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      PlayerUnit :

      + +
    • +
    • + +

      PlayerGroup :

      + +
    • +
    • + +

      PlayerName :

      + +
    • +
    • + +

      MGRS_Accuracy :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuGroupMWSystem(PlayerUnit, PlayerGroup, PlayerName, MW) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      PlayerUnit :

      + +
    • +
    • + +

      PlayerGroup :

      + +
    • +
    • + +

      PlayerName :

      + +
    • +
    • + +

      MW :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuLL_Accuracy(LL_Accuracy) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      LL_Accuracy :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuLL_DMS(LL_DMS) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      LL_DMS :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuMGRS_Accuracy(MGRS_Accuracy) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      MGRS_Accuracy :

      + +
    • +
    +
    +
    +
    +
    + + +SETTINGS:MenuMWSystem(MW) + +
    +
    + + + +

    Parameter

    +
      +
    • + +

      MW :

      + +
    • +
    +
    +
    +
    +
    + + + +SETTINGS.MenuText + +
    +
    + + + +
    +
    +
    +
    + + #boolean + +SETTINGS.Metric + +
    +
    + + + +
    +
    +
    +
    + + + +SETTINGS.Metrics + +
    +
    + + + +
    +
    +
    +
    + + + +SETTINGS.PlayerMenu + +
    +
    + + + +
    +
    +
    +
    + + +SETTINGS:RemovePlayerMenu(RootMenu, PlayerUnit) + +
    +
    + + + +

    Parameters

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:Set(PlayerName) + +
    +
    + +

    SETTINGS constructor.

    + +

    Parameter

    +
      +
    • + +

      PlayerName :

      + +
    • +
    +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetA2A_BRA() + +
    +
    + +

    Sets A2A BRA

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetA2A_BULLS() + +
    +
    + +

    Sets A2A BULLS

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetA2G_BRA() + +
    +
    + +

    Sets A2G BRA

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetA2G_LL() + +
    +
    + +

    Sets A2G LL

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetA2G_MGRS() + +
    +
    + +

    Sets A2G MGRS

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetImperial() + +
    +
    + +

    Sets the SETTINGS imperial.

    + +
    +
    +
    +
    + + +SETTINGS:SetLL_Accuracy(LL_Accuracy) + +
    +
    + +

    Sets the SETTINGS LL accuracy.

    + +

    Parameter

    +
      +
    • + +

      #number LL_Accuracy :

      + +
    • +
    +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetLL_DMS(LL_DMS) + +
    +
    + +

    Sets the SETTINGS LL DMS.

    + +

    Parameter

    +
      +
    • + +

      #number LL_DMS :

      + +
    • +
    +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetMGRS_Accuracy(MGRS_Accuracy) + +
    +
    + +

    Sets the SETTINGS MGRS accuracy.

    + +

    Parameter

    +
      +
    • + +

      #number MGRS_Accuracy :

      + +
    • +
    +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetMetric() + +
    +
    + +

    Sets the SETTINGS metric.

    + +
    +
    +
    +
    + + +SETTINGS:SetPlayerMenu(RootMenu, PlayerUnit, MenuText) + +
    +
    + + + +

    Parameters

    + +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + +SETTINGS:SetSystemMenu(RootMenu, MenuText) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      RootMenu :

      + +
    • +
    • + +

      MenuText :

      + +
    • +
    +

    Return value

    + +

    #SETTINGS:

    + + +
    +
    +
    +
    + + + +SETTINGS.SettingsMenu + +
    +
    + + + +
    +
    + + + + + + diff --git a/docs/Documentation/Smoke.html b/docs/Documentation/Smoke.html index f025f8ba8..b2f4e1d69 100644 --- a/docs/Documentation/Smoke.html +++ b/docs/Documentation/Smoke.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Spawn.html b/docs/Documentation/Spawn.html index 19d5a6d46..c96559421 100644 --- a/docs/Documentation/Spawn.html +++ b/docs/Documentation/Spawn.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -2529,6 +2532,9 @@ when nothing was spawned.

    + +

    Overwrite unit names by default with group name.

    +
    @@ -2543,9 +2549,6 @@ when nothing was spawned.

    - -

    By default, no InitLimit

    -
    @@ -2581,7 +2584,7 @@ when nothing was spawned.

    - #number + SPAWN.SpawnMaxGroups @@ -2598,7 +2601,7 @@ when nothing was spawned.

    - #number + SPAWN.SpawnMaxUnitsAlive diff --git a/docs/Documentation/SpawnStatic.html b/docs/Documentation/SpawnStatic.html index 50d544bd6..7e31f46d4 100644 --- a/docs/Documentation/SpawnStatic.html +++ b/docs/Documentation/SpawnStatic.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -446,7 +449,6 @@ ptional) The name of the new static.

    - #number SPAWNSTATIC.SpawnIndex diff --git a/docs/Documentation/Spot.html b/docs/Documentation/Spot.html index 5befab5b3..018cdd833 100644 --- a/docs/Documentation/Spot.html +++ b/docs/Documentation/Spot.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Static.html b/docs/Documentation/Static.html index fbd841089..25c4ef050 100644 --- a/docs/Documentation/Static.html +++ b/docs/Documentation/Static.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/StaticObject.html b/docs/Documentation/StaticObject.html index 1f1abe42f..0a048aa1e 100644 --- a/docs/Documentation/StaticObject.html +++ b/docs/Documentation/StaticObject.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • diff --git a/docs/Documentation/Task.html b/docs/Documentation/Task.html index ffd356b4b..37429004e 100644 --- a/docs/Documentation/Task.html +++ b/docs/Documentation/Task.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -453,13 +456,13 @@ - TASK:ReportDetails() + TASK:ReportDetails(TaskGroup)

    Create a detailed report of the Task.

    - TASK:ReportOverview() + TASK:ReportOverview(ReportGroup)

    Create an overiew report of the Task.

    @@ -2007,7 +2010,7 @@ self

    -TASK:ReportDetails() +TASK:ReportDetails(TaskGroup)
    @@ -2017,6 +2020,14 @@ self

    List the Task Status, and the Players assigned to the Task.

    +

    Parameter

    +

    Return value

    #string:

    @@ -2028,7 +2039,7 @@ self

    -TASK:ReportOverview() +TASK:ReportOverview(ReportGroup)
    @@ -2038,6 +2049,14 @@ self

    List the Task Name and Status

    +

    Parameter

    +
      +
    • + +

      ReportGroup :

      + +
    • +

    Return value

    #string:

    diff --git a/docs/Documentation/Task_A2A.html b/docs/Documentation/Task_A2A.html new file mode 100644 index 000000000..5a87f36ca --- /dev/null +++ b/docs/Documentation/Task_A2A.html @@ -0,0 +1,1012 @@ + + + + + + +
    +
    + +
    +
    +
    +
    + +
    +

    Module Task_A2A

    + +

    Tasking - The TASK_A2A models tasks for players in Air to Air engagements.

    + + + +

    Banner Image

    + + +

    1) TaskA2A#TASKA2A class, extends Task#TASK

    + +

    The #TASK_A2A class defines Air To Air tasks for a Set of Target Units, +based on the tasking capabilities defined in Task#TASK. +The TASK_A2A is implemented using a Statemachine#FSM_TASK, and has the following statuses:

    + +
      +
    • None: Start of the process
    • +
    • Planned: The A2A task is planned.
    • +
    • Assigned: The A2A task is assigned to a Group#GROUP.
    • +
    • Success: The A2A task is successfully completed.
    • +
    • Failed: The A2A task has failed. This will happen if the player exists the task early, without communicating a possible cancellation to HQ.
    • +
    + +

    1.1) Set the scoring of achievements in an A2A attack.

    + +

    Scoring or penalties can be given in the following circumstances:

    + + + +

    2) TaskA2A#TASKINTERCEPT class, extends TaskA2A#TASKA2A

    + +

    The TASKA2AINTERCEPT class defines an INTERCEPT task for a Set of Target Units.

    + +
    + +

    API CHANGE HISTORY

    + +

    The underlying change log documents the API changes. Please read this carefully. The following notation is used:

    + +
      +
    • Added parts are expressed in bold type face.
    • +
    • Removed parts are expressed in italic type face.
    • +
    + +

    Hereby the change log:

    + +
    + +

    AUTHORS and CONTRIBUTIONS

    + +

    Contributions:

    + + + +

    Authors:

    + +
      +
    • FlightControl: Concept, Design & Programming. +
    • +
    + +

    Global(s)

    + + + + + + + + + + + + + +
    TASK_A2A + +
    TASK_A2A_ENGAGE + +
    TASK_A2A_INTERCEPT + +
    +

    Type TASK_A2A

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TASK_A2A.ClassName + +
    TASK_A2A:GetPlannedMenuText() + +
    TASK_A2A:GetRendezVousCoordinate(TaskUnit) + +
    TASK_A2A:GetRendezVousZone(TaskUnit) + +
    TASK_A2A:GetTargetCoordinate(TaskUnit) + +
    TASK_A2A:GetTargetZone(TaskUnit) + +
    TASK_A2A:New(Mission, SetAttack, TaskName, UnitSetTargets, TargetDistance, TargetZone, TargetSetUnit, TaskType, TaskBriefing) +

    Instantiates a new TASK_A2A.

    +
    TASK_A2A:SetPenaltyOnFailed(Text, Penalty, TaskUnit) +

    Set a penalty when the A2A attack has failed.

    +
    TASK_A2A:SetRendezVousCoordinate(RendezVousCoordinate, RendezVousRange, TaskUnit) + +
    TASK_A2A:SetRendezVousZone(RendezVousZone, TaskUnit) + +
    TASK_A2A:SetScoreOnDestroy(Text, Score, TaskUnit) +

    Set a score when a target in scope of the A2A attack, has been destroyed .

    +
    TASK_A2A:SetScoreOnSuccess(Text, Score, TaskUnit) +

    Set a score when all the targets in scope of the A2A attack, have been destroyed.

    +
    TASK_A2A:SetTargetCoordinate(TargetCoordinate, TaskUnit) + +
    TASK_A2A:SetTargetZone(TargetZone, TaskUnit, Altitude, Heading) + +
    TASK_A2A.TargetSetUnit + +
    + +

    Type TASK_A2A_ENGAGE

    + + + + + + + + + + + + + +
    TASK_A2A_ENGAGE.ClassName + +
    TASK_A2A_ENGAGE:New(Mission, SetGroup, TaskName, TargetSetUnit, TaskBriefing) +

    Instantiates a new TASKA2AENGAGE.

    +
    TASK_A2A_ENGAGE.TargetSetUnit + +
    + +

    Type TASK_A2A_INTERCEPT

    + + + + + + + + + + + + + +
    TASK_A2A_INTERCEPT.ClassName + +
    TASK_A2A_INTERCEPT:New(Mission, SetGroup, TaskName, TargetSetUnit, TaskBriefing) +

    Instantiates a new TASKA2AINTERCEPT.

    +
    TASK_A2A_INTERCEPT.TargetSetUnit + +
    + +

    Global(s)

    +
    +
    + + #TASK_A2A + +TASK_A2A + +
    +
    + + + +
    +
    +
    +
    + + #TASK_A2A_ENGAGE + +TASK_A2A_ENGAGE + +
    +
    + + + +
    +
    +
    +
    + + #TASK_A2A_INTERCEPT + +TASK_A2A_INTERCEPT + +
    +
    + + + +
    +
    +

    Type Task_A2A

    + +

    Type FSM_PROCESS

    + +

    Type TASK_A2A

    + +

    The TASK_A2A class

    + +

    Field(s)

    +
    +
    + + #string + +TASK_A2A.ClassName + +
    +
    + + + +
    +
    +
    +
    + + +TASK_A2A:GetPlannedMenuText() + +
    +
    + + + +
    +
    +
    +
    + + +TASK_A2A:GetRendezVousCoordinate(TaskUnit) + +
    +
    + + + +

    Parameter

    + +

    Return values

    +
      +
    1. + +

      Core.Point#COORDINATE: +The Coordinate object referencing to the 2D point where the RendezVous point is located on the map.

      + +
    2. +
    3. + +

      #number: +The RendezVousRange that defines when the player is considered to have arrived at the RendezVous point.

      + +
    4. +
    +
    +
    +
    +
    + + +TASK_A2A:GetRendezVousZone(TaskUnit) + +
    +
    + + + +

    Parameter

    + +

    Return value

    + +

    Core.Zone#ZONE_BASE: +The Zone object where the RendezVous is located on the map.

    + +
    +
    +
    +
    + + +TASK_A2A:GetTargetCoordinate(TaskUnit) + +
    +
    + + + +

    Parameter

    + +

    Return value

    + +

    Core.Point#COORDINATE: +The Coordinate object where the Target is located on the map.

    + +
    +
    +
    +
    + + +TASK_A2A:GetTargetZone(TaskUnit) + +
    +
    + + + +

    Parameter

    + +

    Return value

    + +

    Core.Zone#ZONE_BASE: +The Zone object where the Target is located on the map.

    + +
    +
    +
    +
    + + +TASK_A2A:New(Mission, SetAttack, TaskName, UnitSetTargets, TargetDistance, TargetZone, TargetSetUnit, TaskType, TaskBriefing) + +
    +
    + +

    Instantiates a new TASK_A2A.

    + +

    Parameters

    +
      +
    • + +

      Tasking.Mission#MISSION Mission :

      + +
    • +
    • + +

      Set#SET_GROUP SetAttack : +The set of groups for which the Task can be assigned.

      + +
    • +
    • + +

      #string TaskName : +The name of the Task.

      + +
    • +
    • + +

      Set#SET_UNIT UnitSetTargets :

      + +
    • +
    • + +

      #number TargetDistance : +The distance to Target when the Player is considered to have "arrived" at the engagement range.

      + +
    • +
    • + +

      Core.Zone#ZONE_BASE TargetZone : +The target zone, if known. +If the TargetZone parameter is specified, the player will be routed to the center of the zone where all the targets are assumed to be.

      + +
    • +
    • + +

      TargetSetUnit :

      + +
    • +
    • + +

      TaskType :

      + +
    • +
    • + +

      TaskBriefing :

      + +
    • +
    +

    Return value

    + +

    #TASK_A2A: +self

    + +
    +
    +
    +
    + + +TASK_A2A:SetPenaltyOnFailed(Text, Penalty, TaskUnit) + +
    +
    + +

    Set a penalty when the A2A attack has failed.

    + +

    Parameters

    +
      +
    • + +

      #string Text : +The text to display to the player, when the A2A attack has failed.

      + +
    • +
    • + +

      #number Penalty : +The penalty in points.

      + +
    • +
    • + +

      Wrapper.Unit#UNIT TaskUnit :

      + +
    • +
    +

    Return value

    + +

    #TASK_A2A:

    + + +
    +
    +
    +
    + + +TASK_A2A:SetRendezVousCoordinate(RendezVousCoordinate, RendezVousRange, TaskUnit) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      Core.Point#COORDINATE RendezVousCoordinate : +The Coordinate object referencing to the 2D point where the RendezVous point is located on the map.

      + +
    • +
    • + +

      #number RendezVousRange : +The RendezVousRange that defines when the player is considered to have arrived at the RendezVous point.

      + +
    • +
    • + +

      Wrapper.Unit#UNIT TaskUnit :

      + +
    • +
    +
    +
    +
    +
    + + +TASK_A2A:SetRendezVousZone(RendezVousZone, TaskUnit) + +
    +
    + + + +

    Parameters

    + +
    +
    +
    +
    + + +TASK_A2A:SetScoreOnDestroy(Text, Score, TaskUnit) + +
    +
    + +

    Set a score when a target in scope of the A2A attack, has been destroyed .

    + +

    Parameters

    +
      +
    • + +

      #string Text : +The text to display to the player, when the target has been destroyed.

      + +
    • +
    • + +

      #number Score : +The score in points.

      + +
    • +
    • + +

      Wrapper.Unit#UNIT TaskUnit :

      + +
    • +
    +

    Return value

    + +

    #TASK_A2A:

    + + +
    +
    +
    +
    + + +TASK_A2A:SetScoreOnSuccess(Text, Score, TaskUnit) + +
    +
    + +

    Set a score when all the targets in scope of the A2A attack, have been destroyed.

    + +

    Parameters

    +
      +
    • + +

      #string Text : +The text to display to the player, when all targets hav been destroyed.

      + +
    • +
    • + +

      #number Score : +The score in points.

      + +
    • +
    • + +

      Wrapper.Unit#UNIT TaskUnit :

      + +
    • +
    +

    Return value

    + +

    #TASK_A2A:

    + + +
    +
    +
    +
    + + +TASK_A2A:SetTargetCoordinate(TargetCoordinate, TaskUnit) + +
    +
    + + + +

    Parameters

    + +
    +
    +
    +
    + + +TASK_A2A:SetTargetZone(TargetZone, TaskUnit, Altitude, Heading) + +
    +
    + + + +

    Parameters

    +
      +
    • + +

      Core.Zone#ZONE_BASE TargetZone : +The Zone object where the Target is located on the map.

      + +
    • +
    • + +

      Wrapper.Unit#UNIT TaskUnit :

      + +
    • +
    • + +

      Altitude :

      + +
    • +
    • + +

      Heading :

      + +
    • +
    +
    +
    +
    +
    + + Set#SET_UNIT + +TASK_A2A.TargetSetUnit + +
    +
    + + + +
    +
    + +

    Type TASK_A2A_ENGAGE

    + +

    The TASKA2AENGAGE class

    + +

    Field(s)

    +
    +
    + + #string + +TASK_A2A_ENGAGE.ClassName + +
    +
    + + + +
    +
    +
    +
    + + +TASK_A2A_ENGAGE:New(Mission, SetGroup, TaskName, TargetSetUnit, TaskBriefing) + +
    +
    + +

    Instantiates a new TASKA2AENGAGE.

    + +

    Parameters

    +
      +
    • + +

      Tasking.Mission#MISSION Mission :

      + +
    • +
    • + +

      Core.Set#SET_GROUP SetGroup : +The set of groups for which the Task can be assigned.

      + +
    • +
    • + +

      #string TaskName : +The name of the Task.

      + +
    • +
    • + +

      Core.Set#SET_UNIT TargetSetUnit :

      + +
    • +
    • + +

      #string TaskBriefing : +The briefing of the task.

      + +
    • +
    +

    Return value

    + +

    #TASKA2AENGAGE: +self

    + +
    +
    +
    +
    + + Set#SET_UNIT + +TASK_A2A_ENGAGE.TargetSetUnit + +
    +
    + + + +
    +
    + +

    Type TASK_A2A_INTERCEPT

    + +

    The TASKA2AINTERCEPT class

    + +

    Field(s)

    +
    +
    + + #string + +TASK_A2A_INTERCEPT.ClassName + +
    +
    + + + +
    +
    +
    +
    + + +TASK_A2A_INTERCEPT:New(Mission, SetGroup, TaskName, TargetSetUnit, TaskBriefing) + +
    +
    + +

    Instantiates a new TASKA2AINTERCEPT.

    + +

    Parameters

    +
      +
    • + +

      Tasking.Mission#MISSION Mission :

      + +
    • +
    • + +

      Core.Set#SET_GROUP SetGroup : +The set of groups for which the Task can be assigned.

      + +
    • +
    • + +

      #string TaskName : +The name of the Task.

      + +
    • +
    • + +

      Core.Set#SET_UNIT TargetSetUnit :

      + +
    • +
    • + +

      #string TaskBriefing : +The briefing of the task.

      + +
    • +
    +

    Return value

    + +

    #TASKA2AINTERCEPT: +self

    + +
    +
    +
    +
    + + Set#SET_UNIT + +TASK_A2A_INTERCEPT.TargetSetUnit + +
    +
    + + + +
    +
    + +
    + +
    + + diff --git a/docs/Documentation/Task_A2A_Dispatcher.html b/docs/Documentation/Task_A2A_Dispatcher.html new file mode 100644 index 000000000..56997d179 --- /dev/null +++ b/docs/Documentation/Task_A2A_Dispatcher.html @@ -0,0 +1,644 @@ + + + + + + +
    +
    + +
    +
    +
    +
    + +
    +

    Module Task_A2A_Dispatcher

    + +

    Tasking - The TASKA2ADISPATCHER creates and manages player TASK_A2A tasks based on detected targets.

    + + + +
    + +

    1) #TASKA2ADISPATCHER class, extends #DETECTION_MANAGER

    + +

    The #TASKA2ADISPATCHER class implements the dynamic dispatching of tasks upon groups of detected units determined a Set of EWR installation groups. +The EWR will detect units, will group them, and will dispatch Tasks to groups. Depending on the type of target detected, different tasks will be dispatched. +Find a summary below describing for which situation a task type is created:

    + +
      +
    • INTERCEPT Task: Is created when the target is known, is detected and within a danger zone, and there is no friendly airborne in range.
    • +
    • SWEEP Task: Is created when the target is unknown, was detected and the last position is only known, and within a danger zone, and there is no friendly airborne in range.
    • +
    • ENGAGE Task: Is created when the target is known, is detected and within a danger zone, and there is a friendly airborne in range, that will receive this task.
    • +
    + +

    Other task types will follow...

    + +

    3.1) TASKA2ADISPATCHER constructor:

    +

    The TASKA2ADISPATCHER.New() method creates a new TASKA2ADISPATCHER instance.

    + +
    + +

    API CHANGE HISTORY

    + +

    The underlying change log documents the API changes. Please read this carefully. The following notation is used:

    + +
      +
    • Added parts are expressed in bold type face.
    • +
    • Removed parts are expressed in italic type face.
    • +
    + +

    Hereby the change log:

    + +
    + +

    AUTHORS and CONTRIBUTIONS

    + +

    Contributions:

    + +

    Authors:

    + +
      +
    • FlightControl: Concept, Design & Programming.
    • +
    + + +

    Global(s)

    + + + + + +
    TASK_A2A_DISPATCHER + +
    +

    Type TASK_A2A_DISPATCHER

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TASK_A2A_DISPATCHER.ClassName + +
    TASK_A2A_DISPATCHER.Detection +

    The DETECTION_BASE object that is used to report the detected objects. The Detection object will only function in RADAR mode!!!

    +
    TASK_A2A_DISPATCHER:EvaluateENGAGE(DetectedItem) +

    Creates an ENGAGE task when there are human friendlies airborne near the targets.

    +
    TASK_A2A_DISPATCHER:EvaluateINTERCEPT(DetectedItem) +

    Creates an INTERCEPT task when there are targets for it.

    +
    TASK_A2A_DISPATCHER:EvaluateRemoveTask(Mission, Task, Detection, DetectedItemID, DetectedItemChange, DetectedItem, DetectedItemIndex, DetectedItemChanged) +

    Evaluates the removal of the Task from the Mission.

    +
    TASK_A2A_DISPATCHER:GetFriendliesNearBy(DetectedItem) +

    Calculates which friendlies are nearby the area

    +
    TASK_A2A_DISPATCHER:GetPlayerFriendliesNearBy(DetectedItem) +

    Calculates which HUMAN friendlies are nearby the area

    +
    TASK_A2A_DISPATCHER.Mission + +
    TASK_A2A_DISPATCHER:New(Mission, SetGroup, Detection) +

    TASKA2ADISPATCHER constructor.

    +
    TASK_A2A_DISPATCHER:OnAfterAssign(From, Event, To, Task, TaskUnit, PlayerName) +

    OnAfter Transition Handler for Event Assign.

    +
    TASK_A2A_DISPATCHER:ProcessDetected(Detection) +

    Assigns tasks in relation to the detected items to the Set#SET_GROUP.

    +
    TASK_A2A_DISPATCHER.SetGroup +

    The groups to which the FAC will report to.

    +
    TASK_A2A_DISPATCHER.Tasks + +
    + +

    Global(s)

    +
    +
    + + #TASK_A2A_DISPATCHER + +TASK_A2A_DISPATCHER + +
    +
    + + + +
    +
    +

    Type Task_A2A_Dispatcher

    + +

    Type TASK_A2A_DISPATCHER

    + +

    TASKA2ADISPATCHER class.

    + +

    Field(s)

    +
    +
    + + #string + +TASK_A2A_DISPATCHER.ClassName + +
    +
    + + + +
    +
    +
    +
    + + Functional.Detection#DETECTION_BASE + +TASK_A2A_DISPATCHER.Detection + +
    +
    + +

    The DETECTION_BASE object that is used to report the detected objects. The Detection object will only function in RADAR mode!!!

    + +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:EvaluateENGAGE(DetectedItem) + +
    +
    + +

    Creates an ENGAGE task when there are human friendlies airborne near the targets.

    + +

    Parameter

    + +

    Return values

    +
      +
    1. + +

      Set#SET_UNIT: +TargetSetUnit: The target set of units.

      + +
    2. +
    3. + +

      #nil: +If there are no targets to be set.

      + +
    4. +
    +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:EvaluateINTERCEPT(DetectedItem) + +
    +
    + +

    Creates an INTERCEPT task when there are targets for it.

    + +

    Parameter

    + +

    Return values

    +
      +
    1. + +

      Set#SET_UNIT: +TargetSetUnit: The target set of units.

      + +
    2. +
    3. + +

      #nil: +If there are no targets to be set.

      + +
    4. +
    +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:EvaluateRemoveTask(Mission, Task, Detection, DetectedItemID, DetectedItemChange, DetectedItem, DetectedItemIndex, DetectedItemChanged) + +
    +
    + +

    Evaluates the removal of the Task from the Mission.

    + + +

    Can only occur when the DetectedItem is Changed AND the state of the Task is "Planned".

    + +

    Parameters

    + +

    Return value

    + +

    Tasking.Task#TASK:

    + + +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:GetFriendliesNearBy(DetectedItem) + +
    +
    + +

    Calculates which friendlies are nearby the area

    + +

    Parameter

    +
      +
    • + +

      DetectedItem :

      + +
    • +
    +

    Return value

    + +

    #number, Core.CommandCenter#REPORT:

    + + +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:GetPlayerFriendliesNearBy(DetectedItem) + +
    +
    + +

    Calculates which HUMAN friendlies are nearby the area

    + +

    Parameter

    +
      +
    • + +

      DetectedItem :

      + +
    • +
    +

    Return value

    + +

    #number, Core.CommandCenter#REPORT:

    + + +
    +
    +
    +
    + + Tasking.Mission#MISSION + +TASK_A2A_DISPATCHER.Mission + +
    +
    + + + +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:New(Mission, SetGroup, Detection) + +
    +
    + +

    TASKA2ADISPATCHER constructor.

    + +

    Parameters

    + +

    Return value

    + +

    #TASKA2ADISPATCHER: +self

    + +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:OnAfterAssign(From, Event, To, Task, TaskUnit, PlayerName) + +
    +
    + +

    OnAfter Transition Handler for Event Assign.

    + +

    Parameters

    +
      +
    • + +

      #string From : +The From State string.

      + +
    • +
    • + +

      #string Event : +The Event string.

      + +
    • +
    • + +

      #string To : +The To State string.

      + +
    • +
    • + +

      Tasking.TaskA2A#TASKA2A Task :

      + +
    • +
    • + +

      Wrapper.Unit#UNIT TaskUnit :

      + +
    • +
    • + +

      #string PlayerName :

      + +
    • +
    +
    +
    +
    +
    + + +TASK_A2A_DISPATCHER:ProcessDetected(Detection) + +
    +
    + +

    Assigns tasks in relation to the detected items to the Set#SET_GROUP.

    + +

    Parameter

    + +

    Return value

    + +

    #boolean: +Return true if you want the task assigning to continue... false will cancel the loop.

    + +
    +
    +
    +
    + + Set#SET_GROUP + +TASK_A2A_DISPATCHER.SetGroup + +
    +
    + +

    The groups to which the FAC will report to.

    + +
    +
    +
    +
    + + + +TASK_A2A_DISPATCHER.Tasks + +
    +
    + + + +
    +
    + +
    + +
    + + diff --git a/docs/Documentation/Task_A2G.html b/docs/Documentation/Task_A2G.html index 82710dd9f..78390c8c1 100644 --- a/docs/Documentation/Task_A2G.html +++ b/docs/Documentation/Task_A2G.html @@ -75,6 +75,7 @@
  • Scoring
  • Sead
  • Set
  • +
  • Settings
  • Smoke
  • Spawn
  • SpawnStatic
  • @@ -82,6 +83,8 @@
  • Static
  • StaticObject
  • Task
  • +
  • Task_A2A
  • +
  • Task_A2A_Dispatcher
  • Task_A2G
  • Task_A2G_Dispatcher
  • Task_Cargo
  • @@ -218,7 +221,7 @@ The TASK_A2G is implemented using a Stat - TASK_A2G:GetRendezVousPointVec2(TaskUnit) + TASK_A2G:GetRendezVousCoordinate(TaskUnit) @@ -230,7 +233,7 @@ The TASK_A2G is implemented using a Stat - TASK_A2G:GetTargetPointVec2(TaskUnit) + TASK_A2G:GetTargetCoordinate(TaskUnit) @@ -254,7 +257,7 @@ The TASK_A2G is implemented using a Stat - TASK_A2G:SetRendezVousPointVec2(RendezVousPointVec2, RendezVousRange, TaskUnit) + TASK_A2G:SetRendezVousCoordinate(RendezVousCoordinate, RendezVousRange, TaskUnit) @@ -278,7 +281,7 @@ The TASK_A2G is implemented using a Stat - TASK_A2G:SetTargetPointVec2(TargetPointVec2, TaskUnit) + TASK_A2G:SetTargetCoordinate(TargetCoordinate, TaskUnit) @@ -459,8 +462,8 @@ The TASK_A2G is implemented using a Stat
    - -TASK_A2G:GetRendezVousPointVec2(TaskUnit) + +TASK_A2G:GetRendezVousCoordinate(TaskUnit)
    @@ -479,8 +482,8 @@ The TASK_A2G is implemented using a Stat
    1. -

      Core.Point#POINT_VEC2: -The PointVec2 object referencing to the 2D point where the RendezVous point is located on the map.

      +

      Core.Point#COORDINATE: +The Coordinate object referencing to the 2D point where the RendezVous point is located on the map.

    2. @@ -521,8 +524,8 @@ The Zone object where the RendezVous is located on the map.

      - -TASK_A2G:GetTargetPointVec2(TaskUnit) + +TASK_A2G:GetTargetCoordinate(TaskUnit)
      @@ -539,8 +542,8 @@ The Zone object where the RendezVous is located on the map.

      Return value

      -

      Core.Point#POINT_VEC2: -The PointVec2 object where the Target is located on the map.

      +

      Core.Point#COORDINATE: +The Coordinate object where the Target is located on the map.

      @@ -682,8 +685,8 @@ The penalty in points.

      - -TASK_A2G:SetRendezVousPointVec2(RendezVousPointVec2, RendezVousRange, TaskUnit) + +TASK_A2G:SetRendezVousCoordinate(RendezVousCoordinate, RendezVousRange, TaskUnit)
      @@ -694,8 +697,8 @@ The penalty in points.