mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
742626ff1a
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
39 lines
732 B
Plaintext
39 lines
732 B
Plaintext
#include "..\script_component.hpp"
|
|
/*
|
|
* Author: Garth 'L-H' de Wet, commy2
|
|
* Handles the player dying.
|
|
*
|
|
* Arguments:
|
|
* 0: Unit <OBJECT>
|
|
*
|
|
* Return Value:
|
|
* Function is handled? <BOOL>
|
|
*
|
|
* Example:
|
|
* [bob] call ace_goggles_fnc_handleKilled
|
|
*
|
|
* Public: No
|
|
*/
|
|
|
|
params ["_unit"];
|
|
|
|
if (_unit != ACE_player) exitWith {true};
|
|
if (GVAR(effects) == 0) exitWith {true};
|
|
|
|
call FUNC(removeGlassesEffect);
|
|
|
|
if (GVAR(effects) in [2, 3]) then {
|
|
GVAR(PostProcessEyes) ppEffectEnable false;
|
|
|
|
SETGLASSES(_unit,GLASSESDEFAULT);
|
|
|
|
_unit setVariable ["ACE_EyesDamaged", false];
|
|
|
|
if (GVAR(DustHandler) != -1) then {
|
|
[GVAR(DustHandler)] call CBA_fnc_removePerFrameHandler;
|
|
};
|
|
GVAR(DustHandler) = -1;
|
|
};
|
|
|
|
true
|