Banner Image

Module Core.Point

Core - Defines an extensive API to manage 3D points in the DCS World 3D simulation space.

Features:

  • Provides a COORDINATE class, which allows to manage points in 3D space and perform various operations on it.
  • Provides a POINT_VEC2 class, which is derived from COORDINATE, and allows to manage points in 3D space, but from a Lat/Lon and Altitude perspective.
  • Provides a POINT_VEC3 class, which is derived from COORDINATE, and allows to manage points in 3D space, but from a X, Z and Y vector perspective.

Demo Missions

POINT_VEC Demo Missions source code

POINT_VEC Demo Missions, only for beta testers

ALL Demo Missions pack of the last release


YouTube Channel

POINT_VEC YouTube Channel


Authors:

  • FlightControl : Design & Programming

Contributions:

Global(s)

Global COORDINATE

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

#COORDINATE COORDINATE

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

1) Create a COORDINATE object.

A new COORDINATE object can be created with 3 various methods:

2) Smoke, flare, explode, illuminate at the coordinate.

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

2.1) Smoke

2.2) Flare

2.3) Explode

2.4) Illuminate

3) Create markings on the map.

Place markers (text boxes with clarifications for briefings, target locations or any other reference point) on the map for all players, coalitions or specific groups:

4) Coordinate calculation methods.

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

4.1) Get the distance between 2 points.

4.2) Get the angle.

4.3) Coordinate translation.

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

4.4) Get the North correction of the current location.

4.5) Point Randomization

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

4.6) LOS between coordinates.

Calculate if the coordinate has Line of Sight (LOS) with the other given coordinate. Mountains, trees and other objects can be positioned between the two 3D points, preventing visibilty in a straight continuous line. The method COORDINATE.IsLOS() returns if the two coodinates have LOS.

4.7) Check the coordinate position.

Various methods are available that allow to check if a coordinate is:

5) Measure the simulation environment at the coordinate.

5.1) Weather specific.

Within the DCS simulator, a coordinate has specific environmental properties, like wind, temperature, humidity etc.

5.2) Surface specific.

Within the DCS simulator, the surface can have various objects placed at the coordinate, and the surface height will vary.

6) Create waypoints for routes.

A COORDINATE 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 Wrapper.Group#GROUP class.

7) Manage the roads.

Important for ground vehicle transportation and movement, the method COORDINATE.GetClosestPointToRoad() will calculate the closest point on the nearest road.

In order to use the most optimal road system to transport vehicles, the method COORDINATE.GetPathOnRoad() will calculate the most optimal path following the road between two coordinates.

8) Metric or imperial system

9) Coordinate text generation

Global POINT_VEC2

Defines a 2D point in the simulator.

#POINT_VEC2 POINT_VEC2

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:

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()

Global POINT_VEC3

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

#POINT_VEC3 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:

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.

Type(s)

Fields and Methods inherited from COORDINATE Description

COORDINATE:BigSmokeAndFire(preset, density)

Big smoke and fire at the coordinate.

COORDINATE:BigSmokeAndFireHuge(density)

Huge smoke and fire at the coordinate.

COORDINATE:BigSmokeAndFireLarge(density)

Large smoke and fire at the coordinate.

COORDINATE:BigSmokeAndFireMedium(density)

Medium smoke and fire at the coordinate.

COORDINATE:BigSmokeAndFireSmall(density)

Small smoke and fire at the coordinate.

COORDINATE:BigSmokeHuge(density)

Huge smoke at the coordinate.

COORDINATE:BigSmokeLarge(density)

Large smoke at the coordinate.

COORDINATE:BigSmokeMedium(density)

Medium smoke at the coordinate.

COORDINATE:BigSmokeSmall(density)

Small smoke at the coordinate.

COORDINATE:DistanceFromPointVec2(PointVec2Reference)

Calculate the distance from a reference #COORDINATE.

COORDINATE:Explosion(ExplosionIntensity, Delay)

Creates an explosion at the point of a certain intensity.

COORDINATE:FindClosestScenery(radius)

Find the closest scenery to the COORDINATE within a certain radius.

COORDINATE:FindClosestUnit(radius)

Find the closest unit to the COORDINATE within a certain radius.

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, Language)

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, Language)

Provides a Bearing / Range / Altitude string

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

Provides a Bearing / Range string

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

Provides a bearing text in degrees.

COORDINATE:GetClosestAirbase(Category, Coalition)

Gets the nearest airbase with respect to the current coordinates.

COORDINATE:GetClosestAirbase2(Category, Coalition)

Gets the nearest airbase with respect to the current coordinates.

COORDINATE:GetClosestFreeParkingSpot(airbase, terminaltype)

Gets the nearest free parking spot.

COORDINATE:GetClosestOccupiedParkingSpot(airbase, terminaltype)

Gets the nearest occupied parking spot.

COORDINATE:GetClosestParkingSpot(airbase, terminaltype, free)

Gets the nearest parking spot.

COORDINATE:GetClosestPointToRoad(Railroad)

Gets the nearest coordinate to a road (or railroad).

COORDINATE:GetDirectionVec3(TargetCoordinate)

Return a direction vector Vec3 from COORDINATE to the COORDINATE.

COORDINATE:GetDistanceText(Distance, Settings, Language)

Provides a distance text expressed in the units of measurement.

COORDINATE:GetHeading()

Get the heading of the coordinate, if applicable.

COORDINATE:GetHeadingText(Settings)

Return the heading text of the COORDINATE.

COORDINATE:GetIntermediateCoordinate(ToCoordinate, Fraction)

Return an intermediate COORDINATE between this an another coordinate.

COORDINATE:GetLLDDM()

Get Latitude and Longitude in Degrees Decimal Minutes (DDM).

COORDINATE:GetLandHeight()

Return the height of the land at the coordinate.

COORDINATE:GetMinutesToSunrise(OnlyToday)

Get minutes until the next sun rise at this coordinate.

COORDINATE:GetMinutesToSunset(OnlyToday)

Get minutes until the next sun set at this coordinate.

COORDINATE:GetMovingText(Settings)

Return velocity text of the COORDINATE.

COORDINATE:GetNorthCorrectionRadians()

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

COORDINATE:GetPathOnRoad(ToCoord, IncludeEndpoints, Railroad, MarkPath, SmokePath)

Returns a table of coordinates to a destination using only roads or railroads.

COORDINATE:GetPressure(height)

Returns the pressure in hPa.

COORDINATE:GetPressureText(height, Settings)

Returns a text of the pressure according the measurement system Settings.

COORDINATE:GetRandomCoordinateInRadius(OuterRadius, InnerRadius)

Return a random Coordinate within an Outer Radius and optionally NOT within an Inner Radius 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:GetSunrise(InSeconds)

Get todays sun rise time.

COORDINATE:GetSunriseAtDate(Day, Month, Year, InSeconds)

Get sun rise time for a specific date at the coordinate.

COORDINATE:GetSunriseAtDayOfYear(DayOfYear, InSeconds)

Get sun rise time for a specific day of the year at the coordinate.

COORDINATE:GetSunset(InSeconds)

Get todays sun set time.

COORDINATE:GetSunsetAtDate(Day, Month, Year, InSeconds)

Get sun set time for a specific date at the coordinate.

COORDINATE:GetSurfaceType()

Gets the surface type at the coordinate.

COORDINATE:GetTemperature(height)

Returns the temperature in Degrees Celsius.

COORDINATE:GetTemperatureText(height, Settings)

Returns a text of the temperature according the measurement system Settings.

COORDINATE:GetVec2()

Return the coordinates of the COORDINATE in Vec2 format.

COORDINATE:GetVec3()

Return the coordinates of the COORDINATE in Vec3 format.

COORDINATE:GetVelocity()

Return the velocity of the COORDINATE.

COORDINATE:GetVelocityText(Settings)

Return the velocity text of the COORDINATE.

COORDINATE:GetWind(height)

Returns the wind direction (from) and strength.

COORDINATE:GetWindText(height, Settings)

Returns a text documenting the wind direction (from) and strength according the measurement system Settings.

COORDINATE:GetWindWithTurbulenceVec3(height)

Returns the wind direction (from) and strength.

COORDINATE.Heading

COORDINATE:HeadingTo(ToCoordinate)

Returns the heading from this to another coordinate.

COORDINATE:IlluminationBomb(power)

Creates an illumination bomb at the point.

COORDINATE:IsAtCoordinate2D(Coordinate, Precision)

Returns if the 2 coordinates are at the same 2D position.

COORDINATE:IsDay(Clock)

Check if it is day, i.e.

COORDINATE:IsInRadius(Coordinate, Radius)

Returns if a Coordinate is in a certain Radius of this Coordinate in 2D plane using the X and Z axis.

COORDINATE:IsInSphere(ToCoordinate, Radius, Coordinate)

Returns if a Coordinate is in a certain radius of this Coordinate in 3D space using the X, Y and Z axis.

COORDINATE:IsLOS(ToCoordinate, Offset)

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

COORDINATE:IsNight(Clock)

Check if it is night, i.e.

COORDINATE:IsSurfaceTypeLand()

Checks if the surface type is on land.

COORDINATE:IsSurfaceTypeRoad()

Checks if the surface type is road.

COORDINATE:IsSurfaceTypeRunway()

Checks if the surface type is runway.

COORDINATE:IsSurfaceTypeShallowWater()

Checks if the surface type is shallow water.

COORDINATE:IsSurfaceTypeWater()

Checks if the surface type is water.

COORDINATE:MarkToAll(MarkText, ReadOnly, Text)

Mark to All

COORDINATE:MarkToCoalition(MarkText, Coalition, ReadOnly, Text)

Mark to Coalition

COORDINATE:MarkToCoalitionBlue(MarkText, ReadOnly, Text)

Mark to Blue Coalition

COORDINATE:MarkToCoalitionRed(MarkText, ReadOnly, Text)

Mark to Red Coalition

COORDINATE:MarkToGroup(MarkText, MarkGroup, ReadOnly, Text)

Mark to Group

COORDINATE:New(x, y, z)

COORDINATE constructor.

COORDINATE:NewFromCoordinate(Coordinate)

COORDINATE constructor.

COORDINATE:NewFromLLDD(latitude, longitude, altitude)

Returns the coordinate from the latitude and longitude given in decimal degrees.

COORDINATE:NewFromVec2(Vec2, LandHeightAdd)

Create a new COORDINATE object from Vec2 coordinates.

COORDINATE:NewFromVec3(Vec3)

Create a new COORDINATE object from Vec3 coordinates.

COORDINATE:RemoveMark(MarkID)

Remove a mark

COORDINATE:Rotate2D(Angle)

Rotate coordinate in 2D (x,z) space.

COORDINATE:ScanObjects(radius, scanunits, scanstatics, scanscenery)

Scan/find objects (units, statics, scenery) within a certain radius around the coordinate using the world.searchObjects() DCS API function.

COORDINATE:ScanScenery(radius)

Scan/find SCENERY objects within a certain radius around the coordinate using the world.searchObjects() DCS API function.

COORDINATE:ScanUnits(radius)

Scan/find UNITS within a certain radius around the coordinate using the world.searchObjects() DCS API function.

COORDINATE:SetAltitude(altitude, asl)

Set altitude.

COORDINATE:SetHeading(Heading)

Set the heading of the coordinate, if applicable.

COORDINATE:SetVelocity(Velocity)

Set the velocity of the COORDINATE.

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, Task)

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

COORDINATE:ToStringA2A(Controllable, Settings, Language)

Provides a coordinate string of the point, based on the A2A coordinate format system.

COORDINATE:ToStringA2G(Controllable, Settings)

Provides a coordinate string of the point, based on the A2G coordinate format system.

COORDINATE:ToStringAspect(TargetCoordinate)

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

COORDINATE:ToStringBR(FromCoordinate, Settings)

Return a BR string from a COORDINATE to the COORDINATE.

COORDINATE:ToStringBRA(FromCoordinate, Settings, Language)

Return a BRAA string from a COORDINATE to the COORDINATE.

COORDINATE:ToStringBULLS(Coalition, Settings)

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

COORDINATE:ToStringFromRP(ReferenceCoord, ReferenceName, Controllable, Settings)

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

COORDINATE:ToStringLLDDM(Settings)

Provides a Lat Lon string in Degree Decimal Minute format.

COORDINATE:ToStringLLDMS(Settings)

Provides a Lat Lon string in Degree Minute Second format.

COORDINATE:ToStringMGRS(Settings)

Provides a MGRS string

COORDINATE:ToStringPressure(Controllable, Settings)

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

COORDINATE:ToStringTemperature(Controllable, Core, Settings)

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

COORDINATE:ToStringWind(Controllable, Settings)

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

COORDINATE:Translate(Distance, Angle, Keepalt, Overwrite)

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

COORDINATE:UpdateFromCoordinate(Coordinate)

Update x,y,z coordinates from another given COORDINATE.

COORDINATE:UpdateFromVec2(Vec2)

Update x and z coordinates from a given 2D vector.

COORDINATE:UpdateFromVec3(Vec3)

Update x,y,z coordinates from a given 3D vector.

COORDINATE.Velocity

COORDINATE.WaypointAction

COORDINATE:WaypointAir(AltType, Type, Action, Speed, SpeedLocked, airbase, DCSTasks, description, timeReFuAr)

Build an air type route point.

COORDINATE:WaypointAirFlyOverPoint(AltType, Speed)

Build a Waypoint Air "Fly Over Point".

COORDINATE:WaypointAirLanding(Speed, airbase, DCSTasks, description)

Build a Waypoint Air "Landing".

COORDINATE:WaypointAirLandingReFu(Speed, airbase, timeReFuAr, DCSTasks, description)

Build a Waypoint Air "LandingReFuAr".

COORDINATE:WaypointAirTakeOffParking(AltType, Speed)

Build a Waypoint Air "Take Off Parking".

COORDINATE:WaypointAirTakeOffParkingHot(AltType, Speed)

Build a Waypoint Air "Take Off Parking Hot".

COORDINATE:WaypointAirTakeOffRunway(AltType, Speed)

Build a Waypoint Air "Take Off Runway".

COORDINATE:WaypointAirTurningPoint(AltType, Speed, DCSTasks, description)

Build a Waypoint Air "Turning Point".

COORDINATE.WaypointAltType

COORDINATE:WaypointGround(Speed, Formation, DCSTasks)

Build an ground type route point.

COORDINATE:WaypointNaval(Speed, Depth, DCSTasks)

Build route waypoint point for Naval units.

COORDINATE.WaypointType

COORDINATE.x

COORDINATE.y

COORDINATE.z

Fields and Methods inherited from BASE Description

COORDINATE.ClassID

The ID number of the class.

COORDINATE.ClassName

The name of the class.

COORDINATE.ClassNameAndID

The name of the class concatenated with the ID number of the class.

COORDINATE:ClearState(Object, StateName)

Clear the state of an object.

COORDINATE:CreateEventBirth(EventTime, Initiator, IniUnitName, place, subplace)

Creation of a Birth Event.

COORDINATE:CreateEventCrash(EventTime, Initiator)

Creation of a Crash Event.

COORDINATE:CreateEventDead(EventTime, Initiator)

Creation of a Dead Event.

COORDINATE:CreateEventRemoveUnit(EventTime, Initiator)

Creation of a Remove Unit Event.

COORDINATE:CreateEventTakeoff(EventTime, Initiator)

Creation of a Takeoff Event.

COORDINATE:CreateEventUnitLost(EventTime, Initiator)

Creation of a Crash Event.

COORDINATE:E(Arguments)

Log an exception which will be traced always.

COORDINATE:EventDispatcher()

Returns the event dispatcher

COORDINATE:EventRemoveAll()

Remove all subscribed events

COORDINATE:F(Arguments)

Trace a function call.

COORDINATE:F2(Arguments)

Trace a function call level 2.

COORDINATE:F3(Arguments)

Trace a function call level 3.

COORDINATE:GetClassID()

Get the ClassID of the class instance.

COORDINATE:GetClassName()

Get the ClassName of the class instance.

COORDINATE:GetClassNameAndID()

Get the ClassName + ClassID of the class instance.

COORDINATE:GetEventPriority()

Get the Class Event processing Priority.

COORDINATE:GetParent(Child, FromClass)

This is the worker method to retrieve the Parent class.

COORDINATE:GetState(Object, Key)

Get a Value given a Key from the Object.

COORDINATE:HandleEvent(Event, EventFunction)

Subscribe to a DCS Event.

COORDINATE:I(Arguments)

Log an information which will be traced always.

COORDINATE:Inherit(Child, Parent)

This is the worker method to inherit from a parent class.

COORDINATE:IsInstanceOf(ClassName)

This is the worker method to check if an object is an (sub)instance of a class.

COORDINATE:IsTrace()

Enquires if tracing is on (for the class).

COORDINATE:New()

BASE constructor.

COORDINATE:OnEvent(EventData)

Occurs when an object is completely destroyed.

COORDINATE:OnEventBaseCaptured(EventData)

Occurs when a ground unit captures either an airbase or a farp.

COORDINATE:OnEventBirth(EventData)

Occurs when any object is spawned into the mission.

COORDINATE:OnEventCrash(EventData)

Occurs when any aircraft crashes into the ground and is completely destroyed.

COORDINATE:OnEventDead(EventData)

Occurs when an object is dead.

COORDINATE:OnEventDetailedFailure(EventData)

Unknown precisely what creates this event, likely tied into newer damage model.

COORDINATE:OnEventEjection(EventData)

Occurs when a pilot ejects from an aircraft initiator : The unit that has ejected

COORDINATE:OnEventEngineShutdown(EventData)

Occurs when any aircraft shuts down its engines.

COORDINATE:OnEventEngineStartup(EventData)

Occurs when any aircraft starts its engines.

COORDINATE:OnEventHit(EventData)

Occurs whenever an object is hit by a weapon.

COORDINATE:OnEventHumanFailure(EventData)

Occurs when any system fails on a human controlled aircraft.

COORDINATE:OnEventKill(EventData)

Occurs on the death of a unit.

COORDINATE:OnEventLand(EventData)

Occurs when an aircraft lands at an airbase, farp or ship initiator : The unit that has landed place: Object that the unit landed on.

COORDINATE:OnEventLandingAfterEjection(EventData)

Occurs shortly after the landing animation of an ejected pilot touching the ground and standing up.

COORDINATE:OnEventMarkAdded(EventData)

Occurs when a new mark was added.

COORDINATE:OnEventMarkChange(EventData)

Occurs when a mark text was changed.

COORDINATE:OnEventMarkRemoved(EventData)

Occurs when a mark was removed.

COORDINATE:OnEventMissionEnd(EventData)

Occurs when a mission ends

COORDINATE:OnEventMissionStart(EventData)

Occurs when a mission starts

COORDINATE:OnEventPilotDead(EventData)

Occurs when the pilot of an aircraft is killed.

COORDINATE:OnEventPlayerEnterUnit(EventData)

Occurs when any player assumes direct control of a unit.

COORDINATE:OnEventPlayerLeaveUnit(EventData)

Occurs when any player relieves control of a unit to the AI.

COORDINATE:OnEventRefueling(EventData)

Occurs when an aircraft connects with a tanker and begins taking on fuel.

COORDINATE:OnEventRefuelingStop(EventData)

Occurs when an aircraft is finished taking fuel.

COORDINATE:OnEventScore(EventData)

Occurs when any modification to the "Score" as seen on the debrief menu would occur.

COORDINATE:OnEventShootingEnd(EventData)

Occurs when any unit stops firing its weapon.

COORDINATE:OnEventShootingStart(EventData)

Occurs when any unit begins firing a weapon that has a high rate of fire.

COORDINATE:OnEventShot(EventData)

Occurs whenever any unit in a mission fires a weapon.

COORDINATE:OnEventTakeoff(EventData)

Occurs when an aircraft takes off from an airbase, farp, or ship.

COORDINATE:OnEventUnitLost(EventData)

Occurs when the game thinks an object is destroyed.

COORDINATE:ScheduleOnce(Start, SchedulerFunction, ...)

Schedule a new time event.

COORDINATE:ScheduleRepeat(Start, Repeat, RandomizeFactor, Stop, SchedulerFunction, ...)

Schedule a new time event.

COORDINATE:ScheduleStop(SchedulerFunction)

Stops the Schedule.

COORDINATE.Scheduler

COORDINATE:SetEventPriority(EventPriority)

Set the Class Event processing Priority.

COORDINATE:SetState(Object, Key, Value)

Set a state or property of the Object given a Key and a Value.

COORDINATE:T(Arguments)

Trace a function logic level 1.

COORDINATE:T2(Arguments)

Trace a function logic level 2.

COORDINATE:T3(Arguments)

Trace a function logic level 3.

COORDINATE:TraceAll(TraceAll)

Trace all methods in MOOSE

COORDINATE:TraceClass(Class)

Set tracing for a class

COORDINATE:TraceClassMethod(Class, Method)

Set tracing for a specific method of class

COORDINATE:TraceLevel(Level)

Set trace level

COORDINATE:TraceOff()

Set trace off.

COORDINATE:TraceOn()

Set trace on.

COORDINATE:TraceOnOff(TraceOnOff)

Set trace on or off Note that when trace is off, no BASE.Debug statement is performed, increasing performance! When Moose is loaded statically, (as one file), tracing is switched off by default.

COORDINATE:UnHandleEvent(Event)

UnSubscribe to a DCS event.

COORDINATE._

COORDINATE:_F(Arguments, DebugInfoCurrentParam, DebugInfoFromParam)

Trace a function call.

COORDINATE:_T(Arguments, DebugInfoCurrentParam, DebugInfoFromParam)

Trace a function logic.

COORDINATE.__

COORDINATE:onEvent(event)

Fields and Methods inherited from POINT_VEC2 Description

POINT_VEC2:AddAlt(Altitude)

Add to the current land height an altitude.

POINT_VEC2:AddX(x)

Add to the x coordinate of the POINT_VEC2.

POINT_VEC2:AddY(y)

Add to the y coordinate of the POINT_VEC2.

POINT_VEC2:DistanceFromPointVec2(PointVec2Reference)

POINT_VEC2:GetAlt()

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

POINT_VEC2:GetLat()

Return Return the Lat(itude) coordinate of the POINT_VEC2 (ie: (parent)POINT_VEC3.x).

POINT_VEC2:GetLon()

Return the Lon(gitude) coordinate of the POINT_VEC2 (ie: (parent)POINT_VEC3.z).

POINT_VEC2:GetRandomPointVec2InRadius(OuterRadius, InnerRadius)

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

POINT_VEC2:GetX()

Return the x coordinate of the POINT_VEC2.

POINT_VEC2:GetY()

Return the y coordinate of the POINT_VEC2.

POINT_VEC2:New(x, y, LandHeightAdd)

POINT_VEC2 constructor.

POINT_VEC2:NewFromVec2(Vec2, LandHeightAdd)

Create a new POINT_VEC2 object from Vec2 coordinates.

POINT_VEC2:NewFromVec3(Vec3)

Create a new POINT_VEC2 object from Vec3 coordinates.

POINT_VEC2:SetAlt(Altitude)

Set the altitude of the POINT_VEC2.

POINT_VEC2:SetLat(x)

Set the Lat(itude) coordinate of the POINT_VEC2 (ie: POINT_VEC3.x).

POINT_VEC2:SetLon(y, z)

Set the Lon(gitude) coordinate of the POINT_VEC2 (ie: POINT_VEC3.z).

POINT_VEC2:SetX(x)

Set the x coordinate of the POINT_VEC2.

POINT_VEC2:SetY(y)

Set the y coordinate of the POINT_VEC2.

POINT_VEC2.x

The x coordinate in meters.

POINT_VEC2.y

the y coordinate in meters.

POINT_VEC2.z

Fields and Methods inherited from COORDINATE Description

POINT_VEC2:BigSmokeAndFire(preset, density)

Big smoke and fire at the coordinate.

POINT_VEC2:BigSmokeAndFireHuge(density)

Huge smoke and fire at the coordinate.

POINT_VEC2:BigSmokeAndFireLarge(density)

Large smoke and fire at the coordinate.

POINT_VEC2:BigSmokeAndFireMedium(density)

Medium smoke and fire at the coordinate.

POINT_VEC2:BigSmokeAndFireSmall(density)

Small smoke and fire at the coordinate.

POINT_VEC2:BigSmokeHuge(density)

Huge smoke at the coordinate.

POINT_VEC2:BigSmokeLarge(density)

Large smoke at the coordinate.

POINT_VEC2:BigSmokeMedium(density)

Medium smoke at the coordinate.

POINT_VEC2:BigSmokeSmall(density)

Small smoke at the coordinate.

POINT_VEC2:DistanceFromPointVec2(PointVec2Reference)

Calculate the distance from a reference #COORDINATE.

POINT_VEC2:Explosion(ExplosionIntensity, Delay)

Creates an explosion at the point of a certain intensity.

POINT_VEC2:FindClosestScenery(radius)

Find the closest scenery to the COORDINATE within a certain radius.

POINT_VEC2:FindClosestUnit(radius)

Find the closest unit to the COORDINATE within a certain radius.

POINT_VEC2:Flare(FlareColor, Azimuth)

Flares the point in a color.

POINT_VEC2:FlareGreen(Azimuth)

Flare the COORDINATE Green.

POINT_VEC2:FlareRed(Azimuth)

Flare the COORDINATE Red.

POINT_VEC2:FlareWhite(Azimuth)

Flare the COORDINATE White.

POINT_VEC2:FlareYellow(Azimuth)

Flare the COORDINATE Yellow.

POINT_VEC2:Get2DDistance(TargetCoordinate)

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

POINT_VEC2:Get3DDistance(TargetCoordinate)

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

POINT_VEC2:GetAltitudeText(Settings, Language)

Return the altitude text of the COORDINATE.

POINT_VEC2:GetAngleDegrees(DirectionVec3)

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

POINT_VEC2:GetAngleRadians(DirectionVec3)

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

POINT_VEC2:GetBRAText(AngleRadians, Distance, Settings, Language)

Provides a Bearing / Range / Altitude string

POINT_VEC2:GetBRText(AngleRadians, Distance, Settings, Language)

Provides a Bearing / Range string

POINT_VEC2:GetBearingText(AngleRadians, Precision, Settings, Language)

Provides a bearing text in degrees.

POINT_VEC2:GetClosestAirbase(Category, Coalition)

Gets the nearest airbase with respect to the current coordinates.

POINT_VEC2:GetClosestAirbase2(Category, Coalition)

Gets the nearest airbase with respect to the current coordinates.

POINT_VEC2:GetClosestFreeParkingSpot(airbase, terminaltype)

Gets the nearest free parking spot.

POINT_VEC2:GetClosestOccupiedParkingSpot(airbase, terminaltype)

Gets the nearest occupied parking spot.

POINT_VEC2:GetClosestParkingSpot(airbase, terminaltype, free)

Gets the nearest parking spot.

POINT_VEC2:GetClosestPointToRoad(Railroad)

Gets the nearest coordinate to a road (or railroad).

POINT_VEC2:GetDirectionVec3(TargetCoordinate)

Return a direction vector Vec3 from COORDINATE to the COORDINATE.

POINT_VEC2:GetDistanceText(Distance, Settings, Language)

Provides a distance text expressed in the units of measurement.

POINT_VEC2:GetHeading()

Get the heading of the coordinate, if applicable.

POINT_VEC2:GetHeadingText(Settings)

Return the heading text of the COORDINATE.

POINT_VEC2:GetIntermediateCoordinate(ToCoordinate, Fraction)

Return an intermediate COORDINATE between this an another coordinate.

POINT_VEC2:GetLLDDM()

Get Latitude and Longitude in Degrees Decimal Minutes (DDM).

POINT_VEC2:GetLandHeight()

Return the height of the land at the coordinate.

POINT_VEC2:GetMinutesToSunrise(OnlyToday)

Get minutes until the next sun rise at this coordinate.

POINT_VEC2:GetMinutesToSunset(OnlyToday)

Get minutes until the next sun set at this coordinate.

POINT_VEC2:GetMovingText(Settings)

Return velocity text of the COORDINATE.

POINT_VEC2:GetNorthCorrectionRadians()

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

POINT_VEC2:GetPathOnRoad(ToCoord, IncludeEndpoints, Railroad, MarkPath, SmokePath)

Returns a table of coordinates to a destination using only roads or railroads.

POINT_VEC2:GetPressure(height)

Returns the pressure in hPa.

POINT_VEC2:GetPressureText(height, Settings)

Returns a text of the pressure according the measurement system Settings.

POINT_VEC2:GetRandomCoordinateInRadius(OuterRadius, InnerRadius)

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

POINT_VEC2:GetRandomVec2InRadius(OuterRadius, InnerRadius)

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

POINT_VEC2:GetRandomVec3InRadius(OuterRadius, InnerRadius)

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

POINT_VEC2:GetSunrise(InSeconds)

Get todays sun rise time.

POINT_VEC2:GetSunriseAtDate(Day, Month, Year, InSeconds)

Get sun rise time for a specific date at the coordinate.

POINT_VEC2:GetSunriseAtDayOfYear(DayOfYear, InSeconds)

Get sun rise time for a specific day of the year at the coordinate.

POINT_VEC2:GetSunset(InSeconds)

Get todays sun set time.

POINT_VEC2:GetSunsetAtDate(Day, Month, Year, InSeconds)

Get sun set time for a specific date at the coordinate.

POINT_VEC2:GetSurfaceType()

Gets the surface type at the coordinate.

POINT_VEC2:GetTemperature(height)

Returns the temperature in Degrees Celsius.

POINT_VEC2:GetTemperatureText(height, Settings)

Returns a text of the temperature according the measurement system Settings.

POINT_VEC2:GetVec2()

Return the coordinates of the COORDINATE in Vec2 format.

POINT_VEC2:GetVec3()

Return the coordinates of the COORDINATE in Vec3 format.

POINT_VEC2:GetVelocity()

Return the velocity of the COORDINATE.

POINT_VEC2:GetVelocityText(Settings)

Return the velocity text of the COORDINATE.

POINT_VEC2:GetWind(height)

Returns the wind direction (from) and strength.

POINT_VEC2:GetWindText(height, Settings)

Returns a text documenting the wind direction (from) and strength according the measurement system Settings.

POINT_VEC2:GetWindWithTurbulenceVec3(height)

Returns the wind direction (from) and strength.

POINT_VEC2.Heading

POINT_VEC2:HeadingTo(ToCoordinate)

Returns the heading from this to another coordinate.

POINT_VEC2:IlluminationBomb(power)

Creates an illumination bomb at the point.

POINT_VEC2:IsAtCoordinate2D(Coordinate, Precision)

Returns if the 2 coordinates are at the same 2D position.

POINT_VEC2:IsDay(Clock)

Check if it is day, i.e.

POINT_VEC2:IsInRadius(Coordinate, Radius)

Returns if a Coordinate is in a certain Radius of this Coordinate in 2D plane using the X and Z axis.

POINT_VEC2:IsInSphere(ToCoordinate, Radius, Coordinate)

Returns if a Coordinate is in a certain radius of this Coordinate in 3D space using the X, Y and Z axis.

POINT_VEC2:IsLOS(ToCoordinate, Offset)

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

POINT_VEC2:IsNight(Clock)

Check if it is night, i.e.

POINT_VEC2:IsSurfaceTypeLand()

Checks if the surface type is on land.

POINT_VEC2:IsSurfaceTypeRoad()

Checks if the surface type is road.

POINT_VEC2:IsSurfaceTypeRunway()

Checks if the surface type is runway.

POINT_VEC2:IsSurfaceTypeShallowWater()

Checks if the surface type is shallow water.

POINT_VEC2:IsSurfaceTypeWater()

Checks if the surface type is water.

POINT_VEC2:MarkToAll(MarkText, ReadOnly, Text)

Mark to All

POINT_VEC2:MarkToCoalition(MarkText, Coalition, ReadOnly, Text)

Mark to Coalition

POINT_VEC2:MarkToCoalitionBlue(MarkText, ReadOnly, Text)

Mark to Blue Coalition

POINT_VEC2:MarkToCoalitionRed(MarkText, ReadOnly, Text)

Mark to Red Coalition

POINT_VEC2:MarkToGroup(MarkText, MarkGroup, ReadOnly, Text)

Mark to Group

POINT_VEC2:New(x, y, z)

COORDINATE constructor.

POINT_VEC2:NewFromCoordinate(Coordinate)

COORDINATE constructor.

POINT_VEC2:NewFromLLDD(latitude, longitude, altitude)

Returns the coordinate from the latitude and longitude given in decimal degrees.

POINT_VEC2:NewFromVec2(Vec2, LandHeightAdd)

Create a new COORDINATE object from Vec2 coordinates.

POINT_VEC2:NewFromVec3(Vec3)

Create a new COORDINATE object from Vec3 coordinates.

POINT_VEC2:RemoveMark(MarkID)

Remove a mark

POINT_VEC2:Rotate2D(Angle)

Rotate coordinate in 2D (x,z) space.

POINT_VEC2:ScanObjects(radius, scanunits, scanstatics, scanscenery)

Scan/find objects (units, statics, scenery) within a certain radius around the coordinate using the world.searchObjects() DCS API function.

POINT_VEC2:ScanScenery(radius)

Scan/find SCENERY objects within a certain radius around the coordinate using the world.searchObjects() DCS API function.

POINT_VEC2:ScanUnits(radius)

Scan/find UNITS within a certain radius around the coordinate using the world.searchObjects() DCS API function.

POINT_VEC2:SetAltitude(altitude, asl)

Set altitude.

POINT_VEC2:SetHeading(Heading)

Set the heading of the coordinate, if applicable.

POINT_VEC2:SetVelocity(Velocity)

Set the velocity of the COORDINATE.

POINT_VEC2:Smoke(SmokeColor)

Smokes the point in a color.

POINT_VEC2:SmokeBlue()

Smoke the COORDINATE Blue.

POINT_VEC2:SmokeGreen()

Smoke the COORDINATE Green.

POINT_VEC2:SmokeOrange()

Smoke the COORDINATE Orange.

POINT_VEC2:SmokeRed()

Smoke the COORDINATE Red.

POINT_VEC2:SmokeWhite()

Smoke the COORDINATE White.

POINT_VEC2:ToString(Controllable, Settings, Task)

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

POINT_VEC2:ToStringA2A(Controllable, Settings, Language)

Provides a coordinate string of the point, based on the A2A coordinate format system.

POINT_VEC2:ToStringA2G(Controllable, Settings)

Provides a coordinate string of the point, based on the A2G coordinate format system.

POINT_VEC2:ToStringAspect(TargetCoordinate)

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

POINT_VEC2:ToStringBR(FromCoordinate, Settings)

Return a BR string from a COORDINATE to the COORDINATE.

POINT_VEC2:ToStringBRA(FromCoordinate, Settings, Language)

Return a BRAA string from a COORDINATE to the COORDINATE.

POINT_VEC2:ToStringBULLS(Coalition, Settings)

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

POINT_VEC2:ToStringFromRP(ReferenceCoord, ReferenceName, Controllable, Settings)

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

POINT_VEC2:ToStringLLDDM(Settings)

Provides a Lat Lon string in Degree Decimal Minute format.

POINT_VEC2:ToStringLLDMS(Settings)

Provides a Lat Lon string in Degree Minute Second format.

POINT_VEC2:ToStringMGRS(Settings)

Provides a MGRS string

POINT_VEC2:ToStringPressure(Controllable, Settings)

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

POINT_VEC2:ToStringTemperature(Controllable, Core, Settings)

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

POINT_VEC2:ToStringWind(Controllable, Settings)

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

POINT_VEC2:Translate(Distance, Angle, Keepalt, Overwrite)

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

POINT_VEC2:UpdateFromCoordinate(Coordinate)

Update x,y,z coordinates from another given COORDINATE.

POINT_VEC2:UpdateFromVec2(Vec2)

Update x and z coordinates from a given 2D vector.

POINT_VEC2:UpdateFromVec3(Vec3)

Update x,y,z coordinates from a given 3D vector.

POINT_VEC2.Velocity

POINT_VEC2.WaypointAction

POINT_VEC2:WaypointAir(AltType, Type, Action, Speed, SpeedLocked, airbase, DCSTasks, description, timeReFuAr)

Build an air type route point.

POINT_VEC2:WaypointAirFlyOverPoint(AltType, Speed)

Build a Waypoint Air "Fly Over Point".

POINT_VEC2:WaypointAirLanding(Speed, airbase, DCSTasks, description)

Build a Waypoint Air "Landing".

POINT_VEC2:WaypointAirLandingReFu(Speed, airbase, timeReFuAr, DCSTasks, description)

Build a Waypoint Air "LandingReFuAr".

POINT_VEC2:WaypointAirTakeOffParking(AltType, Speed)

Build a Waypoint Air "Take Off Parking".

POINT_VEC2:WaypointAirTakeOffParkingHot(AltType, Speed)

Build a Waypoint Air "Take Off Parking Hot".

POINT_VEC2:WaypointAirTakeOffRunway(AltType, Speed)

Build a Waypoint Air "Take Off Runway".

POINT_VEC2:WaypointAirTurningPoint(AltType, Speed, DCSTasks, description)

Build a Waypoint Air "Turning Point".

POINT_VEC2.WaypointAltType

POINT_VEC2:WaypointGround(Speed, Formation, DCSTasks)

Build an ground type route point.

POINT_VEC2:WaypointNaval(Speed, Depth, DCSTasks)

Build route waypoint point for Naval units.

POINT_VEC2.WaypointType

POINT_VEC2.x

POINT_VEC2.y

POINT_VEC2.z

Fields and Methods inherited from BASE Description

POINT_VEC2.ClassID

The ID number of the class.

POINT_VEC2.ClassName

The name of the class.

POINT_VEC2.ClassNameAndID

The name of the class concatenated with the ID number of the class.

POINT_VEC2:ClearState(Object, StateName)

Clear the state of an object.

POINT_VEC2:CreateEventBirth(EventTime, Initiator, IniUnitName, place, subplace)

Creation of a Birth Event.

POINT_VEC2:CreateEventCrash(EventTime, Initiator)

Creation of a Crash Event.

POINT_VEC2:CreateEventDead(EventTime, Initiator)

Creation of a Dead Event.

POINT_VEC2:CreateEventRemoveUnit(EventTime, Initiator)

Creation of a Remove Unit Event.

POINT_VEC2:CreateEventTakeoff(EventTime, Initiator)

Creation of a Takeoff Event.

POINT_VEC2:CreateEventUnitLost(EventTime, Initiator)

Creation of a Crash Event.

POINT_VEC2:E(Arguments)

Log an exception which will be traced always.

POINT_VEC2:EventDispatcher()

Returns the event dispatcher

POINT_VEC2:EventRemoveAll()

Remove all subscribed events

POINT_VEC2:F(Arguments)

Trace a function call.

POINT_VEC2:F2(Arguments)

Trace a function call level 2.

POINT_VEC2:F3(Arguments)

Trace a function call level 3.

POINT_VEC2:GetClassID()

Get the ClassID of the class instance.

POINT_VEC2:GetClassName()

Get the ClassName of the class instance.

POINT_VEC2:GetClassNameAndID()

Get the ClassName + ClassID of the class instance.

POINT_VEC2:GetEventPriority()

Get the Class Event processing Priority.

POINT_VEC2:GetParent(Child, FromClass)

This is the worker method to retrieve the Parent class.

POINT_VEC2:GetState(Object, Key)

Get a Value given a Key from the Object.

POINT_VEC2:HandleEvent(Event, EventFunction)

Subscribe to a DCS Event.

POINT_VEC2:I(Arguments)

Log an information which will be traced always.

POINT_VEC2:Inherit(Child, Parent)

This is the worker method to inherit from a parent class.

POINT_VEC2:IsInstanceOf(ClassName)

This is the worker method to check if an object is an (sub)instance of a class.

POINT_VEC2:IsTrace()

Enquires if tracing is on (for the class).

POINT_VEC2:New()

BASE constructor.

POINT_VEC2:OnEvent(EventData)

Occurs when an object is completely destroyed.

POINT_VEC2:OnEventBaseCaptured(EventData)

Occurs when a ground unit captures either an airbase or a farp.

POINT_VEC2:OnEventBirth(EventData)

Occurs when any object is spawned into the mission.

POINT_VEC2:OnEventCrash(EventData)

Occurs when any aircraft crashes into the ground and is completely destroyed.

POINT_VEC2:OnEventDead(EventData)

Occurs when an object is dead.

POINT_VEC2:OnEventDetailedFailure(EventData)

Unknown precisely what creates this event, likely tied into newer damage model.

POINT_VEC2:OnEventEjection(EventData)

Occurs when a pilot ejects from an aircraft initiator : The unit that has ejected

POINT_VEC2:OnEventEngineShutdown(EventData)

Occurs when any aircraft shuts down its engines.

POINT_VEC2:OnEventEngineStartup(EventData)

Occurs when any aircraft starts its engines.

POINT_VEC2:OnEventHit(EventData)

Occurs whenever an object is hit by a weapon.

POINT_VEC2:OnEventHumanFailure(EventData)

Occurs when any system fails on a human controlled aircraft.

POINT_VEC2:OnEventKill(EventData)

Occurs on the death of a unit.

POINT_VEC2:OnEventLand(EventData)

Occurs when an aircraft lands at an airbase, farp or ship initiator : The unit that has landed place: Object that the unit landed on.

POINT_VEC2:OnEventLandingAfterEjection(EventData)

Occurs shortly after the landing animation of an ejected pilot touching the ground and standing up.

POINT_VEC2:OnEventMarkAdded(EventData)

Occurs when a new mark was added.

POINT_VEC2:OnEventMarkChange(EventData)

Occurs when a mark text was changed.

POINT_VEC2:OnEventMarkRemoved(EventData)

Occurs when a mark was removed.

POINT_VEC2:OnEventMissionEnd(EventData)

Occurs when a mission ends

POINT_VEC2:OnEventMissionStart(EventData)

Occurs when a mission starts

POINT_VEC2:OnEventPilotDead(EventData)

Occurs when the pilot of an aircraft is killed.

POINT_VEC2:OnEventPlayerEnterUnit(EventData)

Occurs when any player assumes direct control of a unit.

POINT_VEC2:OnEventPlayerLeaveUnit(EventData)

Occurs when any player relieves control of a unit to the AI.

POINT_VEC2:OnEventRefueling(EventData)

Occurs when an aircraft connects with a tanker and begins taking on fuel.

POINT_VEC2:OnEventRefuelingStop(EventData)

Occurs when an aircraft is finished taking fuel.

POINT_VEC2:OnEventScore(EventData)

Occurs when any modification to the "Score" as seen on the debrief menu would occur.

POINT_VEC2:OnEventShootingEnd(EventData)

Occurs when any unit stops firing its weapon.

POINT_VEC2:OnEventShootingStart(EventData)

Occurs when any unit begins firing a weapon that has a high rate of fire.

POINT_VEC2:OnEventShot(EventData)

Occurs whenever any unit in a mission fires a weapon.

POINT_VEC2:OnEventTakeoff(EventData)

Occurs when an aircraft takes off from an airbase, farp, or ship.

POINT_VEC2:OnEventUnitLost(EventData)

Occurs when the game thinks an object is destroyed.

POINT_VEC2:ScheduleOnce(Start, SchedulerFunction, ...)

Schedule a new time event.

POINT_VEC2:ScheduleRepeat(Start, Repeat, RandomizeFactor, Stop, SchedulerFunction, ...)

Schedule a new time event.

POINT_VEC2:ScheduleStop(SchedulerFunction)

Stops the Schedule.

POINT_VEC2.Scheduler

POINT_VEC2:SetEventPriority(EventPriority)

Set the Class Event processing Priority.

POINT_VEC2:SetState(Object, Key, Value)

Set a state or property of the Object given a Key and a Value.

POINT_VEC2:T(Arguments)

Trace a function logic level 1.

POINT_VEC2:T2(Arguments)

Trace a function logic level 2.

POINT_VEC2:T3(Arguments)

Trace a function logic level 3.

POINT_VEC2:TraceAll(TraceAll)

Trace all methods in MOOSE

POINT_VEC2:TraceClass(Class)

Set tracing for a class

POINT_VEC2:TraceClassMethod(Class, Method)

Set tracing for a specific method of class

POINT_VEC2:TraceLevel(Level)

Set trace level

POINT_VEC2:TraceOff()

Set trace off.

POINT_VEC2:TraceOn()

Set trace on.

POINT_VEC2:TraceOnOff(TraceOnOff)

Set trace on or off Note that when trace is off, no BASE.Debug statement is performed, increasing performance! When Moose is loaded statically, (as one file), tracing is switched off by default.

POINT_VEC2:UnHandleEvent(Event)

UnSubscribe to a DCS event.

POINT_VEC2._

POINT_VEC2:_F(Arguments, DebugInfoCurrentParam, DebugInfoFromParam)

Trace a function call.

POINT_VEC2:_T(Arguments, DebugInfoCurrentParam, DebugInfoFromParam)

Trace a function logic.

POINT_VEC2.__

POINT_VEC2:onEvent(event)

Fields and Methods inherited from POINT_VEC3 Description

POINT_VEC3:AddX(x)

Add to the x coordinate of the POINT_VEC3.

POINT_VEC3:AddY(y)

Add to the y coordinate of the POINT_VEC3.

POINT_VEC3:AddZ(z)

Add to the z coordinate of the POINT_VEC3.

POINT_VEC3.FlareColor

POINT_VEC3:GetRandomPointVec3InRadius(OuterRadius, InnerRadius)

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

POINT_VEC3:GetX()

Return the x coordinate of the POINT_VEC3.

POINT_VEC3:GetY()

Return the y coordinate of the POINT_VEC3.

POINT_VEC3:GetZ()

Return the z coordinate of the POINT_VEC3.

POINT_VEC3:New(x, y, z)

Create a new POINT_VEC3 object.

POINT_VEC3:NewFromVec2(Vec2, LandHeightAdd)

Create a new POINT_VEC3 object from Vec2 coordinates.

POINT_VEC3:NewFromVec3(Vec3)

Create a new POINT_VEC3 object from Vec3 coordinates.

POINT_VEC3.RoutePointAction

POINT_VEC3.RoutePointAltType

POINT_VEC3.RoutePointType

POINT_VEC3:SetX(x)

Set the x coordinate of the POINT_VEC3.

POINT_VEC3:SetY(y)

Set the y coordinate of the POINT_VEC3.

POINT_VEC3:SetZ(z)

Set the z coordinate of the POINT_VEC3.

POINT_VEC3.SmokeColor

POINT_VEC3.x

The x coordinate in 3D space.

POINT_VEC3.y

The y coordinate in 3D space.

POINT_VEC3.z

The z coordiante in 3D space.

Fields and Methods inherited from POINT_VEC3.RoutePointAction Description

POINT_VEC3.RoutePointAction.FromParkingArea

"From Parking Area"

POINT_VEC3.RoutePointAction.TurningPoint

"Turning Point"

Fields and Methods inherited from POINT_VEC3.RoutePointAltType Description

POINT_VEC3.RoutePointAltType.BARO

"BARO"

Fields and Methods inherited from POINT_VEC3.RoutePointType Description

POINT_VEC3.RoutePointType.TakeOffParking

"TakeOffParking"

POINT_VEC3.RoutePointType.TurningPoint

"Turning Point"

Field(s)

Function(s)

Big smoke and fire at the coordinate.

Defined in:

COORDINATE

Parameters:

Smoke preset (0=small smoke and fire, 1=medium smoke and fire, 2=large smoke and fire, 3=huge smoke and fire, 4=small smoke, 5=medium smoke, 6=large smoke, 7=huge smoke).

#number density

(Optional) Smoke density. Number in [0,...,1]. Default 0.5.

Huge smoke and fire at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Large smoke and fire at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Medium smoke and fire at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Small smoke and fire at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Huge smoke at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Large smoke at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Medium smoke at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Small smoke at the coordinate.

Defined in:

COORDINATE

Parameter:

density

Calculate the distance from a reference #COORDINATE.

Defined in:

COORDINATE

Parameter:

#COORDINATE PointVec2Reference

The reference #COORDINATE.

Return value:

The distance from the reference #COORDINATE in meters.

Creates an explosion at the point of a certain intensity.

Defined in:

COORDINATE

Parameters:

#number ExplosionIntensity

Intensity of the explosion in kg TNT. Default 100 kg.

#number Delay

Delay before explosion in seconds.

Return value:

self

Find the closest scenery to the COORDINATE within a certain radius.

Defined in:

COORDINATE

Parameter:

#number radius

Scan radius in meters. Default 100 m.

Return value:

The closest scenery or #nil if no object is inside the given radius.

Find the closest unit to the COORDINATE within a certain radius.

Defined in:

COORDINATE

Parameter:

#number radius

Scan radius in meters. Default 100 m.

Return value:

The closest unit or #nil if no unit is inside the given radius.

Flares the point in a color.

Defined in:

COORDINATE

Parameters:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

Flare the COORDINATE Green.

Defined in:

COORDINATE

Parameter:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

Flare the COORDINATE Red.

Defined in:

COORDINATE

Parameter:

Azimuth

Flare the COORDINATE White.

Defined in:

COORDINATE

Parameter:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

Flare the COORDINATE Yellow.

Defined in:

COORDINATE

Parameter:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

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

Defined in:

COORDINATE

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE. Can also be a DCS#Vec3.

Return value:

Distance The distance in meters.

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

Defined in:

COORDINATE

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE.

Return value:

Distance The distance in meters.

Return the altitude text of the COORDINATE.

Defined in:

COORDINATE

Parameters:

Settings

Language

Return value:

#string:

Altitude text.

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

Defined in:

COORDINATE

Parameter:

DCS#Vec3 DirectionVec3

The direction vector in Vec3 format.

Return value:

#number:

DirectionRadians The angle in degrees.

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

Defined in:

COORDINATE

Parameter:

DCS#Vec3 DirectionVec3

The direction vector in Vec3 format.

Return value:

#number:

DirectionRadians The angle in radians.

Provides a Bearing / Range / Altitude string

Defined in:

COORDINATE

Parameters:

#number AngleRadians

The angle in randians

#number Distance

The distance

Language

Return value:

#string:

The BRA Text

Provides a Bearing / Range string

Defined in:

COORDINATE

Parameters:

#number AngleRadians

The angle in randians

#number Distance

The distance

Language

Return value:

#string:

The BR Text

Provides a bearing text in degrees.

Defined in:

COORDINATE

Parameters:

#number AngleRadians

The angle in randians.

#number Precision

The precision.

Language

Return value:

#string:

The bearing text in degrees.

Gets the nearest airbase with respect to the current coordinates.

Defined in:

COORDINATE

Parameters:

#number Category

(Optional) Category of the airbase. Enumerator of Wrapper.Airbase#AIRBASE.Category.

#number Coalition

(Optional) Coalition of the airbase.

Return values:

Closest Airbase to the given coordinate.

#number:

Distance to the closest airbase in meters.

Gets the nearest airbase with respect to the current coordinates.

Defined in:

COORDINATE

Parameters:

#number Category

(Optional) Category of the airbase. Enumerator of Wrapper.Airbase#AIRBASE.Category.

#number Coalition

(Optional) Coalition of the airbase.

Return values:

Closest Airbase to the given coordinate.

#number:

Distance to the closest airbase in meters.

Gets the nearest free parking spot.

Defined in:

COORDINATE

Parameters:

(Optional) Search only parking spots at that airbase.

(Optional) Type of the terminal.

Return values:

Coordinate of the nearest free parking spot.

#number:

Terminal ID.

#number:

Distance to closest free parking spot in meters.

Gets the nearest occupied parking spot.

Defined in:

COORDINATE

Parameters:

(Optional) Search only parking spots at that airbase.

(Optional) Type of the terminal.

Return values:

Coordinate of the nearest occupied parking spot.

#number:

Terminal ID.

#number:

Distance to closest occupied parking spot in meters.

Gets the nearest parking spot.

Defined in:

COORDINATE

Parameters:

(Optional) Search only parking spots at this airbase.

(Optional) Type of the terminal. Default any execpt valid spawn points on runway.

#boolean free

(Optional) If true, returns the closest free spot. If false, returns the closest occupied spot. If nil, returns the closest spot regardless of free or occupied.

Return values:

Coordinate of the nearest parking spot.

#number:

Terminal ID.

#number:

Distance to closest parking spot in meters.

ParkingSpot Parking spot table.

Gets the nearest coordinate to a road (or railroad).

Defined in:

COORDINATE

Parameter:

#boolean Railroad

(Optional) If true, closest point to railroad is returned rather than closest point to conventional road. Default false.

Return value:

Coordinate of the nearest road.

Return a direction vector Vec3 from COORDINATE to the COORDINATE.

Defined in:

COORDINATE

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE.

Return value:

DirectionVec3 The direction vector in Vec3 format.

Provides a distance text expressed in the units of measurement.

Defined in:

COORDINATE

Parameters:

#number Distance

The distance in meters.

Language

Return value:

#string:

The distance text expressed in the units of measurement.

Get the heading of the coordinate, if applicable.

Defined in:

COORDINATE

Return value:

#number:

or nil

Return the heading text of the COORDINATE.

Defined in:

COORDINATE

Parameter:

Settings

Return value:

#string:

Heading text.

Return an intermediate COORDINATE between this an another coordinate.

Defined in:

COORDINATE

Parameters:

#COORDINATE ToCoordinate

The other coordinate.

#number Fraction

The fraction (0,1) where the new coordinate is created. Default 0.5, i.e. in the middle.

Return value:

Coordinate between this and the other coordinate.

Get Latitude and Longitude in Degrees Decimal Minutes (DDM).

Defined in:

COORDINATE

Return values:

#number:

Latitude in DDM.

#number:

Lontitude in DDM.

Return the height of the land at the coordinate.

Defined in:

COORDINATE

Return value:

#number:

Land height (ASL) in meters.

Get minutes until the next sun rise at this coordinate.

Defined in:

COORDINATE

Parameter:

OnlyToday

If true, only calculate the sun rise of today. If sun has already risen, the time in negative minutes since sunrise is reported.

Return value:

#number:

Minutes to the next sunrise.

Get minutes until the next sun set at this coordinate.

Defined in:

COORDINATE

Parameter:

OnlyToday

If true, only calculate the sun set of today. If sun has already set, the time in negative minutes since sunset is reported.

Return value:

#number:

Minutes to the next sunrise.

Return velocity text of the COORDINATE.

Defined in:

COORDINATE

Parameter:

Settings

Return value:

#string:

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

Defined in:

COORDINATE

Return value:

#number:

CorrectionRadians The correction in radians.

Returns a table of coordinates to a destination using only roads or railroads.

The first point is the closest point on road of the given coordinate. By default, the last point is the closest point on road of the ToCoord. Hence, the coordinate itself and the final ToCoord are not necessarily included in the path.

Defined in:

COORDINATE

Parameters:

#COORDINATE ToCoord

Coordinate of destination.

#boolean IncludeEndpoints

(Optional) Include the coordinate itself and the ToCoordinate in the path.

#boolean Railroad

(Optional) If true, path on railroad is returned. Default false.

#boolean MarkPath

(Optional) If true, place markers on F10 map along the path.

#boolean SmokePath

(Optional) If true, put (green) smoke along the

Return values:

#table:

Table of coordinates on road. If no path on road can be found, nil is returned or just the endpoints.

#number:

Tonal length of path.

#boolean:

If true a valid path on road/rail was found. If false, only the direct way is possible.

Returns the pressure in hPa.

Defined in:

COORDINATE

Parameter:

height

(Optional) parameter specifying the height ASL. E.g. set height=0 for QNH.

Return value:

Pressure in hPa.

Returns a text of the pressure according the measurement system Settings.

The text will contain always the pressure in hPa and:

  • For Russian and European aircraft using the metric system - hPa and mmHg
  • For Americain and European aircraft we link to the imperial system - hPa and inHg

A text containing a pressure will look like this:

  • QFE: x hPa (y mmHg)
  • QFE: x hPa (y inHg)

Defined in:

COORDINATE

Parameters:

height

(Optional) parameter specifying the height ASL. E.g. set height=0 for QNH.

Settings

Return value:

#string:

Pressure in hPa and mmHg or inHg depending on the measurement system Settings.

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

Defined in:

COORDINATE

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

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

Defined in:

COORDINATE

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

Vec2

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

Defined in:

COORDINATE

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

Vec3

Get todays sun rise time.

Defined in:

COORDINATE

Parameter:

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunrise time, e.g. "05:41".

Get sun rise time for a specific date at the coordinate.

Defined in:

COORDINATE

Parameters:

#number Day

The day.

#number Month

The month.

#number Year

The year.

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunrise time, e.g. "05:41".

Get sun rise time for a specific day of the year at the coordinate.

Defined in:

COORDINATE

Parameters:

#number DayOfYear

The day of the year.

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunrise time, e.g. "05:41".

Get todays sun set time.

Defined in:

COORDINATE

Parameter:

#boolean InSeconds

If true, return the sun set time in seconds.

Return value:

#string:

Sunrise time, e.g. "20:41".

Get sun set time for a specific date at the coordinate.

Defined in:

COORDINATE

Parameters:

#number Day

The day.

#number Month

The month.

#number Year

The year.

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunset time, e.g. "20:41".

Gets the surface type at the coordinate.

Defined in:

COORDINATE

Return value:

Surface type.

Returns the temperature in Degrees Celsius.

Defined in:

COORDINATE

Parameter:

height

(Optional) parameter specifying the height ASL.

Return value:

Temperature in Degrees Celsius.

Returns a text of the temperature according the measurement system Settings.

The text will reflect the temperature like this:

  • For Russian and European aircraft using the metric system - Degrees Celcius (°C)
  • For Americain aircraft we link to the imperial system - Degrees Farenheit (°F)

A text containing a pressure will look like this:

  • Temperature: %n.d °C
  • Temperature: %n.d °F

Defined in:

COORDINATE

Parameters:

height

(Optional) parameter specifying the height ASL.

Settings

Return value:

#string:

Temperature according the measurement system Settings.

Return the coordinates of the COORDINATE in Vec2 format.

Defined in:

COORDINATE

Return value:

The Vec2 format coordinate.

Return the coordinates of the COORDINATE in Vec3 format.

Defined in:

COORDINATE

Return value:

The Vec3 format coordinate.

Return the velocity of the COORDINATE.

Defined in:

COORDINATE

Return value:

#number:

Velocity in meters per second.

Return the velocity text of the COORDINATE.

Defined in:

COORDINATE

Parameter:

Settings

Return value:

#string:

Velocity text.

Returns the wind direction (from) and strength.

Defined in:

COORDINATE

Parameter:

height

(Optional) parameter specifying the height ASL. The minimum height will be always be the land height since the wind is zero below the ground.

Return values:

Direction the wind is blowing from in degrees.

Wind strength in m/s.

Returns a text documenting the wind direction (from) and strength according the measurement system Settings.

The text will reflect the wind like this:

  • For Russian and European aircraft using the metric system - Wind direction in degrees (°) and wind speed in meters per second (mps).
  • For Americain aircraft we link to the imperial system - Wind direction in degrees (°) and wind speed in knots per second (kps).

A text containing a pressure will look like this:

  • Wind: %n ° at n.d mps
  • Wind: %n ° at n.d kps

Defined in:

COORDINATE

Parameters:

height

(Optional) parameter specifying the height ASL. The minimum height will be always be the land height since the wind is zero below the ground.

Settings

Return value:

#string:

Wind direction and strength according the measurement system Settings.

Returns the wind direction (from) and strength.

Defined in:

COORDINATE

Parameter:

height

(Optional) parameter specifying the height ASL. The minimum height will be always be the land height since the wind is zero below the ground.

Return value:

Direction the wind is blowing from in degrees.

Returns the heading from this to another coordinate.

Defined in:

COORDINATE

Parameter:

#COORDINATE ToCoordinate

Return value:

#number:

Heading in degrees.

Creates an illumination bomb at the point.

Defined in:

COORDINATE

Parameter:

#number power

Power of illumination bomb in Candela.

Return value:

self

Returns if the 2 coordinates are at the same 2D position.

Defined in:

COORDINATE

Parameters:

#COORDINATE Coordinate

#number Precision

Return value:

#boolean:

true if at the same position.

Check if it is day, i.e.

if the sun has risen about the horizon at this coordinate.

Defined in:

COORDINATE

Parameter:

#string Clock

(Optional) Time in format "HH:MM:SS+D", e.g. "05:40:00+3" to check if is day at 5:40 at third day after mission start. Default is to check right now.

Return value:

#boolean:

If true, it is day. If false, it is night time.

Returns if a Coordinate is in a certain Radius of this Coordinate in 2D plane using the X and Z axis.

Defined in:

COORDINATE

Parameters:

#COORDINATE Coordinate

The coordinate that will be tested if it is in the radius of this coordinate.

#number Radius

The radius of the circle on the 2D plane around this coordinate.

Return value:

#boolean:

true if in the Radius.

Returns if a Coordinate is in a certain radius of this Coordinate in 3D space using the X, Y and Z axis.

So Radius defines the radius of the a Sphere in 3D space around this coordinate.

Defined in:

COORDINATE

Parameters:

#COORDINATE ToCoordinate

The coordinate that will be tested if it is in the radius of this coordinate.

#number Radius

The radius of the sphere in the 3D space around this coordinate.

Coordinate

Return value:

#boolean:

true if in the Sphere.

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

Defined in:

COORDINATE

Parameters:

#COORDINATE ToCoordinate

#number Offset

Height offset in meters. Default 2 m.

Return value:

#boolean:

true If the ToCoordinate has LOS with the Coordinate, otherwise false.

Check if it is night, i.e.

if the sun has set below the horizon at this coordinate.

Defined in:

COORDINATE

Parameter:

#string Clock

(Optional) Time in format "HH:MM:SS+D", e.g. "05:40:00+3" to check if is night at 5:40 at third day after mission start. Default is to check right now.

Return value:

#boolean:

If true, it is night. If false, it is day time.

Checks if the surface type is on land.

Defined in:

COORDINATE

Return value:

#boolean:

If true, the surface type at the coordinate is land.

Checks if the surface type is road.

Defined in:

COORDINATE

Return value:

#boolean:

If true, the surface type at the coordinate is a road.

Checks if the surface type is runway.

Defined in:

COORDINATE

Return value:

#boolean:

If true, the surface type at the coordinate is a runway or taxi way.

Checks if the surface type is shallow water.

Defined in:

COORDINATE

Return value:

#boolean:

If true, the surface type at the coordinate is a shallow water.

Checks if the surface type is water.

Defined in:

COORDINATE

Return value:

#boolean:

If true, the surface type at the coordinate is a deep water.

Mark to All

Defined in:

COORDINATE

Parameters:

#string MarkText

Free format text that shows the marking clarification.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToAll( "This is a target for all players" )

Mark to Coalition

Defined in:

COORDINATE

Parameters:

#string MarkText

Free format text that shows the marking clarification.

Coalition

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToCoalition( "This is a target for the red coalition", coalition.side.RED )

Mark to Blue Coalition

Defined in:

COORDINATE

Parameters:

#string MarkText

Free format text that shows the marking clarification.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToCoalitionBlue( "This is a target for the blue coalition" )

Mark to Red Coalition

Defined in:

COORDINATE

Parameters:

#string MarkText

Free format text that shows the marking clarification.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToCoalitionRed( "This is a target for the red coalition" )

Mark to Group

Defined in:

COORDINATE

Parameters:

#string MarkText

Free format text that shows the marking clarification.

The Wrapper.Group that receives the mark.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkGroup = GROUP:FindByName( "AttackGroup" )
  local MarkID = TargetCoord:MarkToGroup( "This is a target for the attack group", AttackGroup )

COORDINATE constructor.

Defined in:

COORDINATE

Parameters:

The x coordinate of the Vec3 point, pointing to the North.

The y coordinate of the Vec3 point, pointing to the Right.

The z coordinate of the Vec3 point, pointing to the Right.

Return value:

COORDINATE constructor.

Defined in:

COORDINATE

Parameter:

#COORDINATE Coordinate

Return value:

Returns the coordinate from the latitude and longitude given in decimal degrees.

Defined in:

COORDINATE

Parameters:

#number latitude

Latitude in decimal degrees.

#number longitude

Longitude in decimal degrees.

#number altitude

(Optional) Altitude in meters. Default is the land height at the coordinate.

Return value:

Create a new COORDINATE object from Vec2 coordinates.

Defined in:

COORDINATE

Parameters:

DCS#Vec2 Vec2

The Vec2 point.

DCS#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.

Return value:

Create a new COORDINATE object from Vec3 coordinates.

Defined in:

COORDINATE

Parameter:

DCS#Vec3 Vec3

The Vec3 point.

Return value:

Remove a mark

Defined in:

COORDINATE

Parameter:

#number MarkID

The ID of the mark to be removed.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkGroup = GROUP:FindByName( "AttackGroup" )
  local MarkID = TargetCoord:MarkToGroup( "This is a target for the attack group", AttackGroup )
  <<< logic >>>
  RemoveMark( MarkID ) -- The mark is now removed

Rotate coordinate in 2D (x,z) space.

Defined in:

COORDINATE

Parameter:

DCS#Angle Angle

Angle of rotation in degrees.

Return value:

The rotated coordinate.

Scan/find objects (units, statics, scenery) within a certain radius around the coordinate using the world.searchObjects() DCS API function.

Defined in:

COORDINATE

Parameters:

#number radius

(Optional) Scan radius in meters. Default 100 m.

#boolean scanunits

(Optional) If true scan for units. Default true.

#boolean scanstatics

(Optional) If true scan for static objects. Default true.

#boolean scanscenery

(Optional) If true scan for scenery objects. Default false.

Return values:

#boolean:

True if units were found.

#boolean:

True if statics were found.

#boolean:

True if scenery objects were found.

#table:

Table of MOOSE Wrapper.Unit#UNIT objects found.

#table:

Table of DCS static objects found.

#table:

Table of DCS scenery objects found.

Scan/find SCENERY objects within a certain radius around the coordinate using the world.searchObjects() DCS API function.

Defined in:

COORDINATE

Parameter:

#number radius

(Optional) Scan radius in meters. Default 100 m.

Return value:

table Set of scenery objects.

Scan/find UNITS within a certain radius around the coordinate using the world.searchObjects() DCS API function.

Defined in:

COORDINATE

Parameter:

#number radius

(Optional) Scan radius in meters. Default 100 m.

Return value:

Set of units.

Set altitude.

Defined in:

COORDINATE

Parameters:

#number altitude

New altitude in meters.

#boolean asl

Altitude above sea level. Default is above ground level.

Return value:

The COORDINATE with adjusted altitude.

Set the heading of the coordinate, if applicable.

Defined in:

COORDINATE

Parameter:

Heading

Set the velocity of the COORDINATE.

Defined in:

COORDINATE

Parameter:

#string Velocity

Velocity in meters per second.

Smokes the point in a color.

Defined in:

COORDINATE

Parameter:

Smoke the COORDINATE Blue.

Defined in:

COORDINATE

Smoke the COORDINATE Green.

Defined in:

COORDINATE

Smoke the COORDINATE Orange.

Defined in:

COORDINATE

Smoke the COORDINATE Red.

Defined in:

COORDINATE

Smoke the COORDINATE White.

Defined in:

COORDINATE

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

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

Defined in:

COORDINATE

Parameters:

The controllable to retrieve the settings from, otherwise the default settings will be chosen.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

The task for which coordinates need to be calculated.

Return value:

#string:

The coordinate Text in the configured coordinate system.

Provides a coordinate string of the point, based on the A2A coordinate format system.

Defined in:

COORDINATE

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Language

Return value:

#string:

The coordinate Text in the configured coordinate system.

Provides a coordinate string of the point, based on the A2G coordinate format system.

Defined in:

COORDINATE

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The coordinate Text in the configured coordinate system.

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

Defined in:

COORDINATE

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE.

Return value:

#string:

The Aspect string, which is Hot, Cold or Flanking.

Return a BR string from a COORDINATE to the COORDINATE.

Defined in:

COORDINATE

Parameters:

#COORDINATE FromCoordinate

The coordinate to measure the distance and the bearing from.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The BR text.

Return a BRAA string from a COORDINATE to the COORDINATE.

Defined in:

COORDINATE

Parameters:

#COORDINATE FromCoordinate

The coordinate to measure the distance and the bearing from.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Language

Return value:

#string:

The BR text.

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

Defined in:

COORDINATE

Parameters:

DCS#coalition.side Coalition

The coalition.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The BR text.

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

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

Defined in:

COORDINATE

Parameters:

#COORDINATE ReferenceCoord

The refrence coordinate.

#string ReferenceName

The refrence name.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The coordinate Text in the configured coordinate system.

Provides a Lat Lon string in Degree Decimal Minute format.

Defined in:

COORDINATE

Parameter:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The LL DDM Text

Provides a Lat Lon string in Degree Minute Second format.

Defined in:

COORDINATE

Parameter:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The LL DMS Text

Provides a MGRS string

Defined in:

COORDINATE

Parameter:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The MGRS Text

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

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

Defined in:

COORDINATE

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The pressure text in the configured measurement system.

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

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

Defined in:

COORDINATE

Parameters:

Core

Settings#SETTINGS

Settings

Return value:

#string:

The temperature text in the configured measurement system.

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

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

Defined in:

COORDINATE

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The wind text in the configured measurement system.

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

Defined in:

COORDINATE

Parameters:

DCS#Distance Distance

The Distance to be added in meters.

DCS#Angle Angle

The Angle in degrees. Defaults to 0 if not specified (nil).

#boolean Keepalt

If true, keep altitude of original coordinate. Default is that the new coordinate is created at the translated land height.

#boolean Overwrite

If true, overwrite the original COORDINATE with the translated one. Otherwise, create a new COODINATE.

Return value:

The new calculated COORDINATE.

Update x,y,z coordinates from another given COORDINATE.

Defined in:

COORDINATE

Parameter:

#COORDINATE Coordinate

The coordinate with the new x,y,z positions.

Return value:

The modified COORDINATE itself.

Update x and z coordinates from a given 2D vector.

Defined in:

COORDINATE

Parameter:

DCS#Vec2 Vec2

The 2D vector with x,y components. x is overwriting COORDINATE.x while y is overwriting COORDINATE.z.

Return value:

The modified COORDINATE itself.

Update x,y,z coordinates from a given 3D vector.

Defined in:

COORDINATE

Parameter:

DCS#Vec3 Vec3

The 3D vector with x,y,z components.

Return value:

The modified COORDINATE itself.

Build an air type route point.

Defined in:

COORDINATE

Parameters:

The altitude type.

The route point type.

The route point action.

DCS#Speed Speed

Airspeed in km/h. Default is 500 km/h.

#boolean SpeedLocked

true means the speed is locked.

The airbase for takeoff and landing points.

#table DCSTasks

A table of DCS#Task items which are executed at the waypoint.

#string description

A text description of the waypoint, which will be shown on the F10 map.

#number timeReFuAr

Time in minutes the aircraft stays at the airport for ReFueling and ReArming.

Return value:

#table:

The route point.

Build a Waypoint Air "Fly Over Point".

Defined in:

COORDINATE

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Landing".

Defined in:

COORDINATE

Parameters:

DCS#Speed Speed

Airspeed in km/h.

The airbase for takeoff and landing points.

#table DCSTasks

A table of DCS#Task items which are executed at the waypoint.

#string description

A text description of the waypoint, which will be shown on the F10 map.

Return value:

#table:

The route point.

Usage:


   LandingZone = ZONE:New( "LandingZone" )
   LandingCoord = LandingZone:GetCoordinate()
   LandingWaypoint = LandingCoord:WaypointAirLanding( 60 )
   HeliGroup:Route( { LandWaypoint }, 1 ) -- Start landing the helicopter in one second.

Build a Waypoint Air "LandingReFuAr".

Mimics the aircraft ReFueling and ReArming.

Defined in:

COORDINATE

Parameters:

DCS#Speed Speed

Airspeed in km/h.

The airbase for takeoff and landing points.

#number timeReFuAr

Time in minutes, the aircraft stays at the airbase. Default 10 min.

#table DCSTasks

A table of DCS#Task items which are executed at the waypoint.

#string description

A text description of the waypoint, which will be shown on the F10 map.

Return value:

#table:

The route point.

Build a Waypoint Air "Take Off Parking".

Defined in:

COORDINATE

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Take Off Parking Hot".

Defined in:

COORDINATE

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Take Off Runway".

Defined in:

COORDINATE

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Turning Point".

Defined in:

COORDINATE

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

#table DCSTasks

(Optional) A table of DCS#Task items which are executed at the waypoint.

#string description

(Optional) A text description of the waypoint, which will be shown on the F10 map.

Return value:

#table:

The route point.

Build an ground type route point.

Defined in:

COORDINATE

Parameters:

#number Speed

(Optional) Speed in km/h. The default speed is 20 km/h.

#string Formation

(Optional) The route point Formation, which is a text string that specifies exactly the Text in the Type of the route point, like "Vee", "Echelon Right".

#table DCSTasks

(Optional) A table of DCS tasks that are executed at the waypoints. Mind the curly brackets {}!

Return value:

#table:

The route point.

Build route waypoint point for Naval units.

Defined in:

COORDINATE

Parameters:

#number Speed

(Optional) Speed in km/h. The default speed is 20 km/h.

#string Depth

(Optional) Dive depth in meters. Only for submarines. Default is COORDINATE.y component.

#table DCSTasks

(Optional) A table of DCS tasks that are executed at the waypoints. Mind the curly brackets {}!

Return value:

#table:

The route point.

Field(s)

Function(s)

Clear the state of an object.

Defined in:

Parameters:

Object

The object that holds the Value set by the Key.

StateName

The key that is should be cleared.

Creation of a Birth Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

#string IniUnitName

The initiating unit name.

place

subplace

Creation of a Crash Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Dead Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Remove Unit Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Takeoff Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Crash Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Log an exception which will be traced always.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Returns the event dispatcher

Defined in:

Return value:

Remove all subscribed events

Defined in:

Return value:

Trace a function call.

Must be at the beginning of the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function call level 2.

Must be at the beginning of the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function call level 3.

Must be at the beginning of the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Get the ClassID of the class instance.

Defined in:

Return value:

#string:

The ClassID of the class instance.

Get the ClassName of the class instance.

Defined in:

Return value:

#string:

The ClassName of the class instance.

Get the ClassName + ClassID of the class instance.

The ClassName + ClassID is formatted as '%s#%09d'.

Defined in:

Return value:

#string:

The ClassName + ClassID of the class instance.

Get the Class Event processing Priority.

The Event processing Priority is a number from 1 to 10, reflecting the order of the classes subscribed to the Event to be processed.

Defined in:

Return value:

#number:

The Event processing Priority.

This is the worker method to retrieve the Parent class.

Note that the Parent class must be passed to call the parent class method.

self:GetParent(self):ParentMethod()


Defined in:

Parameters:

#BASE Child

This is the Child class from which the Parent class needs to be retrieved.

#BASE FromClass

(Optional) The class from which to get the parent.

Return value:

Get a Value given a Key from the Object.

Note that if the Object is destroyed, nillified or garbage collected, then the Values and Keys will also be gone.

Defined in:

Parameters:

Object

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!

Return value:

The Value retrieved or nil if the Key was not found and thus the Value could not be retrieved.

Subscribe to a DCS Event.

Defined in:

Parameters:

#function EventFunction

(optional) The function to be called when the event occurs for the unit.

Return value:

Log an information which will be traced always.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

This is the worker method to inherit from a parent class.

Defined in:

Parameters:

Child

is the Child class that inherits.

#BASE Parent

is the Parent class that the Child inherits from.

Return value:

Child

This is the worker method to check if an object is an (sub)instance of a class.

Examples:

  • ZONE:New( 'some zone' ):IsInstanceOf( ZONE ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'ZONE' ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'zone' ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'BASE' ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'GROUP' ) will return false

Defined in:

Parameter:

ClassName

is the name of the class or the class itself to run the check against

Return value:

#boolean:

Enquires if tracing is on (for the class).

Defined in:

Return value:

#boolean:

BASE constructor.

This is an example how to use the BASE:New() constructor in a new class definition when inheriting from BASE.

function EVENT:New()
  local self = BASE:Inherit( self, BASE:New() ) -- #EVENT
  return self
end
  

Defined in:

Return value:

Occurs when an object is completely destroyed.

initiator : The unit that is was destroyed.

Defined in:

Parameter:

The EventData structure.

Occurs when a ground unit captures either an airbase or a farp.

initiator : The unit that captured the base place: The airbase that was captured, can be a FARP or Airbase. When calling place:getCoalition() the faction will already be the new owning faction.

Defined in:

Parameter:

The EventData structure.

Occurs when any object is spawned into the mission.

initiator : The unit that was spawned

Defined in:

Parameter:

The EventData structure.

Occurs when any aircraft crashes into the ground and is completely destroyed.

initiator : The unit that has crashed

Defined in:

Parameter:

The EventData structure.

Occurs when an object is dead.

initiator : The unit that is dead.

Defined in:

Parameter:

The EventData structure.

Unknown precisely what creates this event, likely tied into newer damage model.

Will update this page when new information become available.

  • initiator: The unit that had the failure.

Defined in:

Parameter:

The EventData structure.

Occurs when a pilot ejects from an aircraft initiator : The unit that has ejected

Defined in:

Parameter:

The EventData structure.

Occurs when any aircraft shuts down its engines.

initiator : The unit that is stopping its engines.

Defined in:

Parameter:

The EventData structure.

Occurs when any aircraft starts its engines.

initiator : The unit that is starting its engines.

Defined in:

Parameter:

The EventData structure.

Occurs whenever an object is hit by a weapon.

initiator : The unit object the fired the weapon weapon: Weapon object that hit the target target: The Object that was hit.

Defined in:

Parameter:

The EventData structure.

Occurs when any system fails on a human controlled aircraft.

initiator : The unit that had the failure

Defined in:

Parameter:

The EventData structure.

Occurs on the death of a unit.

Contains more and different information. Similar to unit_lost it will occur for aircraft before the aircraft crash event occurs.

  • initiator: The unit that killed the target
  • target: Target Object
  • weapon: Weapon Object

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft lands at an airbase, farp or ship initiator : The unit that has landed place: Object that the unit landed on.

Can be an Airbase Object, FARP, or Ships

Defined in:

Parameter:

The EventData structure.

Occurs shortly after the landing animation of an ejected pilot touching the ground and standing up.

Event does not occur if the pilot lands in the water and sub combs to Davey Jones Locker.

  • initiator: Static object representing the ejected pilot. Place : Aircraft that the pilot ejected from.
  • place: may not return as a valid object if the aircraft has crashed into the ground and no longer exists.
  • subplace: is always 0 for unknown reasons.

Defined in:

Parameter:

The EventData structure.

Occurs when a new mark was added.

MarkID: ID of the mark.

Defined in:

Parameter:

The EventData structure.

Occurs when a mark text was changed.

MarkID: ID of the mark.

Defined in:

Parameter:

The EventData structure.

Occurs when a mark was removed.

MarkID: ID of the mark.

Defined in:

Parameter:

The EventData structure.

Occurs when a mission ends

Defined in:

Parameter:

The EventData structure.

Occurs when a mission starts

Defined in:

Parameter:

The EventData structure.

Occurs when the pilot of an aircraft is killed.

Can occur either if the player is alive and crashes or if a weapon kills the pilot without completely destroying the plane. initiator : The unit that the pilot has died in.

Defined in:

Parameter:

The EventData structure.

Occurs when any player assumes direct control of a unit.

initiator : The unit that is being taken control of.

Defined in:

Parameter:

The EventData structure.

Occurs when any player relieves control of a unit to the AI.

initiator : The unit that the player left.

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft connects with a tanker and begins taking on fuel.

initiator : The unit that is receiving fuel.

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft is finished taking fuel.

initiator : The unit that was receiving fuel.

Defined in:

Parameter:

The EventData structure.

Occurs when any modification to the "Score" as seen on the debrief menu would occur.

There is no information on what values the score was changed to. Event is likely similar to player_comment in this regard.

Defined in:

Parameter:

The EventData structure.

Occurs when any unit stops firing its weapon.

Event will always correspond with a shooting start event. initiator : The unit that was doing the shooting.

Defined in:

Parameter:

The EventData structure.

Occurs when any unit begins firing a weapon that has a high rate of fire.

Most common with aircraft cannons (GAU-8), autocannons, and machine guns. initiator : The unit that is doing the shooting. target: The unit that is being targeted.

Defined in:

Parameter:

The EventData structure.

Occurs whenever any unit in a mission fires a weapon.

But not any machine gun or autocannon based weapon, those are handled by EVENT.ShootingStart.

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft takes off from an airbase, farp, or ship.

initiator : The unit that tookoff place: Object from where the AI took-off from. Can be an Airbase Object, FARP, or Ships

Defined in:

Parameter:

The EventData structure.

Occurs when the game thinks an object is destroyed.

  • initiator: The unit that is was destroyed.

Defined in:

Parameter:

The EventData structure.

Schedule a new time event.

Note that the schedule will only take place if the scheduler is started. Even for a single schedule event, the scheduler needs to be started also.

Defined in:

Parameters:

#number Start

Specifies the amount of seconds that will be waited before the scheduling is started, and the event function is called.

#function SchedulerFunction

The event function to be called when a timer event occurs. The event function needs to accept the parameters specified in SchedulerArguments.

#table ...

Optional arguments that can be given as part of scheduler. The arguments need to be given as a table { param1, param 2, ... }.

Return value:

#number:

The ScheduleID of the planned schedule.

Schedule a new time event.

Note that the schedule will only take place if the scheduler is started. Even for a single schedule event, the scheduler needs to be started also.

Defined in:

Parameters:

#number Start

Specifies the amount of seconds that will be waited before the scheduling is started, and the event function is called.

#number Repeat

Specifies the interval in seconds when the scheduler will call the event function.

#number RandomizeFactor

Specifies a randomization factor between 0 and 1 to randomize the Repeat.

#number Stop

Specifies the amount of seconds when the scheduler will be stopped.

#function SchedulerFunction

The event function to be called when a timer event occurs. The event function needs to accept the parameters specified in SchedulerArguments.

#table ...

Optional arguments that can be given as part of scheduler. The arguments need to be given as a table { param1, param 2, ... }.

Return value:

#number:

The ScheduleID of the planned schedule.

Stops the Schedule.

Defined in:

Parameter:

#function SchedulerFunction

The event function to be called when a timer event occurs. The event function needs to accept the parameters specified in SchedulerArguments.

Set the Class Event processing Priority.

The Event processing Priority is a number from 1 to 10, reflecting the order of the classes subscribed to the Event to be processed.

Defined in:

Parameter:

#number EventPriority

The Event processing Priority.

Return value:

self

Set a state or property of the Object given a Key and a Value.

Note that if the Object is destroyed, nillified or garbage collected, then the Values and Keys will also be gone.

Defined in:

Parameters:

Object

The object that will hold the Value set by the Key.

Key

The key that is used as a reference of 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:

The Value set.

Trace a function logic level 1.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function logic level 2.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function logic level 3.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace all methods in MOOSE

Defined in:

Parameter:

#boolean TraceAll

true = trace all methods in MOOSE.

Set tracing for a class

Defined in:

Parameter:

#string Class

Set tracing for a specific method of class

Defined in:

Parameters:

#string Class

#string Method

Set trace level

Defined in:

Parameter:

#number Level

Set trace off.

Defined in:

Usage:

-- Switch the tracing Off
BASE:TraceOff()

Set trace on.

Defined in:

Usage:

-- Switch the tracing On
BASE:TraceOn()

Set trace on or off Note that when trace is off, no BASE.Debug statement is performed, increasing performance! When Moose is loaded statically, (as one file), tracing is switched off by default.

So tracing must be switched on manually in your mission if you are using Moose statically. When moose is loading dynamically (for moose class development), tracing is switched on by default.

Defined in:

Parameter:

#boolean TraceOnOff

Switch the tracing on or off.

Usage:

-- Switch the tracing On
BASE:TraceOnOff( true )

-- Switch the tracing Off
BASE:TraceOnOff( false )

UnSubscribe to a DCS event.

Defined in:

Parameter:

Return value:

Trace a function call.

This function is private.

Defined in:

Parameters:

Arguments

A #table or any field.

DebugInfoCurrentParam

DebugInfoFromParam

Trace a function logic.

Defined in:

Parameters:

Arguments

A #table or any field.

DebugInfoCurrentParam

DebugInfoFromParam

TODO: Complete DCS#Event structure.
- The main event handling function... This function captures all events generated for the class. @param #BASE self @param DCS#Event event

Defined in:

Parameter:

event

Field(s)

DCS#Distance POINT_VEC2.x

The x coordinate in meters.

DCS#Distance POINT_VEC2.y

the y coordinate in meters.

Function(s)

Add to the current land height an altitude.

Defined in:

POINT_VEC2

Parameter:

#number Altitude

The Altitude to add. If nothing (nil) is given, then the current land altitude is set.

Return value:

Add to the x coordinate of the POINT_VEC2.

Defined in:

POINT_VEC2

Parameter:

#number x

The x coordinate.

Return value:

Add to the y coordinate of the POINT_VEC2.

Defined in:

POINT_VEC2

Parameter:

#number y

The y coordinate.

Return value:

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. @return DCS#Distance The distance from the reference #POINT_VEC2 in meters.

Defined in:

POINT_VEC2

Parameter:

PointVec2Reference

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

Defined in:

POINT_VEC2

Return value:

#number:

The land altitude.

Return Return the Lat(itude) coordinate of the POINT_VEC2 (ie: (parent)POINT_VEC3.x).

Defined in:

POINT_VEC2

Return value:

#number:

The x coodinate.

Return the Lon(gitude) coordinate of the POINT_VEC2 (ie: (parent)POINT_VEC3.z).

Defined in:

POINT_VEC2

Return value:

#number:

The y coodinate.

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

Defined in:

POINT_VEC2

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

Return the x coordinate of the POINT_VEC2.

Defined in:

POINT_VEC2

Return value:

#number:

The x coodinate.

Return the y coordinate of the POINT_VEC2.

Defined in:

POINT_VEC2

Return value:

#number:

The y coodinate.

POINT_VEC2 constructor.

Defined in:

POINT_VEC2

Parameters:

The x coordinate of the Vec3 point, pointing to the North.

The y coordinate of the Vec3 point, pointing to the Right.

DCS#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.

Return value:

Create a new POINT_VEC2 object from Vec2 coordinates.

Defined in:

POINT_VEC2

Parameters:

DCS#Vec2 Vec2

The Vec2 point.

LandHeightAdd

Return value:

Create a new POINT_VEC2 object from Vec3 coordinates.

Defined in:

POINT_VEC2

Parameter:

DCS#Vec3 Vec3

The Vec3 point.

Return value:

Set the altitude of the POINT_VEC2.

Defined in:

POINT_VEC2

Parameter:

#number Altitude

The land altitude. If nothing (nil) is given, then the current land altitude is set.

Return value:

Set the Lat(itude) coordinate of the POINT_VEC2 (ie: POINT_VEC3.x).

Defined in:

POINT_VEC2

Parameter:

#number x

The x coordinate.

Return value:

Set the Lon(gitude) coordinate of the POINT_VEC2 (ie: POINT_VEC3.z).

Defined in:

POINT_VEC2

Parameters:

#number y

The y coordinate.

z

Return value:

Set the x coordinate of the POINT_VEC2.

Defined in:

POINT_VEC2

Parameter:

#number x

The x coordinate.

Return value:

Set the y coordinate of the POINT_VEC2.

Defined in:

POINT_VEC2

Parameter:

#number y

The y coordinate.

Return value:

Field(s)

DCS#Distance POINT_VEC2.x

The x coordinate in meters.

DCS#Distance POINT_VEC2.y

the y coordinate in meters.

Function(s)

Big smoke and fire at the coordinate.

Defined in:

Parameters:

Smoke preset (0=small smoke and fire, 1=medium smoke and fire, 2=large smoke and fire, 3=huge smoke and fire, 4=small smoke, 5=medium smoke, 6=large smoke, 7=huge smoke).

#number density

(Optional) Smoke density. Number in [0,...,1]. Default 0.5.

Huge smoke and fire at the coordinate.

Defined in:

Parameter:

density

Large smoke and fire at the coordinate.

Defined in:

Parameter:

density

Medium smoke and fire at the coordinate.

Defined in:

Parameter:

density

Small smoke and fire at the coordinate.

Defined in:

Parameter:

density

Huge smoke at the coordinate.

Defined in:

Parameter:

density

Large smoke at the coordinate.

Defined in:

Parameter:

density

Medium smoke at the coordinate.

Defined in:

Parameter:

density

Small smoke at the coordinate.

Defined in:

Parameter:

density

Calculate the distance from a reference #COORDINATE.

Defined in:

Parameter:

#COORDINATE PointVec2Reference

The reference #COORDINATE.

Return value:

The distance from the reference #COORDINATE in meters.

Creates an explosion at the point of a certain intensity.

Defined in:

Parameters:

#number ExplosionIntensity

Intensity of the explosion in kg TNT. Default 100 kg.

#number Delay

Delay before explosion in seconds.

Return value:

self

Find the closest scenery to the COORDINATE within a certain radius.

Defined in:

Parameter:

#number radius

Scan radius in meters. Default 100 m.

Return value:

The closest scenery or #nil if no object is inside the given radius.

Find the closest unit to the COORDINATE within a certain radius.

Defined in:

Parameter:

#number radius

Scan radius in meters. Default 100 m.

Return value:

The closest unit or #nil if no unit is inside the given radius.

Flares the point in a color.

Defined in:

Parameters:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

Flare the COORDINATE Green.

Defined in:

Parameter:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

Flare the COORDINATE Red.

Defined in:

Parameter:

Azimuth

Flare the COORDINATE White.

Defined in:

Parameter:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

Flare the COORDINATE Yellow.

Defined in:

Parameter:

DCS#Azimuth Azimuth

(optional) The azimuth of the flare direction. The default azimuth is 0.

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

Defined in:

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE. Can also be a DCS#Vec3.

Return value:

Distance The distance in meters.

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

Defined in:

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE.

Return value:

Distance The distance in meters.

Return the altitude text of the COORDINATE.

Defined in:

Parameters:

Settings

Language

Return value:

#string:

Altitude text.

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

Defined in:

Parameter:

DCS#Vec3 DirectionVec3

The direction vector in Vec3 format.

Return value:

#number:

DirectionRadians The angle in degrees.

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

Defined in:

Parameter:

DCS#Vec3 DirectionVec3

The direction vector in Vec3 format.

Return value:

#number:

DirectionRadians The angle in radians.

Provides a Bearing / Range / Altitude string

Defined in:

Parameters:

#number AngleRadians

The angle in randians

#number Distance

The distance

Language

Return value:

#string:

The BRA Text

Provides a Bearing / Range string

Defined in:

Parameters:

#number AngleRadians

The angle in randians

#number Distance

The distance

Language

Return value:

#string:

The BR Text

Provides a bearing text in degrees.

Defined in:

Parameters:

#number AngleRadians

The angle in randians.

#number Precision

The precision.

Language

Return value:

#string:

The bearing text in degrees.

Gets the nearest airbase with respect to the current coordinates.

Defined in:

Parameters:

#number Category

(Optional) Category of the airbase. Enumerator of Wrapper.Airbase#AIRBASE.Category.

#number Coalition

(Optional) Coalition of the airbase.

Return values:

Closest Airbase to the given coordinate.

#number:

Distance to the closest airbase in meters.

Gets the nearest airbase with respect to the current coordinates.

Defined in:

Parameters:

#number Category

(Optional) Category of the airbase. Enumerator of Wrapper.Airbase#AIRBASE.Category.

#number Coalition

(Optional) Coalition of the airbase.

Return values:

Closest Airbase to the given coordinate.

#number:

Distance to the closest airbase in meters.

Gets the nearest free parking spot.

Defined in:

Parameters:

(Optional) Search only parking spots at that airbase.

(Optional) Type of the terminal.

Return values:

Coordinate of the nearest free parking spot.

#number:

Terminal ID.

#number:

Distance to closest free parking spot in meters.

Gets the nearest occupied parking spot.

Defined in:

Parameters:

(Optional) Search only parking spots at that airbase.

(Optional) Type of the terminal.

Return values:

Coordinate of the nearest occupied parking spot.

#number:

Terminal ID.

#number:

Distance to closest occupied parking spot in meters.

Gets the nearest parking spot.

Defined in:

Parameters:

(Optional) Search only parking spots at this airbase.

(Optional) Type of the terminal. Default any execpt valid spawn points on runway.

#boolean free

(Optional) If true, returns the closest free spot. If false, returns the closest occupied spot. If nil, returns the closest spot regardless of free or occupied.

Return values:

Coordinate of the nearest parking spot.

#number:

Terminal ID.

#number:

Distance to closest parking spot in meters.

ParkingSpot Parking spot table.

Gets the nearest coordinate to a road (or railroad).

Defined in:

Parameter:

#boolean Railroad

(Optional) If true, closest point to railroad is returned rather than closest point to conventional road. Default false.

Return value:

Coordinate of the nearest road.

Return a direction vector Vec3 from COORDINATE to the COORDINATE.

Defined in:

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE.

Return value:

DirectionVec3 The direction vector in Vec3 format.

Provides a distance text expressed in the units of measurement.

Defined in:

Parameters:

#number Distance

The distance in meters.

Language

Return value:

#string:

The distance text expressed in the units of measurement.

Get the heading of the coordinate, if applicable.

Defined in:

Return value:

#number:

or nil

Return the heading text of the COORDINATE.

Defined in:

Parameter:

Settings

Return value:

#string:

Heading text.

Return an intermediate COORDINATE between this an another coordinate.

Defined in:

Parameters:

#COORDINATE ToCoordinate

The other coordinate.

#number Fraction

The fraction (0,1) where the new coordinate is created. Default 0.5, i.e. in the middle.

Return value:

Coordinate between this and the other coordinate.

Get Latitude and Longitude in Degrees Decimal Minutes (DDM).

Defined in:

Return values:

#number:

Latitude in DDM.

#number:

Lontitude in DDM.

Return the height of the land at the coordinate.

Defined in:

Return value:

#number:

Land height (ASL) in meters.

Get minutes until the next sun rise at this coordinate.

Defined in:

Parameter:

OnlyToday

If true, only calculate the sun rise of today. If sun has already risen, the time in negative minutes since sunrise is reported.

Return value:

#number:

Minutes to the next sunrise.

Get minutes until the next sun set at this coordinate.

Defined in:

Parameter:

OnlyToday

If true, only calculate the sun set of today. If sun has already set, the time in negative minutes since sunset is reported.

Return value:

#number:

Minutes to the next sunrise.

Return velocity text of the COORDINATE.

Defined in:

Parameter:

Settings

Return value:

#string:

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

Defined in:

Return value:

#number:

CorrectionRadians The correction in radians.

Returns a table of coordinates to a destination using only roads or railroads.

The first point is the closest point on road of the given coordinate. By default, the last point is the closest point on road of the ToCoord. Hence, the coordinate itself and the final ToCoord are not necessarily included in the path.

Defined in:

Parameters:

#COORDINATE ToCoord

Coordinate of destination.

#boolean IncludeEndpoints

(Optional) Include the coordinate itself and the ToCoordinate in the path.

#boolean Railroad

(Optional) If true, path on railroad is returned. Default false.

#boolean MarkPath

(Optional) If true, place markers on F10 map along the path.

#boolean SmokePath

(Optional) If true, put (green) smoke along the

Return values:

#table:

Table of coordinates on road. If no path on road can be found, nil is returned or just the endpoints.

#number:

Tonal length of path.

#boolean:

If true a valid path on road/rail was found. If false, only the direct way is possible.

Returns the pressure in hPa.

Defined in:

Parameter:

height

(Optional) parameter specifying the height ASL. E.g. set height=0 for QNH.

Return value:

Pressure in hPa.

Returns a text of the pressure according the measurement system Settings.

The text will contain always the pressure in hPa and:

  • For Russian and European aircraft using the metric system - hPa and mmHg
  • For Americain and European aircraft we link to the imperial system - hPa and inHg

A text containing a pressure will look like this:

  • QFE: x hPa (y mmHg)
  • QFE: x hPa (y inHg)

Defined in:

Parameters:

height

(Optional) parameter specifying the height ASL. E.g. set height=0 for QNH.

Settings

Return value:

#string:

Pressure in hPa and mmHg or inHg depending on the measurement system Settings.

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

Defined in:

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

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

Defined in:

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

Vec2

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

Defined in:

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

Vec3

Get todays sun rise time.

Defined in:

Parameter:

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunrise time, e.g. "05:41".

Get sun rise time for a specific date at the coordinate.

Defined in:

Parameters:

#number Day

The day.

#number Month

The month.

#number Year

The year.

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunrise time, e.g. "05:41".

Get sun rise time for a specific day of the year at the coordinate.

Defined in:

Parameters:

#number DayOfYear

The day of the year.

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunrise time, e.g. "05:41".

Get todays sun set time.

Defined in:

Parameter:

#boolean InSeconds

If true, return the sun set time in seconds.

Return value:

#string:

Sunrise time, e.g. "20:41".

Get sun set time for a specific date at the coordinate.

Defined in:

Parameters:

#number Day

The day.

#number Month

The month.

#number Year

The year.

#boolean InSeconds

If true, return the sun rise time in seconds.

Return value:

#string:

Sunset time, e.g. "20:41".

Gets the surface type at the coordinate.

Defined in:

Return value:

Surface type.

Returns the temperature in Degrees Celsius.

Defined in:

Parameter:

height

(Optional) parameter specifying the height ASL.

Return value:

Temperature in Degrees Celsius.

Returns a text of the temperature according the measurement system Settings.

The text will reflect the temperature like this:

  • For Russian and European aircraft using the metric system - Degrees Celcius (°C)
  • For Americain aircraft we link to the imperial system - Degrees Farenheit (°F)

A text containing a pressure will look like this:

  • Temperature: %n.d °C
  • Temperature: %n.d °F

Defined in:

Parameters:

height

(Optional) parameter specifying the height ASL.

Settings

Return value:

#string:

Temperature according the measurement system Settings.

Return the coordinates of the COORDINATE in Vec2 format.

Defined in:

Return value:

The Vec2 format coordinate.

Return the coordinates of the COORDINATE in Vec3 format.

Defined in:

Return value:

The Vec3 format coordinate.

Return the velocity of the COORDINATE.

Defined in:

Return value:

#number:

Velocity in meters per second.

Return the velocity text of the COORDINATE.

Defined in:

Parameter:

Settings

Return value:

#string:

Velocity text.

Returns the wind direction (from) and strength.

Defined in:

Parameter:

height

(Optional) parameter specifying the height ASL. The minimum height will be always be the land height since the wind is zero below the ground.

Return values:

Direction the wind is blowing from in degrees.

Wind strength in m/s.

Returns a text documenting the wind direction (from) and strength according the measurement system Settings.

The text will reflect the wind like this:

  • For Russian and European aircraft using the metric system - Wind direction in degrees (°) and wind speed in meters per second (mps).
  • For Americain aircraft we link to the imperial system - Wind direction in degrees (°) and wind speed in knots per second (kps).

A text containing a pressure will look like this:

  • Wind: %n ° at n.d mps
  • Wind: %n ° at n.d kps

Defined in:

Parameters:

height

(Optional) parameter specifying the height ASL. The minimum height will be always be the land height since the wind is zero below the ground.

Settings

Return value:

#string:

Wind direction and strength according the measurement system Settings.

Returns the wind direction (from) and strength.

Defined in:

Parameter:

height

(Optional) parameter specifying the height ASL. The minimum height will be always be the land height since the wind is zero below the ground.

Return value:

Direction the wind is blowing from in degrees.

Returns the heading from this to another coordinate.

Defined in:

Parameter:

#COORDINATE ToCoordinate

Return value:

#number:

Heading in degrees.

Creates an illumination bomb at the point.

Defined in:

Parameter:

#number power

Power of illumination bomb in Candela.

Return value:

self

Returns if the 2 coordinates are at the same 2D position.

Defined in:

Parameters:

#COORDINATE Coordinate

#number Precision

Return value:

#boolean:

true if at the same position.

Check if it is day, i.e.

if the sun has risen about the horizon at this coordinate.

Defined in:

Parameter:

#string Clock

(Optional) Time in format "HH:MM:SS+D", e.g. "05:40:00+3" to check if is day at 5:40 at third day after mission start. Default is to check right now.

Return value:

#boolean:

If true, it is day. If false, it is night time.

Returns if a Coordinate is in a certain Radius of this Coordinate in 2D plane using the X and Z axis.

Defined in:

Parameters:

#COORDINATE Coordinate

The coordinate that will be tested if it is in the radius of this coordinate.

#number Radius

The radius of the circle on the 2D plane around this coordinate.

Return value:

#boolean:

true if in the Radius.

Returns if a Coordinate is in a certain radius of this Coordinate in 3D space using the X, Y and Z axis.

So Radius defines the radius of the a Sphere in 3D space around this coordinate.

Defined in:

Parameters:

#COORDINATE ToCoordinate

The coordinate that will be tested if it is in the radius of this coordinate.

#number Radius

The radius of the sphere in the 3D space around this coordinate.

Coordinate

Return value:

#boolean:

true if in the Sphere.

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

Defined in:

Parameters:

#COORDINATE ToCoordinate

#number Offset

Height offset in meters. Default 2 m.

Return value:

#boolean:

true If the ToCoordinate has LOS with the Coordinate, otherwise false.

Check if it is night, i.e.

if the sun has set below the horizon at this coordinate.

Defined in:

Parameter:

#string Clock

(Optional) Time in format "HH:MM:SS+D", e.g. "05:40:00+3" to check if is night at 5:40 at third day after mission start. Default is to check right now.

Return value:

#boolean:

If true, it is night. If false, it is day time.

Checks if the surface type is on land.

Defined in:

Return value:

#boolean:

If true, the surface type at the coordinate is land.

Checks if the surface type is road.

Defined in:

Return value:

#boolean:

If true, the surface type at the coordinate is a road.

Checks if the surface type is runway.

Defined in:

Return value:

#boolean:

If true, the surface type at the coordinate is a runway or taxi way.

Checks if the surface type is shallow water.

Defined in:

Return value:

#boolean:

If true, the surface type at the coordinate is a shallow water.

Checks if the surface type is water.

Defined in:

Return value:

#boolean:

If true, the surface type at the coordinate is a deep water.

Mark to All

Defined in:

Parameters:

#string MarkText

Free format text that shows the marking clarification.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToAll( "This is a target for all players" )

Mark to Coalition

Defined in:

Parameters:

#string MarkText

Free format text that shows the marking clarification.

Coalition

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToCoalition( "This is a target for the red coalition", coalition.side.RED )

Mark to Blue Coalition

Defined in:

Parameters:

#string MarkText

Free format text that shows the marking clarification.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToCoalitionBlue( "This is a target for the blue coalition" )

Mark to Red Coalition

Defined in:

Parameters:

#string MarkText

Free format text that shows the marking clarification.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkID = TargetCoord:MarkToCoalitionRed( "This is a target for the red coalition" )

Mark to Group

Defined in:

Parameters:

#string MarkText

Free format text that shows the marking clarification.

The Wrapper.Group that receives the mark.

#boolean ReadOnly

(Optional) Mark is readonly and cannot be removed by users. Default false.

#string Text

(Optional) Text displayed when mark is added. Default none.

Return value:

#number:

The resulting Mark ID which is a number.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkGroup = GROUP:FindByName( "AttackGroup" )
  local MarkID = TargetCoord:MarkToGroup( "This is a target for the attack group", AttackGroup )

COORDINATE constructor.

Defined in:

Parameters:

The x coordinate of the Vec3 point, pointing to the North.

The y coordinate of the Vec3 point, pointing to the Right.

The z coordinate of the Vec3 point, pointing to the Right.

Return value:

COORDINATE constructor.

Defined in:

Parameter:

#COORDINATE Coordinate

Return value:

Returns the coordinate from the latitude and longitude given in decimal degrees.

Defined in:

Parameters:

#number latitude

Latitude in decimal degrees.

#number longitude

Longitude in decimal degrees.

#number altitude

(Optional) Altitude in meters. Default is the land height at the coordinate.

Return value:

Create a new COORDINATE object from Vec2 coordinates.

Defined in:

Parameters:

DCS#Vec2 Vec2

The Vec2 point.

DCS#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.

Return value:

Create a new COORDINATE object from Vec3 coordinates.

Defined in:

Parameter:

DCS#Vec3 Vec3

The Vec3 point.

Return value:

Remove a mark

Defined in:

Parameter:

#number MarkID

The ID of the mark to be removed.

Usage:

  local TargetCoord = TargetGroup:GetCoordinate()
  local MarkGroup = GROUP:FindByName( "AttackGroup" )
  local MarkID = TargetCoord:MarkToGroup( "This is a target for the attack group", AttackGroup )
  <<< logic >>>
  RemoveMark( MarkID ) -- The mark is now removed

Rotate coordinate in 2D (x,z) space.

Defined in:

Parameter:

DCS#Angle Angle

Angle of rotation in degrees.

Return value:

The rotated coordinate.

Scan/find objects (units, statics, scenery) within a certain radius around the coordinate using the world.searchObjects() DCS API function.

Defined in:

Parameters:

#number radius

(Optional) Scan radius in meters. Default 100 m.

#boolean scanunits

(Optional) If true scan for units. Default true.

#boolean scanstatics

(Optional) If true scan for static objects. Default true.

#boolean scanscenery

(Optional) If true scan for scenery objects. Default false.

Return values:

#boolean:

True if units were found.

#boolean:

True if statics were found.

#boolean:

True if scenery objects were found.

#table:

Table of MOOSE Wrapper.Unit#UNIT objects found.

#table:

Table of DCS static objects found.

#table:

Table of DCS scenery objects found.

Scan/find SCENERY objects within a certain radius around the coordinate using the world.searchObjects() DCS API function.

Defined in:

Parameter:

#number radius

(Optional) Scan radius in meters. Default 100 m.

Return value:

table Set of scenery objects.

Scan/find UNITS within a certain radius around the coordinate using the world.searchObjects() DCS API function.

Defined in:

Parameter:

#number radius

(Optional) Scan radius in meters. Default 100 m.

Return value:

Set of units.

Set altitude.

Defined in:

Parameters:

#number altitude

New altitude in meters.

#boolean asl

Altitude above sea level. Default is above ground level.

Return value:

The COORDINATE with adjusted altitude.

Set the heading of the coordinate, if applicable.

Defined in:

Parameter:

Heading

Set the velocity of the COORDINATE.

Defined in:

Parameter:

#string Velocity

Velocity in meters per second.

Smokes the point in a color.

Defined in:

Parameter:

Smoke the COORDINATE Blue.

Defined in:

Smoke the COORDINATE Green.

Defined in:

Smoke the COORDINATE Orange.

Defined in:

Smoke the COORDINATE Red.

Defined in:

Smoke the COORDINATE White.

Defined in:

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

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

Defined in:

Parameters:

The controllable to retrieve the settings from, otherwise the default settings will be chosen.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

The task for which coordinates need to be calculated.

Return value:

#string:

The coordinate Text in the configured coordinate system.

Provides a coordinate string of the point, based on the A2A coordinate format system.

Defined in:

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Language

Return value:

#string:

The coordinate Text in the configured coordinate system.

Provides a coordinate string of the point, based on the A2G coordinate format system.

Defined in:

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The coordinate Text in the configured coordinate system.

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

Defined in:

Parameter:

#COORDINATE TargetCoordinate

The target COORDINATE.

Return value:

#string:

The Aspect string, which is Hot, Cold or Flanking.

Return a BR string from a COORDINATE to the COORDINATE.

Defined in:

Parameters:

#COORDINATE FromCoordinate

The coordinate to measure the distance and the bearing from.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The BR text.

Return a BRAA string from a COORDINATE to the COORDINATE.

Defined in:

Parameters:

#COORDINATE FromCoordinate

The coordinate to measure the distance and the bearing from.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Language

Return value:

#string:

The BR text.

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

Defined in:

Parameters:

DCS#coalition.side Coalition

The coalition.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The BR text.

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

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

Defined in:

Parameters:

#COORDINATE ReferenceCoord

The refrence coordinate.

#string ReferenceName

The refrence name.

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The coordinate Text in the configured coordinate system.

Provides a Lat Lon string in Degree Decimal Minute format.

Defined in:

Parameter:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The LL DDM Text

Provides a Lat Lon string in Degree Minute Second format.

Defined in:

Parameter:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The LL DMS Text

Provides a MGRS string

Defined in:

Parameter:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The MGRS Text

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

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

Defined in:

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The pressure text in the configured measurement system.

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

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

Defined in:

Parameters:

Core

Settings#SETTINGS

Settings

Return value:

#string:

The temperature text in the configured measurement system.

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

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

Defined in:

Parameters:

(optional) The settings. Can be nil, and in this case the default settings are used. If you want to specify your own settings, use the _SETTINGS object.

Return value:

#string:

The wind text in the configured measurement system.

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

Defined in:

Parameters:

DCS#Distance Distance

The Distance to be added in meters.

DCS#Angle Angle

The Angle in degrees. Defaults to 0 if not specified (nil).

#boolean Keepalt

If true, keep altitude of original coordinate. Default is that the new coordinate is created at the translated land height.

#boolean Overwrite

If true, overwrite the original COORDINATE with the translated one. Otherwise, create a new COODINATE.

Return value:

The new calculated COORDINATE.

Update x,y,z coordinates from another given COORDINATE.

Defined in:

Parameter:

#COORDINATE Coordinate

The coordinate with the new x,y,z positions.

Return value:

The modified COORDINATE itself.

Update x and z coordinates from a given 2D vector.

Defined in:

Parameter:

DCS#Vec2 Vec2

The 2D vector with x,y components. x is overwriting COORDINATE.x while y is overwriting COORDINATE.z.

Return value:

The modified COORDINATE itself.

Update x,y,z coordinates from a given 3D vector.

Defined in:

Parameter:

DCS#Vec3 Vec3

The 3D vector with x,y,z components.

Return value:

The modified COORDINATE itself.

Build an air type route point.

Defined in:

Parameters:

The altitude type.

The route point type.

The route point action.

DCS#Speed Speed

Airspeed in km/h. Default is 500 km/h.

#boolean SpeedLocked

true means the speed is locked.

The airbase for takeoff and landing points.

#table DCSTasks

A table of DCS#Task items which are executed at the waypoint.

#string description

A text description of the waypoint, which will be shown on the F10 map.

#number timeReFuAr

Time in minutes the aircraft stays at the airport for ReFueling and ReArming.

Return value:

#table:

The route point.

Build a Waypoint Air "Fly Over Point".

Defined in:

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Landing".

Defined in:

Parameters:

DCS#Speed Speed

Airspeed in km/h.

The airbase for takeoff and landing points.

#table DCSTasks

A table of DCS#Task items which are executed at the waypoint.

#string description

A text description of the waypoint, which will be shown on the F10 map.

Return value:

#table:

The route point.

Usage:


   LandingZone = ZONE:New( "LandingZone" )
   LandingCoord = LandingZone:GetCoordinate()
   LandingWaypoint = LandingCoord:WaypointAirLanding( 60 )
   HeliGroup:Route( { LandWaypoint }, 1 ) -- Start landing the helicopter in one second.

Build a Waypoint Air "LandingReFuAr".

Mimics the aircraft ReFueling and ReArming.

Defined in:

Parameters:

DCS#Speed Speed

Airspeed in km/h.

The airbase for takeoff and landing points.

#number timeReFuAr

Time in minutes, the aircraft stays at the airbase. Default 10 min.

#table DCSTasks

A table of DCS#Task items which are executed at the waypoint.

#string description

A text description of the waypoint, which will be shown on the F10 map.

Return value:

#table:

The route point.

Build a Waypoint Air "Take Off Parking".

Defined in:

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Take Off Parking Hot".

Defined in:

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Take Off Runway".

Defined in:

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

Return value:

#table:

The route point.

Build a Waypoint Air "Turning Point".

Defined in:

Parameters:

The altitude type.

DCS#Speed Speed

Airspeed in km/h.

#table DCSTasks

(Optional) A table of DCS#Task items which are executed at the waypoint.

#string description

(Optional) A text description of the waypoint, which will be shown on the F10 map.

Return value:

#table:

The route point.

Build an ground type route point.

Defined in:

Parameters:

#number Speed

(Optional) Speed in km/h. The default speed is 20 km/h.

#string Formation

(Optional) The route point Formation, which is a text string that specifies exactly the Text in the Type of the route point, like "Vee", "Echelon Right".

#table DCSTasks

(Optional) A table of DCS tasks that are executed at the waypoints. Mind the curly brackets {}!

Return value:

#table:

The route point.

Build route waypoint point for Naval units.

Defined in:

Parameters:

#number Speed

(Optional) Speed in km/h. The default speed is 20 km/h.

#string Depth

(Optional) Dive depth in meters. Only for submarines. Default is COORDINATE.y component.

#table DCSTasks

(Optional) A table of DCS tasks that are executed at the waypoints. Mind the curly brackets {}!

Return value:

#table:

The route point.

Field(s)

DCS#Distance POINT_VEC2.x

The x coordinate in meters.

DCS#Distance POINT_VEC2.y

the y coordinate in meters.

Function(s)

Clear the state of an object.

Defined in:

Parameters:

Object

The object that holds the Value set by the Key.

StateName

The key that is should be cleared.

Creation of a Birth Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

#string IniUnitName

The initiating unit name.

place

subplace

Creation of a Crash Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Dead Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Remove Unit Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Takeoff Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Creation of a Crash Event.

Defined in:

Parameters:

DCS#Time EventTime

The time stamp of the event.

DCS#Object Initiator

The initiating object of the event.

Log an exception which will be traced always.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Returns the event dispatcher

Defined in:

Return value:

Remove all subscribed events

Defined in:

Return value:

Trace a function call.

Must be at the beginning of the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function call level 2.

Must be at the beginning of the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function call level 3.

Must be at the beginning of the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Get the ClassID of the class instance.

Defined in:

Return value:

#string:

The ClassID of the class instance.

Get the ClassName of the class instance.

Defined in:

Return value:

#string:

The ClassName of the class instance.

Get the ClassName + ClassID of the class instance.

The ClassName + ClassID is formatted as '%s#%09d'.

Defined in:

Return value:

#string:

The ClassName + ClassID of the class instance.

Get the Class Event processing Priority.

The Event processing Priority is a number from 1 to 10, reflecting the order of the classes subscribed to the Event to be processed.

Defined in:

Return value:

#number:

The Event processing Priority.

This is the worker method to retrieve the Parent class.

Note that the Parent class must be passed to call the parent class method.

self:GetParent(self):ParentMethod()


Defined in:

Parameters:

#BASE Child

This is the Child class from which the Parent class needs to be retrieved.

#BASE FromClass

(Optional) The class from which to get the parent.

Return value:

Get a Value given a Key from the Object.

Note that if the Object is destroyed, nillified or garbage collected, then the Values and Keys will also be gone.

Defined in:

Parameters:

Object

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!

Return value:

The Value retrieved or nil if the Key was not found and thus the Value could not be retrieved.

Subscribe to a DCS Event.

Defined in:

Parameters:

#function EventFunction

(optional) The function to be called when the event occurs for the unit.

Return value:

Log an information which will be traced always.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

This is the worker method to inherit from a parent class.

Defined in:

Parameters:

Child

is the Child class that inherits.

#BASE Parent

is the Parent class that the Child inherits from.

Return value:

Child

This is the worker method to check if an object is an (sub)instance of a class.

Examples:

  • ZONE:New( 'some zone' ):IsInstanceOf( ZONE ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'ZONE' ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'zone' ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'BASE' ) will return true

  • ZONE:New( 'some zone' ):IsInstanceOf( 'GROUP' ) will return false

Defined in:

Parameter:

ClassName

is the name of the class or the class itself to run the check against

Return value:

#boolean:

Enquires if tracing is on (for the class).

Defined in:

Return value:

#boolean:

BASE constructor.

This is an example how to use the BASE:New() constructor in a new class definition when inheriting from BASE.

function EVENT:New()
  local self = BASE:Inherit( self, BASE:New() ) -- #EVENT
  return self
end
  

Defined in:

Return value:

Occurs when an object is completely destroyed.

initiator : The unit that is was destroyed.

Defined in:

Parameter:

The EventData structure.

Occurs when a ground unit captures either an airbase or a farp.

initiator : The unit that captured the base place: The airbase that was captured, can be a FARP or Airbase. When calling place:getCoalition() the faction will already be the new owning faction.

Defined in:

Parameter:

The EventData structure.

Occurs when any object is spawned into the mission.

initiator : The unit that was spawned

Defined in:

Parameter:

The EventData structure.

Occurs when any aircraft crashes into the ground and is completely destroyed.

initiator : The unit that has crashed

Defined in:

Parameter:

The EventData structure.

Occurs when an object is dead.

initiator : The unit that is dead.

Defined in:

Parameter:

The EventData structure.

Unknown precisely what creates this event, likely tied into newer damage model.

Will update this page when new information become available.

  • initiator: The unit that had the failure.

Defined in:

Parameter:

The EventData structure.

Occurs when a pilot ejects from an aircraft initiator : The unit that has ejected

Defined in:

Parameter:

The EventData structure.

Occurs when any aircraft shuts down its engines.

initiator : The unit that is stopping its engines.

Defined in:

Parameter:

The EventData structure.

Occurs when any aircraft starts its engines.

initiator : The unit that is starting its engines.

Defined in:

Parameter:

The EventData structure.

Occurs whenever an object is hit by a weapon.

initiator : The unit object the fired the weapon weapon: Weapon object that hit the target target: The Object that was hit.

Defined in:

Parameter:

The EventData structure.

Occurs when any system fails on a human controlled aircraft.

initiator : The unit that had the failure

Defined in:

Parameter:

The EventData structure.

Occurs on the death of a unit.

Contains more and different information. Similar to unit_lost it will occur for aircraft before the aircraft crash event occurs.

  • initiator: The unit that killed the target
  • target: Target Object
  • weapon: Weapon Object

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft lands at an airbase, farp or ship initiator : The unit that has landed place: Object that the unit landed on.

Can be an Airbase Object, FARP, or Ships

Defined in:

Parameter:

The EventData structure.

Occurs shortly after the landing animation of an ejected pilot touching the ground and standing up.

Event does not occur if the pilot lands in the water and sub combs to Davey Jones Locker.

  • initiator: Static object representing the ejected pilot. Place : Aircraft that the pilot ejected from.
  • place: may not return as a valid object if the aircraft has crashed into the ground and no longer exists.
  • subplace: is always 0 for unknown reasons.

Defined in:

Parameter:

The EventData structure.

Occurs when a new mark was added.

MarkID: ID of the mark.

Defined in:

Parameter:

The EventData structure.

Occurs when a mark text was changed.

MarkID: ID of the mark.

Defined in:

Parameter:

The EventData structure.

Occurs when a mark was removed.

MarkID: ID of the mark.

Defined in:

Parameter:

The EventData structure.

Occurs when a mission ends

Defined in:

Parameter:

The EventData structure.

Occurs when a mission starts

Defined in:

Parameter:

The EventData structure.

Occurs when the pilot of an aircraft is killed.

Can occur either if the player is alive and crashes or if a weapon kills the pilot without completely destroying the plane. initiator : The unit that the pilot has died in.

Defined in:

Parameter:

The EventData structure.

Occurs when any player assumes direct control of a unit.

initiator : The unit that is being taken control of.

Defined in:

Parameter:

The EventData structure.

Occurs when any player relieves control of a unit to the AI.

initiator : The unit that the player left.

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft connects with a tanker and begins taking on fuel.

initiator : The unit that is receiving fuel.

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft is finished taking fuel.

initiator : The unit that was receiving fuel.

Defined in:

Parameter:

The EventData structure.

Occurs when any modification to the "Score" as seen on the debrief menu would occur.

There is no information on what values the score was changed to. Event is likely similar to player_comment in this regard.

Defined in:

Parameter:

The EventData structure.

Occurs when any unit stops firing its weapon.

Event will always correspond with a shooting start event. initiator : The unit that was doing the shooting.

Defined in:

Parameter:

The EventData structure.

Occurs when any unit begins firing a weapon that has a high rate of fire.

Most common with aircraft cannons (GAU-8), autocannons, and machine guns. initiator : The unit that is doing the shooting. target: The unit that is being targeted.

Defined in:

Parameter:

The EventData structure.

Occurs whenever any unit in a mission fires a weapon.

But not any machine gun or autocannon based weapon, those are handled by EVENT.ShootingStart.

Defined in:

Parameter:

The EventData structure.

Occurs when an aircraft takes off from an airbase, farp, or ship.

initiator : The unit that tookoff place: Object from where the AI took-off from. Can be an Airbase Object, FARP, or Ships

Defined in:

Parameter:

The EventData structure.

Occurs when the game thinks an object is destroyed.

  • initiator: The unit that is was destroyed.

Defined in:

Parameter:

The EventData structure.

Schedule a new time event.

Note that the schedule will only take place if the scheduler is started. Even for a single schedule event, the scheduler needs to be started also.

Defined in:

Parameters:

#number Start

Specifies the amount of seconds that will be waited before the scheduling is started, and the event function is called.

#function SchedulerFunction

The event function to be called when a timer event occurs. The event function needs to accept the parameters specified in SchedulerArguments.

#table ...

Optional arguments that can be given as part of scheduler. The arguments need to be given as a table { param1, param 2, ... }.

Return value:

#number:

The ScheduleID of the planned schedule.

Schedule a new time event.

Note that the schedule will only take place if the scheduler is started. Even for a single schedule event, the scheduler needs to be started also.

Defined in:

Parameters:

#number Start

Specifies the amount of seconds that will be waited before the scheduling is started, and the event function is called.

#number Repeat

Specifies the interval in seconds when the scheduler will call the event function.

#number RandomizeFactor

Specifies a randomization factor between 0 and 1 to randomize the Repeat.

#number Stop

Specifies the amount of seconds when the scheduler will be stopped.

#function SchedulerFunction

The event function to be called when a timer event occurs. The event function needs to accept the parameters specified in SchedulerArguments.

#table ...

Optional arguments that can be given as part of scheduler. The arguments need to be given as a table { param1, param 2, ... }.

Return value:

#number:

The ScheduleID of the planned schedule.

Stops the Schedule.

Defined in:

Parameter:

#function SchedulerFunction

The event function to be called when a timer event occurs. The event function needs to accept the parameters specified in SchedulerArguments.

Set the Class Event processing Priority.

The Event processing Priority is a number from 1 to 10, reflecting the order of the classes subscribed to the Event to be processed.

Defined in:

Parameter:

#number EventPriority

The Event processing Priority.

Return value:

self

Set a state or property of the Object given a Key and a Value.

Note that if the Object is destroyed, nillified or garbage collected, then the Values and Keys will also be gone.

Defined in:

Parameters:

Object

The object that will hold the Value set by the Key.

Key

The key that is used as a reference of 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:

The Value set.

Trace a function logic level 1.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function logic level 2.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace a function logic level 3.

Can be anywhere within the function logic.

Defined in:

Parameter:

Arguments

A #table or any field.

Trace all methods in MOOSE

Defined in:

Parameter:

#boolean TraceAll

true = trace all methods in MOOSE.

Set tracing for a class

Defined in:

Parameter:

#string Class

Set tracing for a specific method of class

Defined in:

Parameters:

#string Class

#string Method

Set trace level

Defined in:

Parameter:

#number Level

Set trace off.

Defined in:

Usage:

-- Switch the tracing Off
BASE:TraceOff()

Set trace on.

Defined in:

Usage:

-- Switch the tracing On
BASE:TraceOn()

Set trace on or off Note that when trace is off, no BASE.Debug statement is performed, increasing performance! When Moose is loaded statically, (as one file), tracing is switched off by default.

So tracing must be switched on manually in your mission if you are using Moose statically. When moose is loading dynamically (for moose class development), tracing is switched on by default.

Defined in:

Parameter:

#boolean TraceOnOff

Switch the tracing on or off.

Usage:

-- Switch the tracing On
BASE:TraceOnOff( true )

-- Switch the tracing Off
BASE:TraceOnOff( false )

UnSubscribe to a DCS event.

Defined in:

Parameter:

Return value:

Trace a function call.

This function is private.

Defined in:

Parameters:

Arguments

A #table or any field.

DebugInfoCurrentParam

DebugInfoFromParam

Trace a function logic.

Defined in:

Parameters:

Arguments

A #table or any field.

DebugInfoCurrentParam

DebugInfoFromParam

TODO: Complete DCS#Event structure.
- The main event handling function... This function captures all events generated for the class. @param #BASE self @param DCS#Event event

Defined in:

Parameter:

event

The POINT_VEC3 class

Field(s)

#number POINT_VEC3.x

The x coordinate in 3D space.

#number POINT_VEC3.y

The y coordinate in 3D space.

#number POINT_VEC3.z

The z coordiante in 3D space.

Function(s)

Add to the x coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Parameter:

#number x

The x coordinate value to add to the current x coodinate.

Return value:

Add to the y coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Parameter:

#number y

The y coordinate value to add to the current y coodinate.

Return value:

Add to the z coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Parameter:

#number z

The z coordinate value to add to the current z coodinate.

Return value:

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

Defined in:

POINT_VEC3

Parameters:

DCS#Distance OuterRadius

DCS#Distance InnerRadius

Return value:

Return the x coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Return value:

#number:

The x coodinate.

Return the y coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Return value:

#number:

The y coodinate.

Return the z coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Return value:

#number:

The z coodinate.

Create a new POINT_VEC3 object.

Defined in:

POINT_VEC3

Parameters:

The x coordinate of the Vec3 point, pointing to the North.

The y coordinate of the Vec3 point, pointing Upwards.

The z coordinate of the Vec3 point, pointing to the Right.

Return value:

Create a new POINT_VEC3 object from Vec2 coordinates.

Defined in:

POINT_VEC3

Parameters:

DCS#Vec2 Vec2

The Vec2 point.

DCS#Distance LandHeightAdd

(optional) Add a landheight.

Return value:

Create a new POINT_VEC3 object from Vec3 coordinates.

Defined in:

POINT_VEC3

Parameter:

DCS#Vec3 Vec3

The Vec3 point.

Return value:

Set the x coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Parameter:

#number x

The x coordinate.

Return value:

Set the y coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Parameter:

#number y

The y coordinate.

Return value:

Set the z coordinate of the POINT_VEC3.

Defined in:

POINT_VEC3

Parameter:

#number z

The z coordinate.

Return value:

RoutePoint Actions

Field(s)

Function(s)

RoutePoint AltTypes

Field(s)

Function(s)

RoutePoint Types

Field(s)

Function(s)