diff --git a/client/eventhandlers.lua b/client/eventhandlers.lua index 3757f729..a2aab14c 100644 --- a/client/eventhandlers.lua +++ b/client/eventhandlers.lua @@ -80,6 +80,13 @@ AddEventHandler('CEventShockingCarAlarm', function(_, ped) end) end) +AddEventHandler('CEventExplosionHeard', function(witnesses, ped) + if witnesses and not isPedAWitness(witnesses, ped) then return end + WaitTimer('Explosion', function() + exports['ps-dispatch']:Explosion() + end) +end) + AddEventHandler('gameEventTriggered', function(name, args) if name ~= 'CEventNetworkEntityDamage' then return end local victim = args[1] diff --git a/shared/config.lua b/shared/config.lua index dd99f806..1ec2523a 100644 --- a/shared/config.lua +++ b/shared/config.lua @@ -19,7 +19,8 @@ Config.DefaultAlerts = { Shooting = true, Autotheft = true, Melee = true, - PlayerDowned = true + PlayerDowned = true, + Explosion = true } Config.MinOffset = 1 @@ -401,14 +402,14 @@ Config.Blips = { flash = false }, ['explosion'] = { - radius = 0, + radius = 75.0, sprite = 436, color = 1, scale = 1.5, length = 2, sound = 'Lose_1st', sound2 = 'GTAO_FM_Events_Soundset', - offset = false, + offset = true, flash = false } }