Module Set

Core - SET_ classes define collections of objects to perform bulk actions and logically group objects.

Banner Image


SET_ classes group objects of the same type into a collection, which is either:

  • Manually managed using the :Add...() or :Remove...() methods. The initial SET can be filtered with the **SET_BASE.FilterOnce()** method
  • Dynamically updated when new objects are created or objects are destroyed using the **SET_BASE.FilterStart()** method.

Various types of SET_ classes are available:

These classes are derived from #SET_BASE, which contains the main methods to manage SETs.

A multitude of other methods are available in SET_ classes that allow to:

  • Validate the presence of objects in the SET.
  • Trigger events when objects in the SET change a zone presence.

Authors:

  • FlightControl : Design & Programming

Contributions:

Global(s)

SET_AIRBASE

5) SET_AIRBASE class, extends Set#SET_BASE

Mission designers can use the Set#SET_AIRBASE class to build sets of airbases optionally belonging to certain:

  • Coalitions

5.1) SET_AIRBASE constructor

Create a new SET_AIRBASE object with the SET_AIRBASE.New method:

SET_BASE

1) SET_BASE class, extends Base#BASE

The Set#SET_BASE class defines the core functions that define a collection of objects.

SET_CARGO

SET_CARGO class, extends Set#SET_BASE

Mission designers can use the Set#SET_CARGO class to build sets of cargos optionally belonging to certain:

  • Coalitions
  • Types
  • Name or Prefix

SET_CARGO constructor

Create a new SET_CARGO object with the SET_CARGO.New method:

SET_CLIENT

4) SET_CLIENT class, extends Set#SET_BASE

Mission designers can use the Set#SET_CLIENT class to build sets of units belonging to certain:

  • Coalitions
  • Categories
  • Countries
  • Client types
  • Starting with certain prefix strings.
SET_GROUP

2) SET_GROUP class, extends Set#SET_BASE

Mission designers can use the Set#SET_GROUP class to build sets of groups belonging to certain:

  • Coalitions
  • Categories
  • Countries
  • Starting with certain prefix strings.
SET_UNIT

3) SET_UNIT class, extends Set#SET_BASE

Mission designers can use the SET_UNIT class to build sets of units belonging to certain:

  • Coalitions
  • Categories
  • Countries
  • Unit types
  • Starting with certain prefix strings.

Type SET_AIRBASE

SET_AIRBASE:AddAirbasesByName(AddAirbaseNames)

Add AIRBASEs to SET_AIRBASE.

SET_AIRBASE:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

SET_AIRBASE:FilterCategories(Categories)

Builds a set of airbases out of categories.

SET_AIRBASE:FilterCoalitions(Coalitions)

Builds a set of airbases of coalitions.

SET_AIRBASE:FilterStart()

Starts the filtering.

SET_AIRBASE:FindAirbase(AirbaseName)

Finds a Airbase based on the Airbase Name.

SET_AIRBASE:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

SET_AIRBASE:FindNearestAirbaseFromPointVec2(PointVec2)

Iterate the SET_AIRBASE while identifying the nearest Airbase#AIRBASE from a Point#POINT_VEC2.

SET_AIRBASE:ForEachAirbase(IteratorFunction, ...)

Iterate the SET_AIRBASE and call an interator function for each AIRBASE, providing the AIRBASE and optional parameters.

SET_AIRBASE:IsIncludeObject(MAirbase)
SET_AIRBASE:New()

Creates a new SET_AIRBASE object, building a set of airbases belonging to a coalitions and categories.

SET_AIRBASE:RemoveAirbasesByName(RemoveAirbaseNames)

Remove AIRBASEs from SET_AIRBASE.

Type SET_BASE

SET_BASE:Add(ObjectName, Object)

Adds a Base#BASE object in the Set#SET_BASE, using a given ObjectName as the index.

SET_BASE:AddObject(Object)

Adds a Base#BASE object in the Set#SET_BASE, using the Object Name as the index.

SET_BASE.CallScheduler
SET_BASE:Count()

Retrieves the amount of objects in the Set#SET_BASE and derived classes.

SET_BASE.Database
SET_BASE.Filter
SET_BASE:FilterOnce()

Filters for the defined collection.

SET_BASE:FilterStop()

Stops the filtering for the defined collection.

SET_BASE:FindNearestObjectFromPointVec2(PointVec2)

Iterate the SET_BASE while identifying the nearest object from a Point#POINT_VEC2.

SET_BASE:Flush()

Flushes the current SET_BASE contents in the log ...

SET_BASE:ForEach(IteratorFunction, arg, Set, Function, FunctionArguments)

Iterate the SETBASE and derived classes and call an iterator function for the given SETBASE, providing the Object for each element within the set and optional parameters.

SET_BASE:Get(ObjectName)

Gets a Base#BASE object from the Set#SET_BASE and derived classes, based on the Object Name.

SET_BASE:GetFirst()

Gets the first object from the Set#SET_BASE and derived classes.

SET_BASE:GetLast()

Gets the last object from the Set#SET_BASE and derived classes.

SET_BASE:GetRandom()

Gets a random object from the Set#SET_BASE and derived classes.

SET_BASE:GetSet()

Gets the Set.

SET_BASE:IsIncludeObject(Object)

Decides whether to include the Object

SET_BASE.List
SET_BASE:New(Database)

Creates a new SET_BASE object, building a set of units belonging to a coalitions, categories, countries, types or with defined prefix names.

SET_BASE:Remove(ObjectName)

Removes a Base#BASE object from the Set#SET_BASE and derived classes, based on the Object Name.

SET_BASE.Set
SET_BASE:SetDatabase(BaseSet)

Copies the Filter criteria from a given Set (for rebuilding a new Set based on an existing Set).

SET_BASE:SetIteratorIntervals(YieldInterval, TimeInterval)

Define the SET iterator "yield interval" and the "time interval".

SET_BASE.TimeInterval
SET_BASE.YieldInterval
SET_BASE:_EventOnBirth(Event)

Handles the OnBirth event for the Set.

SET_BASE:_EventOnDeadOrCrash(Event)

Handles the OnDead or OnCrash event for alive units set.

SET_BASE:_EventOnPlayerEnterUnit(Event)

Handles the OnPlayerEnterUnit event to fill the active players table (with the unit filter applied).

SET_BASE:_EventOnPlayerLeaveUnit(Event)

Handles the OnPlayerLeaveUnit event to clean the active players table.

SET_BASE:_FilterStart()

Starts the filtering for the defined collection.

SET_BASE:_Find(ObjectName)

Finds an Base#BASE object based on the object Name.

Type SET_CARGO

SET_CARGO:AddCargosByName(AddCargoNames)

Add CARGOs to SET_CARGO.

SET_CARGO:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

SET_CARGO:FilterCoalitions(Coalitions)

Builds a set of cargos of coalitions.

SET_CARGO:FilterCountries(Countries)

Builds a set of cargos of defined countries.

SET_CARGO:FilterPrefixes(Prefixes)

Builds a set of cargos of defined cargo prefixes.

SET_CARGO:FilterStart()

Starts the filtering.

SET_CARGO:FilterTypes(Types)

Builds a set of cargos of defined cargo types.

SET_CARGO:FindCargo(CargoName)

Finds a Cargo based on the Cargo Name.

SET_CARGO:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

SET_CARGO:FindNearestCargoFromPointVec2(PointVec2)

Iterate the SET_CARGO while identifying the nearest Cargo#CARGO from a Point#POINT_VEC2.

SET_CARGO:ForEachCargo(IteratorFunction, ...)

Iterate the SET_CARGO and call an interator function for each CARGO, providing the CARGO and optional parameters.

SET_CARGO:IsIncludeObject(MCargo)
SET_CARGO:New()

Creates a new SET_CARGO object, building a set of cargos belonging to a coalitions and categories.

SET_CARGO:OnEventDeleteCargo(EventData)

Handles the OnDead or OnCrash event for alive units set.

SET_CARGO:OnEventNewCargo(EventData)

Handles the OnEventNewCargo event for the Set.

SET_CARGO:RemoveCargosByName(RemoveCargoNames)

Remove CARGOs from SET_CARGO.

Type SET_CLIENT

SET_CLIENT:AddClientsByName(AddClientNames)

Add CLIENT(s) to SET_CLIENT.

SET_CLIENT:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

SET_CLIENT:FilterCategories(Categories)

Builds a set of clients out of categories.

SET_CLIENT:FilterCoalitions(Coalitions)

Builds a set of clients of coalitions.

SET_CLIENT:FilterCountries(Countries)

Builds a set of clients of defined countries.

SET_CLIENT:FilterPrefixes(Prefixes)

Builds a set of clients of defined client prefixes.

SET_CLIENT:FilterStart()

Starts the filtering.

SET_CLIENT:FilterTypes(Types)

Builds a set of clients of defined client types.

SET_CLIENT:FindClient(ClientName)

Finds a Client based on the Client Name.

SET_CLIENT:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

SET_CLIENT:ForEachClient(IteratorFunction, ...)

Iterate the SET_CLIENT and call an interator function for each alive CLIENT, providing the CLIENT and optional parameters.

SET_CLIENT:ForEachClientInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_CLIENT and call an iterator function for each alive CLIENT presence completely in a Zone, providing the CLIENT and optional parameters to the called function.

SET_CLIENT:ForEachClientNotInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_CLIENT and call an iterator function for each alive CLIENT presence not in a Zone, providing the CLIENT and optional parameters to the called function.

SET_CLIENT:IsIncludeObject(MClient)
SET_CLIENT:New()

Creates a new SET_CLIENT object, building a set of clients belonging to a coalitions, categories, countries, types or with defined prefix names.

SET_CLIENT:RemoveClientsByName(RemoveClientNames)

Remove CLIENT(s) from SET_CLIENT.

Type SET_GROUP

SET_GROUP:AddGroupsByName(AddGroupNames)

Add GROUP(s) to SET_GROUP.

SET_GROUP:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

SET_GROUP:FilterCategories(Categories)

Builds a set of groups out of categories.

SET_GROUP:FilterCoalitions(Coalitions)

Builds a set of groups of coalitions.

SET_GROUP:FilterCountries(Countries)

Builds a set of groups of defined countries.

SET_GROUP:FilterPrefixes(Prefixes)

Builds a set of groups of defined GROUP prefixes.

SET_GROUP:FilterStart()

Starts the filtering.

SET_GROUP:FindGroup(GroupName)

Finds a Group based on the Group Name.

SET_GROUP:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

SET_GROUP:FindNearestGroupFromPointVec2(PointVec2)

Iterate the SET_GROUP while identifying the nearest object from a Point#POINT_VEC2.

SET_GROUP:ForEachGroup(IteratorFunction, ...)

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

SET_GROUP:ForEachGroupCompletelyInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_GROUP and call an iterator function for each alive GROUP presence completely in a Zone, providing the GROUP and optional parameters to the called function.

SET_GROUP:ForEachGroupNotInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_GROUP and call an iterator function for each alive GROUP presence not in a Zone, providing the GROUP and optional parameters to the called function.

SET_GROUP:ForEachGroupPartlyInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_GROUP and call an iterator function for each alive GROUP presence partly in a Zone, providing the GROUP and optional parameters to the called function.

SET_GROUP:IsIncludeObject(MooseGroup)
SET_GROUP:New()

Creates a new SET_GROUP object, building a set of groups belonging to a coalitions, categories, countries, types or with defined prefix names.

SET_GROUP:RemoveGroupsByName(RemoveGroupNames)

Remove GROUP(s) from SET_GROUP.

Type SET_UNIT

SET_UNIT:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

SET_UNIT:AddUnit(AddUnit)

Add UNIT(s) to SET_UNIT.

SET_UNIT:AddUnitsByName(AddUnitNames)

Add UNIT(s) to SET_UNIT.

SET_UNIT:CalculateThreatLevelA2G()

Calculate the maxium A2G threat level of the SET_UNIT.

SET_UNIT:FilterCategories(Categories)

Builds a set of units out of categories.

SET_UNIT:FilterCoalitions(Coalitions)

Builds a set of units of coalitions.

SET_UNIT:FilterCountries(Countries)

Builds a set of units of defined countries.

SET_UNIT:FilterHasRadar(RadarTypes)

Builds a set of units having a radar of give types.

SET_UNIT:FilterHasSEAD()

Builds a set of SEADable units.

SET_UNIT:FilterPrefixes(Prefixes)

Builds a set of units of defined unit prefixes.

SET_UNIT:FilterStart()

Starts the filtering.

SET_UNIT:FilterTypes(Types)

Builds a set of units of defined unit types.

SET_UNIT:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

SET_UNIT:FindUnit(UnitName)

Finds a Unit based on the Unit Name.

SET_UNIT:ForEachUnit(IteratorFunction, ...)

Iterate the SET_UNIT and call an interator function for each alive UNIT, providing the UNIT and optional parameters.

SET_UNIT:ForEachUnitCompletelyInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_UNIT and call an iterator function for each alive UNIT presence completely in a Zone, providing the UNIT and optional parameters to the called function.

SET_UNIT:ForEachUnitNotInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_UNIT and call an iterator function for each alive UNIT presence not in a Zone, providing the UNIT and optional parameters to the called function.

SET_UNIT:GetTypeNames(Delimiter)

Retrieve the type names of the Units in the SET, delimited by an optional delimiter.

SET_UNIT:GetUnitThreatLevels()

Returns map of unit threat levels.

SET_UNIT:GetUnitTypes()

Returns map of unit types.

SET_UNIT:GetUnitTypesText()

Returns a comma separated string of the unit types with a count in the Set.

SET_UNIT:HasFriendlyUnits(FriendlyCoalition)

Returns if the Set has friendly ground units.

SET_UNIT:HasGroundUnits()

Returns if the Set has ground targets.

SET_UNIT:HasRadar(RadarType)

Returns if the Set has targets having a radar (of a given type).

SET_UNIT:HasSEAD()

Returns if the Set has targets that can be SEADed.

SET_UNIT:IsIncludeObject(MUnit)
SET_UNIT:New()

Creates a new SET_UNIT object, building a set of units belonging to a coalitions, categories, countries, types or with defined prefix names.

SET_UNIT:RemoveUnitsByName(RemoveUnitNames)

Remove UNIT(s) from SET_UNIT.

Global(s)

#SET_AIRBASE SET_AIRBASE

5) SET_AIRBASE class, extends Set#SET_BASE

Mission designers can use the Set#SET_AIRBASE class to build sets of airbases optionally belonging to certain:

  • Coalitions

5.1) SET_AIRBASE constructor

Create a new SET_AIRBASE object with the SET_AIRBASE.New method:

5.2) Add or Remove AIRBASEs from SET_AIRBASE

AIRBASEs can be added and removed using the Set#SET_AIRBASE.AddAirbasesByName and Set#SET_AIRBASE.RemoveAirbasesByName respectively. These methods take a single AIRBASE name or an array of AIRBASE names to be added or removed from SET_AIRBASE.

5.3) SET_AIRBASE filter criteria

You can set filter criteria to define the set of clients within the SET_AIRBASE. Filter criteria are defined by:

Once the filter criteria have been set for the SET_AIRBASE, you can start filtering using:

5.4) SET_AIRBASE iterators

Once the filters have been defined and the SETAIRBASE has been built, you can iterate the SETAIRBASE with the available iterator methods. The iterator methods will walk the SETAIRBASE set, and call for each airbase within the set a function that you provide. The following iterator methods are currently available within the SETAIRBASE:


#SET_BASE SET_BASE

1) SET_BASE class, extends Base#BASE

The Set#SET_BASE class defines the core functions that define a collection of objects.

A SET provides iterators to iterate the SET, but will temporarily yield the ForEach interator loop at defined "intervals" to the mail simulator loop. In this way, large loops can be done while not blocking the simulator main processing loop. The default "yield interval" is after 10 objects processed. The default "time interval" is after 0.001 seconds.

1.1) Add or remove objects from the SET

Some key core functions are Set#SET_BASE.Add and Set#SET_BASE.Remove to add or remove objects from the SET in your logic.

1.2) Define the SET iterator "yield interval" and the "time interval"

Modify the iterator intervals with the Set#SET_BASE.SetInteratorIntervals method. You can set the "yield interval", and the "time interval". (See above).

#SET_CARGO SET_CARGO

SET_CARGO class, extends Set#SET_BASE

Mission designers can use the Set#SET_CARGO class to build sets of cargos optionally belonging to certain:

  • Coalitions
  • Types
  • Name or Prefix

SET_CARGO constructor

Create a new SET_CARGO object with the SET_CARGO.New method:

Add or Remove CARGOs from SET_CARGO

CARGOs can be added and removed using the Set#SET_CARGO.AddCargosByName and Set#SET_CARGO.RemoveCargosByName respectively. These methods take a single CARGO name or an array of CARGO names to be added or removed from SET_CARGO.

SET_CARGO filter criteria

You can set filter criteria to automatically maintain the SET_CARGO contents. Filter criteria are defined by:

Once the filter criteria have been set for the SET_CARGO, you can start filtering using:

SET_CARGO iterators

Once the filters have been defined and the SETCARGO has been built, you can iterate the SETCARGO with the available iterator methods. The iterator methods will walk the SETCARGO set, and call for each cargo within the set a function that you provide. The following iterator methods are currently available within the SETCARGO:

#SET_CLIENT SET_CLIENT

4) SET_CLIENT class, extends Set#SET_BASE

Mission designers can use the Set#SET_CLIENT class to build sets of units belonging to certain:

  • Coalitions
  • Categories
  • Countries
  • Client types
  • Starting with certain prefix strings.

4.1) SET_CLIENT constructor

Create a new SET_CLIENT object with the SET_CLIENT.New method:

4.2) Add or Remove CLIENT(s) from SET_CLIENT

CLIENTs can be added and removed using the Set#SET_CLIENT.AddClientsByName and Set#SET_CLIENT.RemoveClientsByName respectively. These methods take a single CLIENT name or an array of CLIENT names to be added or removed from SET_CLIENT.

4.3) SET_CLIENT filter criteria

You can set filter criteria to define the set of clients within the SET_CLIENT. Filter criteria are defined by:

Once the filter criteria have been set for the SET_CLIENT, you can start filtering using:

Planned filter criteria within development are (so these are not yet available):

4.4) SET_CLIENT iterators

Once the filters have been defined and the SETCLIENT has been built, you can iterate the SETCLIENT with the available iterator methods. The iterator methods will walk the SETCLIENT set, and call for each element within the set a function that you provide. The following iterator methods are currently available within the SETCLIENT:


#SET_GROUP SET_GROUP

2) SET_GROUP class, extends Set#SET_BASE

Mission designers can use the Set#SET_GROUP class to build sets of groups belonging to certain:

  • Coalitions
  • Categories
  • Countries
  • Starting with certain prefix strings.

2.1) SET_GROUP constructor

Create a new SET_GROUP object with the SET_GROUP.New method:

2.2) Add or Remove GROUP(s) from SET_GROUP

GROUPS can be added and removed using the Set#SET_GROUP.AddGroupsByName and Set#SET_GROUP.RemoveGroupsByName respectively. These methods take a single GROUP name or an array of GROUP names to be added or removed from SET_GROUP.

2.3) SET_GROUP filter criteria

You can set filter criteria to define the set of groups within the SET_GROUP. Filter criteria are defined by:

Once the filter criteria have been set for the SET_GROUP, you can start filtering using:

  • SET_GROUP.FilterStart: Starts the filtering of the groups within the SET_GROUP and add or remove GROUP objects dynamically.

Planned filter criteria within development are (so these are not yet available):

2.4) SET_GROUP iterators

Once the filters have been defined and the SETGROUP has been built, you can iterate the SETGROUP with the available iterator methods. The iterator methods will walk the SETGROUP set, and call for each element within the set a function that you provide. The following iterator methods are currently available within the SETGROUP:

  • SET_GROUP.ForEachGroup: Calls a function for each alive group it finds within the SET_GROUP.
  • SET_GROUP.ForEachGroupCompletelyInZone: Iterate the SET_GROUP and call an iterator function for each alive GROUP presence completely in a Zone, providing the GROUP and optional parameters to the called function.
  • SET_GROUP.ForEachGroupPartlyInZone: Iterate the SET_GROUP and call an iterator function for each alive GROUP presence partly in a Zone, providing the GROUP and optional parameters to the called function.
  • SET_GROUP.ForEachGroupNotInZone: Iterate the SET_GROUP and call an iterator function for each alive GROUP presence not in a Zone, providing the GROUP and optional parameters to the called function.

#SET_UNIT SET_UNIT

3) SET_UNIT class, extends Set#SET_BASE

Mission designers can use the SET_UNIT class to build sets of units belonging to certain:

  • Coalitions
  • Categories
  • Countries
  • Unit types
  • Starting with certain prefix strings.

3.1) SET_UNIT constructor

Create a new SET_UNIT object with the SET_UNIT.New method:

3.2) Add or Remove UNIT(s) from SET_UNIT

UNITs can be added and removed using the Set#SET_UNIT.AddUnitsByName and Set#SET_UNIT.RemoveUnitsByName respectively. These methods take a single UNIT name or an array of UNIT names to be added or removed from SET_UNIT.

3.3) SET_UNIT filter criteria

You can set filter criteria to define the set of units within the SET_UNIT. Filter criteria are defined by:

Once the filter criteria have been set for the SET_UNIT, you can start filtering using:

Planned filter criteria within development are (so these are not yet available):

3.4) SET_UNIT iterators

Once the filters have been defined and the SETUNIT has been built, you can iterate the SETUNIT with the available iterator methods. The iterator methods will walk the SETUNIT set, and call for each element within the set a function that you provide. The following iterator methods are currently available within the SETUNIT:

  • SET_UNIT.ForEachUnit: Calls a function for each alive unit it finds within the SET_UNIT.
  • SET_GROUP.ForEachGroupCompletelyInZone: Iterate the SET_GROUP and call an iterator function for each alive GROUP presence completely in a Zone, providing the GROUP and optional parameters to the called function.
  • SET_GROUP.ForEachGroupNotInZone: Iterate the SET_GROUP and call an iterator function for each alive GROUP presence not in a Zone, providing the GROUP and optional parameters to the called function.

Planned iterators methods in development are (so these are not yet available):

3.5 ) SET_UNIT atomic methods

Various methods exist for a SETUNIT to perform actions or calculations and retrieve results from the SETUNIT:


Type Set

Type SET_AIRBASE

Field(s)

SET_AIRBASE:AddAirbasesByName(AddAirbaseNames)

Add AIRBASEs to SET_AIRBASE.

Parameter

  • #string AddAirbaseNames : A single name or an array of AIRBASE names.

Return value

self

SET_AIRBASE:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

This is required, because sometimes the DATABASE birth event gets called later than the SETBASE birth event!

Parameter

Return values

  1. #string: The name of the AIRBASE

  2. #table: The AIRBASE

SET_AIRBASE:FilterCategories(Categories)

Builds a set of airbases out of categories.

Possible current categories are plane, helicopter, ground, ship.

Parameter

  • #string Categories : Can take the following values: "airdrome", "helipad", "ship".

Return value

#SET_AIRBASE: self

SET_AIRBASE:FilterCoalitions(Coalitions)

Builds a set of airbases of coalitions.

Possible current coalitions are red, blue and neutral.

Parameter

  • #string Coalitions : Can take the following values: "red", "blue", "neutral".

Return value

#SET_AIRBASE: self

SET_AIRBASE:FilterStart()

Starts the filtering.

Return value

#SET_AIRBASE: self

SET_AIRBASE:FindAirbase(AirbaseName)

Finds a Airbase based on the Airbase Name.

Parameter

  • #string AirbaseName :

Return value

Wrapper.Airbase#AIRBASE: The found Airbase.

SET_AIRBASE:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

This is required, because sometimes the DATABASE event gets called later than the SETBASE event or vise versa!

Parameter

Return values

  1. #string: The name of the AIRBASE

  2. #table: The AIRBASE

SET_AIRBASE:FindNearestAirbaseFromPointVec2(PointVec2)

Iterate the SET_AIRBASE while identifying the nearest Airbase#AIRBASE from a Point#POINT_VEC2.

Parameter

Return value

Wrapper.Airbase#AIRBASE: The closest Airbase#AIRBASE.

SET_AIRBASE:ForEachAirbase(IteratorFunction, ...)

Iterate the SET_AIRBASE and call an interator function for each AIRBASE, providing the AIRBASE and optional parameters.

Parameters

  • #function IteratorFunction : The function that will be called when there is an alive AIRBASE in the SET_AIRBASE. The function needs to accept a AIRBASE parameter.

  • ... :

Return value

#SET_AIRBASE: self

SET_AIRBASE:IsIncludeObject(MAirbase)

Parameter

Return value

#SET_AIRBASE: self

SET_AIRBASE:New()

Creates a new SET_AIRBASE object, building a set of airbases belonging to a coalitions and categories.

Return value

#SET_AIRBASE: self

Usage:

-- Define a new SET_AIRBASE Object. The DatabaseSet will contain a reference to all Airbases.
DatabaseSet = SET_AIRBASE:New()
SET_AIRBASE:RemoveAirbasesByName(RemoveAirbaseNames)

Remove AIRBASEs from SET_AIRBASE.

Parameter

Return value

self

Type SET_BASE

Field(s)

SET_BASE:Add(ObjectName, Object)

Adds a Base#BASE object in the Set#SET_BASE, using a given ObjectName as the index.

Parameters

Return value

Core.Base#BASE: The added BASE Object.

SET_BASE:AddObject(Object)

Adds a Base#BASE object in the Set#SET_BASE, using the Object Name as the index.

Parameter

Return value

Core.Base#BASE: The added BASE Object.

Core.Scheduler#SCHEDULER SET_BASE.CallScheduler
SET_BASE:Count()

Retrieves the amount of objects in the Set#SET_BASE and derived classes.

Return value

#number: Count

SET_BASE.Database

Now base the new Set on the BaseSet

#table SET_BASE.Filter
SET_BASE:FilterOnce()

Filters for the defined collection.

Return value

#SET_BASE: self

SET_BASE:FilterStop()

Stops the filtering for the defined collection.

Return value

#SET_BASE: self

SET_BASE:FindNearestObjectFromPointVec2(PointVec2)

Iterate the SET_BASE while identifying the nearest object from a Point#POINT_VEC2.

Parameter

Return value

Core.Base#BASE: The closest object.

SET_BASE:Flush()

Flushes the current SET_BASE contents in the log ...

(for debugging reasons).

Return value

#string: A string with the names of the objects.

SET_BASE:ForEach(IteratorFunction, arg, Set, Function, FunctionArguments)

Iterate the SETBASE and derived classes and call an iterator function for the given SETBASE, providing the Object for each element within the set and optional parameters.

Parameters

  • #function IteratorFunction : The function that will be called.

  • arg :

  • Set :

  • Function :

  • FunctionArguments :

Return value

#SET_BASE: self

SET_BASE:Get(ObjectName)

Gets a Base#BASE object from the Set#SET_BASE and derived classes, based on the Object Name.

Parameter

  • #string ObjectName :

Return value

Core.Base#BASE:

SET_BASE:GetFirst()

Gets the first object from the Set#SET_BASE and derived classes.

Return value

Core.Base#BASE:

SET_BASE:GetLast()

Gets the last object from the Set#SET_BASE and derived classes.

Return value

Core.Base#BASE:

SET_BASE:GetRandom()

Gets a random object from the Set#SET_BASE and derived classes.

Return value

Core.Base#BASE:

SET_BASE:GetSet()

Gets the Set.

Return value

#SET_BASE: self

SET_BASE:IsIncludeObject(Object)

Decides whether to include the Object

Parameter

  • #table Object :

Return value

#SET_BASE: self

#table SET_BASE.List
SET_BASE:New(Database)

Creates a new SET_BASE object, building a set of units belonging to a coalitions, categories, countries, types or with defined prefix names.

Parameter

  • Database :

Return value

#SET_BASE:

Usage:

-- Define a new SET_BASE Object. This DBObject will contain a reference to all Group and Unit Templates defined within the ME and the DCSRTE.
DBObject = SET_BASE:New()
SET_BASE:Remove(ObjectName)

Removes a Base#BASE object from the Set#SET_BASE and derived classes, based on the Object Name.

Parameter

  • #string ObjectName :

#table SET_BASE.Set
SET_BASE:SetDatabase(BaseSet)

Copies the Filter criteria from a given Set (for rebuilding a new Set based on an existing Set).

Parameter

Return value

#SET_BASE:

SET_BASE:SetIteratorIntervals(YieldInterval, TimeInterval)

Define the SET iterator "yield interval" and the "time interval".

Parameters

  • #number YieldInterval : Sets the frequency when the iterator loop will yield after the number of objects processed. The default frequency is 10 objects processed.

  • #number TimeInterval : Sets the time in seconds when the main logic will resume the iterator loop. The default time is 0.001 seconds.

Return value

#SET_BASE: self

SET_BASE.TimeInterval
SET_BASE.YieldInterval
SET_BASE:_EventOnBirth(Event)

Handles the OnBirth event for the Set.

Parameter

SET_BASE:_EventOnDeadOrCrash(Event)

Handles the OnDead or OnCrash event for alive units set.

Parameter

SET_BASE:_EventOnPlayerEnterUnit(Event)

Handles the OnPlayerEnterUnit event to fill the active players table (with the unit filter applied).

Parameter

SET_BASE:_EventOnPlayerLeaveUnit(Event)

Handles the OnPlayerLeaveUnit event to clean the active players table.

Parameter

SET_BASE:_FilterStart()

Starts the filtering for the defined collection.

Return value

#SET_BASE: self

SET_BASE:_Find(ObjectName)

Finds an Base#BASE object based on the object Name.

Parameter

  • #string ObjectName :

Return value

Core.Base#BASE: The Object found.

Type SET_CARGO

Field(s)

SET_CARGO:AddCargosByName(AddCargoNames)

Add CARGOs to SET_CARGO.

Parameter

  • #string AddCargoNames : A single name or an array of CARGO names.

Return value

self

SET_CARGO:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

This is required, because sometimes the DATABASE birth event gets called later than the SETBASE birth event!

Parameter

Return values

  1. #string: The name of the CARGO

  2. #table: The CARGO

SET_CARGO:FilterCoalitions(Coalitions)

Builds a set of cargos of coalitions.

Possible current coalitions are red, blue and neutral.

Parameter

  • #string Coalitions : Can take the following values: "red", "blue", "neutral".

Return value

#SET_CARGO: self

SET_CARGO:FilterCountries(Countries)

Builds a set of cargos of defined countries.

Possible current countries are those known within DCS world.

Parameter

  • #string Countries : Can take those country strings known within DCS world.

Return value

#SET_CARGO: self

SET_CARGO:FilterPrefixes(Prefixes)

Builds a set of cargos of defined cargo prefixes.

All the cargos starting with the given prefixes will be included within the set.

Parameter

  • #string Prefixes : The prefix of which the cargo name starts with.

Return value

#SET_CARGO: self

SET_CARGO:FilterStart()

Starts the filtering.

Return value

#SET_CARGO: self

SET_CARGO:FilterTypes(Types)

Builds a set of cargos of defined cargo types.

Possible current types are those types known within DCS world.

Parameter

  • #string Types : Can take those type strings known within DCS world.

Return value

#SET_CARGO: self

SET_CARGO:FindCargo(CargoName)

Finds a Cargo based on the Cargo Name.

Parameter

  • #string CargoName :

Return value

Wrapper.Cargo#CARGO: The found Cargo.

SET_CARGO:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

This is required, because sometimes the DATABASE event gets called later than the SETBASE event or vise versa!

Parameter

Return values

  1. #string: The name of the CARGO

  2. #table: The CARGO

SET_CARGO:FindNearestCargoFromPointVec2(PointVec2)

Iterate the SET_CARGO while identifying the nearest Cargo#CARGO from a Point#POINT_VEC2.

Parameter

Return value

Wrapper.Cargo#CARGO: The closest Cargo#CARGO.

SET_CARGO:ForEachCargo(IteratorFunction, ...)

Iterate the SET_CARGO and call an interator function for each CARGO, providing the CARGO and optional parameters.

Parameters

  • #function IteratorFunction : The function that will be called when there is an alive CARGO in the SET_CARGO. The function needs to accept a CARGO parameter.

  • ... :

Return value

#SET_CARGO: self

SET_CARGO:IsIncludeObject(MCargo)

Parameter

Return value

#SET_CARGO: self

SET_CARGO:New()

Creates a new SET_CARGO object, building a set of cargos belonging to a coalitions and categories.

Return value

#SET_CARGO: self

Usage:

-- Define a new SET_CARGO Object. The DatabaseSet will contain a reference to all Cargos.
DatabaseSet = SET_CARGO:New()
SET_CARGO:OnEventDeleteCargo(EventData)

Handles the OnDead or OnCrash event for alive units set.

Parameter

SET_CARGO:OnEventNewCargo(EventData)

Handles the OnEventNewCargo event for the Set.

Parameter

SET_CARGO:RemoveCargosByName(RemoveCargoNames)

Remove CARGOs from SET_CARGO.

Parameter

Return value

self

Type SET_CLIENT

Field(s)

SET_CLIENT:AddClientsByName(AddClientNames)

Add CLIENT(s) to SET_CLIENT.

Parameter

  • #string AddClientNames : A single name or an array of CLIENT names.

Return value

self

SET_CLIENT:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

This is required, because sometimes the DATABASE birth event gets called later than the SETBASE birth event!

Parameter

Return values

  1. #string: The name of the CLIENT

  2. #table: The CLIENT

SET_CLIENT:FilterCategories(Categories)

Builds a set of clients out of categories.

Possible current categories are plane, helicopter, ground, ship.

Parameter

  • #string Categories : Can take the following values: "plane", "helicopter", "ground", "ship".

Return value

#SET_CLIENT: self

SET_CLIENT:FilterCoalitions(Coalitions)

Builds a set of clients of coalitions.

Possible current coalitions are red, blue and neutral.

Parameter

  • #string Coalitions : Can take the following values: "red", "blue", "neutral".

Return value

#SET_CLIENT: self

SET_CLIENT:FilterCountries(Countries)

Builds a set of clients of defined countries.

Possible current countries are those known within DCS world.

Parameter

  • #string Countries : Can take those country strings known within DCS world.

Return value

#SET_CLIENT: self

SET_CLIENT:FilterPrefixes(Prefixes)

Builds a set of clients of defined client prefixes.

All the clients starting with the given prefixes will be included within the set.

Parameter

  • #string Prefixes : The prefix of which the client name starts with.

Return value

#SET_CLIENT: self

SET_CLIENT:FilterStart()

Starts the filtering.

Return value

#SET_CLIENT: self

SET_CLIENT:FilterTypes(Types)

Builds a set of clients of defined client types.

Possible current types are those types known within DCS world.

Parameter

  • #string Types : Can take those type strings known within DCS world.

Return value

#SET_CLIENT: self

SET_CLIENT:FindClient(ClientName)

Finds a Client based on the Client Name.

Parameter

  • #string ClientName :

Return value

Wrapper.Client#CLIENT: The found Client.

SET_CLIENT:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

This is required, because sometimes the DATABASE event gets called later than the SETBASE event or vise versa!

Parameter

Return values

  1. #string: The name of the CLIENT

  2. #table: The CLIENT

SET_CLIENT:ForEachClient(IteratorFunction, ...)

Iterate the SET_CLIENT and call an interator function for each alive CLIENT, providing the CLIENT and optional parameters.

Parameters

  • #function IteratorFunction : The function that will be called when there is an alive CLIENT in the SET_CLIENT. The function needs to accept a CLIENT parameter.

  • ... :

Return value

#SET_CLIENT: self

SET_CLIENT:ForEachClientInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_CLIENT and call an iterator function for each alive CLIENT presence completely in a Zone, providing the CLIENT and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive CLIENT in the SET_CLIENT. The function needs to accept a CLIENT parameter.

  • ... :

Return value

#SET_CLIENT: self

SET_CLIENT:ForEachClientNotInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_CLIENT and call an iterator function for each alive CLIENT presence not in a Zone, providing the CLIENT and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive CLIENT in the SET_CLIENT. The function needs to accept a CLIENT parameter.

  • ... :

Return value

#SET_CLIENT: self

SET_CLIENT:IsIncludeObject(MClient)

Parameter

Return value

#SET_CLIENT: self

SET_CLIENT:New()

Creates a new SET_CLIENT object, building a set of clients belonging to a coalitions, categories, countries, types or with defined prefix names.

Return value

#SET_CLIENT:

Usage:

-- Define a new SET_CLIENT Object. This DBObject will contain a reference to all Clients.
DBObject = SET_CLIENT:New()
SET_CLIENT:RemoveClientsByName(RemoveClientNames)

Remove CLIENT(s) from SET_CLIENT.

Parameter

Return value

self

Type SET_GROUP

Field(s)

SET_GROUP:AddGroupsByName(AddGroupNames)

Add GROUP(s) to SET_GROUP.

Parameter

  • #string AddGroupNames : A single name or an array of GROUP names.

Return value

self

SET_GROUP:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

This is required, because sometimes the DATABASE birth event gets called later than the SETBASE birth event!

Parameter

Return values

  1. #string: The name of the GROUP

  2. #table: The GROUP

SET_GROUP:FilterCategories(Categories)

Builds a set of groups out of categories.

Possible current categories are plane, helicopter, ground, ship.

Parameter

  • #string Categories : Can take the following values: "plane", "helicopter", "ground", "ship".

Return value

#SET_GROUP: self

SET_GROUP:FilterCoalitions(Coalitions)

Builds a set of groups of coalitions.

Possible current coalitions are red, blue and neutral.

Parameter

  • #string Coalitions : Can take the following values: "red", "blue", "neutral".

Return value

#SET_GROUP: self

SET_GROUP:FilterCountries(Countries)

Builds a set of groups of defined countries.

Possible current countries are those known within DCS world.

Parameter

  • #string Countries : Can take those country strings known within DCS world.

Return value

#SET_GROUP: self

SET_GROUP:FilterPrefixes(Prefixes)

Builds a set of groups of defined GROUP prefixes.

All the groups starting with the given prefixes will be included within the set.

Parameter

  • #string Prefixes : The prefix of which the group name starts with.

Return value

#SET_GROUP: self

SET_GROUP:FilterStart()

Starts the filtering.

Return value

#SET_GROUP: self

SET_GROUP:FindGroup(GroupName)

Finds a Group based on the Group Name.

Parameter

  • #string GroupName :

Return value

Wrapper.Group#GROUP: The found Group.

SET_GROUP:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

This is required, because sometimes the DATABASE event gets called later than the SETBASE event or vise versa!

Parameter

Return values

  1. #string: The name of the GROUP

  2. #table: The GROUP

SET_GROUP:FindNearestGroupFromPointVec2(PointVec2)

Iterate the SET_GROUP while identifying the nearest object from a Point#POINT_VEC2.

Parameter

Return value

Wrapper.Group#GROUP: The closest group.

SET_GROUP:ForEachGroup(IteratorFunction, ...)

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

Parameters

  • #function IteratorFunction : The function that will be called when there is an alive GROUP in the SET_GROUP. The function needs to accept a GROUP parameter.

  • ... :

Return value

#SET_GROUP: self

SET_GROUP:ForEachGroupCompletelyInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_GROUP and call an iterator function for each alive GROUP presence completely in a Zone, providing the GROUP and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive GROUP in the SET_GROUP. The function needs to accept a GROUP parameter.

  • ... :

Return value

#SET_GROUP: self

SET_GROUP:ForEachGroupNotInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_GROUP and call an iterator function for each alive GROUP presence not in a Zone, providing the GROUP and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive GROUP in the SET_GROUP. The function needs to accept a GROUP parameter.

  • ... :

Return value

#SET_GROUP: self

SET_GROUP:ForEachGroupPartlyInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_GROUP and call an iterator function for each alive GROUP presence partly in a Zone, providing the GROUP and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive GROUP in the SET_GROUP. The function needs to accept a GROUP parameter.

  • ... :

Return value

#SET_GROUP: self

SET_GROUP:IsIncludeObject(MooseGroup)

Parameter

Return value

#SET_GROUP: self

SET_GROUP:New()

Creates a new SET_GROUP object, building a set of groups belonging to a coalitions, categories, countries, types or with defined prefix names.

Return value

#SET_GROUP:

Usage:

-- Define a new SET_GROUP Object. This DBObject will contain a reference to all alive GROUPS.
DBObject = SET_GROUP:New()
SET_GROUP:RemoveGroupsByName(RemoveGroupNames)

Remove GROUP(s) from SET_GROUP.

Parameter

Return value

self

Type SET_UNIT

Field(s)

SET_UNIT:AddInDatabase(Event)

Handles the Database to check on an event (birth) that the Object was added in the Database.

This is required, because sometimes the DATABASE birth event gets called later than the SETBASE birth event!

Parameter

Return values

  1. #string: The name of the UNIT

  2. #table: The UNIT

SET_UNIT:AddUnit(AddUnit)

Add UNIT(s) to SET_UNIT.

Parameter

  • #string AddUnit : A single UNIT.

Return value

#SET_UNIT: self

SET_UNIT:AddUnitsByName(AddUnitNames)

Add UNIT(s) to SET_UNIT.

Parameter

  • #string AddUnitNames : A single name or an array of UNIT names.

Return value

#SET_UNIT: self

SET_UNIT:CalculateThreatLevelA2G()

Calculate the maxium A2G threat level of the SET_UNIT.

SET_UNIT:FilterCategories(Categories)

Builds a set of units out of categories.

Possible current categories are plane, helicopter, ground, ship.

Parameter

  • #string Categories : Can take the following values: "plane", "helicopter", "ground", "ship".

Return value

#SET_UNIT: self

SET_UNIT:FilterCoalitions(Coalitions)

Builds a set of units of coalitions.

Possible current coalitions are red, blue and neutral.

Parameter

  • #string Coalitions : Can take the following values: "red", "blue", "neutral".

Return value

#SET_UNIT: self

SET_UNIT:FilterCountries(Countries)

Builds a set of units of defined countries.

Possible current countries are those known within DCS world.

Parameter

  • #string Countries : Can take those country strings known within DCS world.

Return value

#SET_UNIT: self

SET_UNIT:FilterHasRadar(RadarTypes)

Builds a set of units having a radar of give types.

All the units having a radar of a given type will be included within the set.

Parameter

  • #table RadarTypes : The radar types.

Return value

#SET_UNIT: self

SET_UNIT:FilterHasSEAD()

Builds a set of SEADable units.

Return value

#SET_UNIT: self

SET_UNIT:FilterPrefixes(Prefixes)

Builds a set of units of defined unit prefixes.

All the units starting with the given prefixes will be included within the set.

Parameter

  • #string Prefixes : The prefix of which the unit name starts with.

Return value

#SET_UNIT: self

SET_UNIT:FilterStart()

Starts the filtering.

Return value

#SET_UNIT: self

SET_UNIT:FilterTypes(Types)

Builds a set of units of defined unit types.

Possible current types are those types known within DCS world.

Parameter

  • #string Types : Can take those type strings known within DCS world.

Return value

#SET_UNIT: self

SET_UNIT:FindInDatabase(Event)

Handles the Database to check on any event that Object exists in the Database.

This is required, because sometimes the DATABASE event gets called later than the SETBASE event or vise versa!

Parameter

Return values

  1. #string: The name of the UNIT

  2. #table: The UNIT

SET_UNIT:FindUnit(UnitName)

Finds a Unit based on the Unit Name.

Parameter

  • #string UnitName :

Return value

Wrapper.Unit#UNIT: The found Unit.

SET_UNIT:ForEachUnit(IteratorFunction, ...)

Iterate the SET_UNIT and call an interator function for each alive UNIT, providing the UNIT and optional parameters.

Parameters

  • #function IteratorFunction : The function that will be called when there is an alive UNIT in the SET_UNIT. The function needs to accept a UNIT parameter.

  • ... :

Return value

#SET_UNIT: self

SET_UNIT:ForEachUnitCompletelyInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_UNIT and call an iterator function for each alive UNIT presence completely in a Zone, providing the UNIT and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive UNIT in the SET_UNIT. The function needs to accept a UNIT parameter.

  • ... :

Return value

#SET_UNIT: self

SET_UNIT:ForEachUnitNotInZone(ZoneObject, IteratorFunction, ...)

Iterate the SET_UNIT and call an iterator function for each alive UNIT presence not in a Zone, providing the UNIT and optional parameters to the called function.

Parameters

  • Core.Zone#ZONE ZoneObject : The Zone to be tested for.

  • #function IteratorFunction : The function that will be called when there is an alive UNIT in the SET_UNIT. The function needs to accept a UNIT parameter.

  • ... :

Return value

#SET_UNIT: self

SET_UNIT:GetTypeNames(Delimiter)

Retrieve the type names of the Units in the SET, delimited by an optional delimiter.

Parameter

  • #string Delimiter : (optional) The delimiter, which is default a comma.

Return value

#string: The types of the Units delimited.

SET_UNIT:GetUnitThreatLevels()

Returns map of unit threat levels.

Return value

#table:

SET_UNIT:GetUnitTypes()

Returns map of unit types.

Return value

#map:

string,#number> A map of the unit types found. The key is the UnitTypeName and the value is the amount of unit types found.

SET_UNIT:GetUnitTypesText()

Returns a comma separated string of the unit types with a count in the Set.

Return value

#string: The unit types string

SET_UNIT:HasFriendlyUnits(FriendlyCoalition)

Returns if the Set has friendly ground units.

Parameter

  • FriendlyCoalition :

Return value

#number: The amount of ground targets in the Set.

SET_UNIT:HasGroundUnits()

Returns if the Set has ground targets.

Return value

#number: The amount of ground targets in the Set.

SET_UNIT:HasRadar(RadarType)

Returns if the Set has targets having a radar (of a given type).

Parameter

Return value

#number: The amount of radars in the Set with the given type

SET_UNIT:HasSEAD()

Returns if the Set has targets that can be SEADed.

Return value

#number: The amount of SEADable units in the Set

SET_UNIT:IsIncludeObject(MUnit)

Parameter

Return value

#SET_UNIT: self

SET_UNIT:New()

Creates a new SET_UNIT object, building a set of units belonging to a coalitions, categories, countries, types or with defined prefix names.

Return value

#SET_UNIT:

Usage:

-- Define a new SET_UNIT Object. This DBObject will contain a reference to all alive Units.
DBObject = SET_UNIT:New()
SET_UNIT:RemoveUnitsByName(RemoveUnitNames)

Remove UNIT(s) from SET_UNIT.

Parameter

Return value

self

Type map