Difference between revisions of "DCS singleton coalition"

From DCS World Wiki - Hoggitworld.com
m (1 revision imported)
 
Line 26: Line 26:
 
  }
 
  }
  
|notes=  
+
|notes= While not found within the coalition.side table there is a value of -1 used to represent "all" that is present in some scripting functionality. The best example is found within [[DCS_func_markupToAll|markupToAll]].
  
  
 
}}
 
}}

Revision as of 00:20, 15 March 2022


Singleton: coalition Added with: 1.2.0
Description: The coalition singleton contains functions that gets information on the all of the units within the mission. It also has two of the most powerful functions that are capable of spawning groups and static objects into the mission.
Functions: addGroup, addStaticObject, getGroups, getStaticObjects, getAirbases. getPlayers, getServiceProviders, addRefPoint, getRefPoints, getMainRefPoint, getCountryCoalition
Enumerators and Other Data: Side enumerator defines the teams present in the sim.
coalition.side = {
   NEUTRAL = 0
   RED = 1
   BLUE = 2
}

Service enumerator defines the types of services available via radio communications that are coalition wide.

coalition.service = {
  ATC = 0
  AWACS = 1
  TANKER = 2
  FAC = 3
}
Notes: While not found within the coalition.side table there is a value of -1 used to represent "all" that is present in some scripting functionality. The best example is found within markupToAll.