Redoing this

This commit is contained in:
Salluci 2021-08-09 14:46:24 -03:00
parent e6a0772adb
commit 80ff709676
3 changed files with 9 additions and 0 deletions

View File

@ -63,6 +63,10 @@ GVAR(bloodTickCounter) = 0;
[true, _unit] call EFUNC(common,setVolume); [true, _unit] call EFUNC(common,setVolume);
[QUOTE(ADDON), 1, false] call EFUNC(common,setHearingCapability); [QUOTE(ADDON), 1, false] call EFUNC(common,setHearingCapability);
//Force stop heart beat effect
GVAR(heartBeatEffectRunning) = false;
}] call CBA_fnc_addEventHandler; }] call CBA_fnc_addEventHandler;
// Update effects to match new unit's current status (this also handles respawn) // Update effects to match new unit's current status (this also handles respawn)

View File

@ -17,6 +17,10 @@
private _heartRate = GET_HEART_RATE(ACE_player); private _heartRate = GET_HEART_RATE(ACE_player);
if (!GVAR(heartBeatEffectRunning)) exitWith {
TRACE_1("Ending heart beat effect - force stopped",_heartRate);
};
if (_heartRate == 0) exitWith { if (_heartRate == 0) exitWith {
TRACE_1("Ending heart beat effect - zero",_heartRate); TRACE_1("Ending heart beat effect - zero",_heartRate);
GVAR(heartBeatEffectRunning) = false; GVAR(heartBeatEffectRunning) = false;

View File

@ -23,6 +23,7 @@ if (EGVAR(common,OldIsCamera) || {!alive ACE_player}) exitWith {
[false] call FUNC(effectBloodVolume); [false] call FUNC(effectBloodVolume);
[false] call FUNC(effectBloodVolumeIcon); [false] call FUNC(effectBloodVolumeIcon);
[false] call FUNC(effectBleeding); [false] call FUNC(effectBleeding);
GVAR(heartBeatEffectRunning) = false;
}; };
BEGIN_COUNTER(handleEffects); BEGIN_COUNTER(handleEffects);