ACE3/addons/laser_selfdesignate/functions/fnc_laserHudDesignateOff.sqf

30 lines
726 B
Plaintext
Raw Normal View History

/*
* Author: jaynus
* Turns off passed laser self designation.
*
* Argument:
* 0: Shooter, player shooting the laser
* 1: LaserUUID, the UUID of the laser returned by EFUNC(laser,laserOn)
* 2: Local laser target, unused.
*
* Return Value:
* True <BOOL>
*/
#include "script_component.hpp"
if( (count _this) > 2) then {
params ["", "_laserUuid"];
[_laserUuid] call EFUNC(laser,laserOff);
2015-04-12 18:14:12 +00:00
// @TODO: Nou gets to field all tickets about missing lasers.
//deleteVehicle _localLaserTarget;
};
2015-04-07 19:11:28 +00:00
GVAR(active) = false;
if(!isNil QGVAR(selfDesignateHandle)) then {
[GVAR(selfDesignateHandle)] call CBA_fnc_removePerFrameHandler;
GVAR(selfDesignateHandle) = nil;
};
true