Files
MissionTemplate/framework/util/fn_addPlayerInfoToArray.sqf

14 lines
392 B
Plaintext

params [["_playerObj", objNull], ["_arrayToModify", [], [[]]]];
if (isNull _playerObj) exitWith {_arrayToModify};
{
_arrayToModify = [_arrayToModify, _x#0, _x#1] call BIS_fnc_setToPairs;
} forEach [
["playerName", name _playerObj],
["playerUID", getPlayerUID _playerObj],
["playerGroup", groupId (group _playerObj)],
["playerNetID", [_playerObj] call BIS_fnc_netId]
];
_arrayToModify;