Jump to content

FindNearestAirbase

From CMM Wiki
Revision as of 19:02, 31 December 2025 by Ozdeadmeat (talk | contribs) (FindNearestAirbase – created via PowerShell script (2026-01-01T06:02:35Z))
Return to CMM Command Reference
Environment: Mission Scripting
Function: FindNearestAirbase
Function Description:
File Location: cmm.AirBaseFunctions.lua
Syntax: CMM.FindNearestAirbase( table vec3 , number or nil coal )
Return Value: table or nil,table
Parameters: Name Description
vec3A 3‑D position vector ({x, y, z}) used as the reference point.
coalOptional coalition number (1 = Red, 2 = Blue). Defaults to –1 meaning “any”.
Example: CMM.FindNearestAirbase({x=0, y=0, z=1000}, 1)
Example Description: Finds the closest airbase to the given point within the specified coalition (or any if omitted) and logs the result.
Related Functions:
Notes: