Skip to content

Commit

Permalink
Hearing - Ignore explosions with no hit (acemod#10369)
Browse files Browse the repository at this point in the history
  • Loading branch information
PabstMirror authored Oct 7, 2024
1 parent 9f2e40c commit fbcfc24
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion addons/hearing/functions/fnc_explosion.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -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")
Expand Down

0 comments on commit fbcfc24

Please sign in to comment.