Page MenuHomeFeedback Tracker

[Feature Request] SQF command to get unit ID in the group
Closed, ResolvedPublic

Description

There is a hack to get it (ACE uses a very similar), but its quite bad on performance, very hacky and may cause problems when not done on unit init (and the id can change with join command)

Details

Severity
None
Resolution
Fixed
Reproducibility
N/A
Operating System
Windows 10 x64
Category
Scripting
Additional Information
params [["_unit", objNull, [objNull]]];

private _vehicleVarName = vehicleVarName _unit;

_unit setVehicleVarName "";

private _unitString = str _unit;

_unit setVehicleVarName _vehicleVarName;

private _return = _unitString select [(_unitString find ":") + 1];

parseNumber _return;

Event Timeline

dedmen claimed this task.Jan 18 2023, 12:43 PM
dedmen changed the task status from New to Feedback.
dedmen set Ref Ticket to AIII-55505.

groupId alternative syntax thanks to @dedmen!

works fine. can be closed

LouMontana closed this task as Resolved.Mar 6 2023, 11:13 AM
LouMontana changed Resolution from Open to Fixed.