Jump to content

Tools.BuildNewMarkerPointTable: Difference between revisions

From CMM Wiki
tools.BuildNewMarkerPointTable – created via PowerShell script (2025-11-11T21:12:51Z)
Tag: Recreated
 
m tools.BuildNewMarkerPointTable – created via PowerShell script (2026-06-24T22:27:29Z)
 
Line 1: Line 1:
{{Template:FunctionInfo|fName=          tools.BuildNewMarkerPointTable|fDescription=  Creates a table of marker points from a specified group, with options to define position mode and skip the first waypoint. The function uses internal waypoint processing to derive positions either as world coordinates, relative to the first unit, or via heading and distance. Returns a table of waypoints or nil if invalid input.|parentFile=    cmm.tools.lua|syntax=        CMM.tools.BuildNewMarkerPointTable(GroupName <string>, Mode <number>, SkipFirst <boolean>)|return=        table or nil|returnDesc=    Returns a table containing the processed waypoints or nil if group not found or no waypoints exist.|example=        CMM.tools.BuildNewMarkerPointTable("DebrisArea",1,false)|exampleDesc=    Generates a table of waypoints from the group "DebrisArea" using relative positioning to the first unit, without skipping the first point.|related=        |note=          |envType= CMM|par1=        string GroupName|reqType1=    string|reqName1=    GroupName|desc1=      Name of the group in the mission editor containing waypoints to extract. Must be valid and defined in the mission.|par2=        number Mode|reqType2=    number|reqName2=    Mode|desc2=      Mode for position derivation: 0 = world positions, 1 = relative to first unit (default), 2 = heading and distance from first unit. Defaults to 1 if not specified.|par3=        boolean SkipFirst|reqType3=    boolean|reqName3=    SkipFirst|desc3=      If true, the first waypoint in the group is skipped. Defaults to false.}}
{{Template:FunctionInfo|fName=          tools.BuildNewMarkerPointTable|fDescription=  Creates a table of marker points from a specified group, with options to define position mode and skip the first waypoint. The function uses internal waypoint processing to derive positions either as world coordinates, relative to the first unit, or via heading and distance. Returns a table of waypoints or nil if invalid input.|parentFile=    cmm.tools.lua|syntax=        CMM.tools.BuildNewMarkerPointTable(GroupName <string>, Mode <number>, SkipFirst <boolean>)|return=        table or nil|returnDesc=    Returns a table containing the processed waypoints or nil if group not found or no waypoints exist.|example=        CMM.tools.BuildNewMarkerPointTable("DebrisArea",1,false)|exampleDesc=    Generates a table of waypoints from the group "DebrisArea" using relative positioning to the first unit, without skipping the first point.|related=        |note=          |envType= CMM|par1=        string GroupName|reqType1=    string|reqName1=    GroupName|desc1=      Name of the group in the mission editor containing waypoints to extract. Must be valid and defined in the mission.|par2=        number or nil Mode|optType2=    number or nil|optName2=    Mode|desc2=      Mode for position derivation: 0 = world positions, 1 = relative to first unit (default), 2 = heading and distance from first unit. Defaults to 1 if not specified.|par3=        boolean or nil SkipFirst|optType3=    boolean or nil|optName3=    SkipFirst|desc3=      If true, the first waypoint in the group is skipped. Defaults to false.|par4=        boolean or nil WriteToFile|optType4=    boolean or nil|optName4=    WriteToFile|desc4=      If true, will write the CMM.DEV}}

Latest revision as of 12:27, 24 June 2026

Return to CMM Command Reference
Environment: Mission Scripting
Function: tools.BuildNewMarkerPointTable
Function Description: Creates a table of marker points from a specified group, with options to define position mode and skip the first waypoint. The function uses internal waypoint processing to derive positions either as world coordinates, relative to the first unit, or via heading and distance. Returns a table of waypoints or nil if invalid input.
File Location: cmm.tools.lua
Syntax: CMM.tools.BuildNewMarkerPointTable( string GroupName , number or nil Mode , boolean or nil SkipFirst , boolean or nil WriteToFile )
Return Value: table or nil
Parameters: Name Description
GroupNameName of the group in the mission editor containing waypoints to extract. Must be valid and defined in the mission.
ModeMode for position derivation: 0 = world positions, 1 = relative to first unit (default), 2 = heading and distance from first unit. Defaults to 1 if not specified.
SkipFirstIf true, the first waypoint in the group is skipped. Defaults to false.
WriteToFileIf true, will write the CMM.DEV
Example: CMM.tools.BuildNewMarkerPointTable("DebrisArea",1,false)
Example Description: Generates a table of waypoints from the group "DebrisArea" using relative positioning to the first unit, without skipping the first point.
Related Functions:
Notes: