2015-09-29 20:24:25 +00:00
|
|
|
/*
|
|
|
|
* Author: Garth 'L-H' de Wet, commy2
|
|
|
|
* Handles the player dying.
|
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* 0: Unit <OBJECT>
|
|
|
|
*
|
|
|
|
* Return Value:
|
|
|
|
* Function is handled? <BOOL>
|
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
2015-09-29 20:01:40 +00:00
|
|
|
#include "script_component.hpp"
|
2015-09-29 20:24:25 +00:00
|
|
|
|
|
|
|
params ["_unit"];
|
|
|
|
|
|
|
|
if (_unit != ACE_player) exitWith {true};
|
|
|
|
|
|
|
|
GVAR(PostProcessEyes) ppEffectEnable false;
|
|
|
|
|
|
|
|
SETGLASSES(_unit,GLASSESDEFAULT);
|
|
|
|
|
|
|
|
call FUNC(removeGlassesEffect);
|
|
|
|
|
|
|
|
GVAR(EffectsActive) = false;
|
|
|
|
|
|
|
|
_unit setVariable ["ACE_EyesDamaged", false];
|
|
|
|
|
2015-11-18 05:44:50 +00:00
|
|
|
if (GVAR(DustHandler) != -1) then {
|
|
|
|
[GVAR(DustHandler)] call CBA_fnc_removePerFrameHandler;
|
|
|
|
};
|
2015-09-29 20:24:25 +00:00
|
|
|
GVAR(DustHandler) = -1;
|
|
|
|
|
|
|
|
true
|