#include "..\script_component.hpp" /* * Author: IDSolutions * Assigns an AI unit to a task as a shooter * * Arguments: * 0: The AI unit * 1: ID of the task * * Return Value: * None * * Example: * [this, "task_name"] spawn forge_client_task_fnc_makeShooter; * * Public: Yes */ params [["_entity", objNull, [objNull, grpNull]], ["_taskID", "", [""]]]; if (isNull _entity) exitWith { diag_log "ERROR: Attempt to create entity from null object"; }; if (_taskID == "") exitWith { diag_log "ERROR: No task ID provided for entity"; }; diag_log format ["[FORGE] Make Shooter: %1", _this]; SETVAR(_entity,assignedTask,_taskID); GVAR(allShooters) pushBackUnique _entity;