Jump to content

InitialisePOI

From CMM Wiki
Revision as of 19:02, 31 December 2025 by Ozdeadmeat (talk | contribs) (initialisePOI – created via PowerShell script (2026-01-01T06:02:57Z))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Return to CMM Command Reference
Environment: Mission Scripting
Function: initialisePOI
Function Description: Populates the global CMM.ACTIVEPOI list from a set of GRID identifiers. The function first expands the supplied GRIDS (string or table) into a list of POIs via CMM.MakePOIList. If the first argument is the string "ALL" (case‑insensitive) the function activates every POI in the supplied grids. Each activated POI receives a unique marker ID, a visual circle on the F10 map, and is stored in CMM.ACTIVEPOI. The function does not return a value; it updates global state.
File Location: cmm.DCSFunctions.lua
Syntax: CMM.initialisePOI( table or string GRIDS , number LargeFlat , number SmallFlat , number Large , number Small , boolean or nil Visible )
Return Value: table or nil
Parameters: Name Description
GRIDSA list of GRID identifiers (e.g. { "DK47", "DK56" }) or a single GRID string or a Zone name string
LargeFlatDesired count of LargeFlat – number of large flat POIs (radius > 200 & isflat == true)
SmallFlatDesired count of SmallFlat – number of small flat POIs (radius == 200 & isflat == true)
LargeDesired count of Large – number of large non‑flat POIs (radius > 200 & isflat == false)
SmallDesired count of Small – number of small non‑flat POIs (radius == 200 & isflat == false).
VisibleTo show the PIO on the F10 Map --TODO : This isnt implemented yet
Example: CMM.initialisePOI({"DK47","DK56","DK57"},3,0,0,17)
Example Description: Activates 3 large flat POIs and 17 small non‑flat POIs from the grids DK47, DK56, DK57.
Related Functions:
Notes: