From fbcfc24e2a0f43a2ce92a4766782df97540aa684 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 7 Oct 2024 12:55:40 -0500 Subject: [PATCH] Hearing - Ignore explosions with no `hit` (#10369) --- addons/hearing/functions/fnc_explosion.sqf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/hearing/functions/fnc_explosion.sqf b/addons/hearing/functions/fnc_explosion.sqf index b5a6f14a69c..f0a1ee6aab1 100644 --- a/addons/hearing/functions/fnc_explosion.sqf +++ b/addons/hearing/functions/fnc_explosion.sqf @@ -30,11 +30,13 @@ if (_distance > 100) exitWith { }; private _ammoConfig = configOf _projectile; +private _hit = getNumber (_ammoConfig >> "hit"); +if (_hit < 0.5) exitWith { TRACE_1("ignore smoke/flare",_hit) }; private _explosive = getNumber (_ammoConfig >> "explosive"); private _vehAttenuation = [GVAR(playerVehAttenuation), 1] select (isNull objectParent ACE_player || {isTurnedOut ACE_player}); -TRACE_5("",typeOf _projectile,_distance,_explosive,_audibleFire,_vehAttenuation); +TRACE_4("",typeOf _projectile,_distance,_explosive,_vehAttenuation); (if (isArray (_ammoConfig >> "soundHit1")) then { getArray (_ammoConfig >> "soundHit1")