Jump to content

DrawCity

From CMM Wiki
Revision as of 12:26, 24 June 2026 by Ozdeadmeat (talk | contribs) (DrawCity – created via PowerShell script (2026-06-24T22:26:53Z))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Return to CMM Command Reference
Environment: Mission Scripting
Function: DrawCity
Function Description: Draws a city on the map using a predefined set of points from CMM.CITY. It allows customization of coalition ownership and marker colors. Returns the marker ID of the created city marker.
File Location: cmm.drawFunctions.lua
Syntax: CMM.DrawCity( string name , number coal , table colourfill , table colourline )
Return Value: number or nil
Parameters: Name Description
nameName of the city to draw. Must correspond to a key in the CMM.CITY table.
coalCoalition number for the marker (0 = neutral, 1 = red, 2 = blue). If invalid, defaults to -1 (all).
colourfillRGBA color table for the marker fill
colourlineRGBA color table for the marker outline
Example: CMM.DrawCity("Krymsk", 2, {0,0,0.7,0.5}, {0,0,0,1})
Example Description: Draws a city marker for "Krymsk" with blue fill and black outline, owned by the blue coalition.
Related Functions:
Notes: