Jump to content

SetInvisible

From CMM Wiki
Revision as of 10:12, 11 November 2025 by Ozdeadmeat (talk | contribs) (SetInvisible – created via PowerShell script (2025-11-11T21:11:58Z))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Return to CMM Command Reference
Environment: Mission Scripting
Function: SetInvisible
Function Description: Sets the visibility state of a Group AI Controller. If Invisible is omitted it defaults to true. The function verifies that the supplied controller is valid via CMM.IsController; if not, it logs an error and exits.
File Location: cmm.DCSFunctions.lua
Syntax: CMM.SetInvisible( boolean Ctrllr , boolean or nil Invisible )
Return Value:
Parameters: Name Description
CtrllrThe Group AI Controller to modify (must pass IsController check).
InvisibleDesired visibility state; defaults to true if omitted.
Example: local ctrl = unit:getGroup():getController(); CMM.SetInvisible(ctrl, false) -- make the group visible
Example Description: Demonstrates retrieving a controller from a unit and setting its visibility to visible (i.e., false).
Related Functions:
Notes: