Seem to be having another issue with custom alerts now.
I'm trying to call it via a script once a ped is alerted to send a custom alert as a test but nothing appears.
Citizen.CreateThread(function(house)
while true do
Citizen.Wait(6)
if GetPlayerCurrentStealthNoise(PlayerId()) > 5 then
if CanPedHearPlayer(PlayerId(), peds[1]) then
local data = {displayCode = '211', description = 'Robbery', isImportant = 0, recipientList = {'police'}, length = '10000', infoM = 'fa-info-circle', info = 'Vangelico Jewelry Store'}
local dispatchData = {dispatchData = data, caller = 'Alarm', coords = vector3(-633.9, -241.7, 38.1)}
TriggerEvent('wf-alerts:svNotify', dispatchData)
ClearPedTasks(peds[1])
Citizen.Wait(5)
PlayPain(peds[1], 7, 0)
if HasPedGotWeapon(peds[1], GetHashKey("WEAPON_PISTOL"), false) then
SetCurrentPedWeapon(peds[1], GetHashKey("WEAPON_PISTOL"), true)
Citizen.Wait(5)
TaskShootAtEntity(peds[1], PlayerPedId(), -1, 2685983626)
Citizen.Wait(7000)
end
end
end
end
end)
As you can see it's being called once the noise threshold is above 5 but nothing seems to come through, with no errors either.
Hi, sorry to bug you again haha.
Seem to be having another issue with custom alerts now.
I'm trying to call it via a script once a ped is alerted to send a custom alert as a test but nothing appears.
As you can see it's being called once the noise threshold is above 5 but nothing seems to come through, with no errors either.
Thanks