dispatches updated

This commit is contained in:
MrNewb committed 2025-02-05 20:43:44 -05:00
1 parent 8900822234
commit b829edb835
16 files changed
+170 -175

No files matched your search

@@ -1,21 +0,0 @@
if GetResourceState('linden_outlawalert') ~= 'started' then return end
Dispatch = {}
Dispatch.SendAlert = function(data)
local formattedData = {
displayCode = data.code or '10-80',
description = data.message,
isImportant = data.priority or 0,
recipientList = data.job,
length = '10000',
infoM = data.icon or 'fas fa-question',
info = data.message
}
local dispatchData = {
dispatchData = formattedData,
caller = 'Anonymous',
coords = GetEntityCoords(cache.ped)
}
TriggerServerEvent('wf-alerts:svNotify', dispatchData)
end
@@ -0,0 +1,18 @@
if GetResourceState('linden_outlawalert') ~= 'started' then return end
Dispatch = Dispatch or {}
Dispatch.SendAlert = function(data)
TriggerServerEvent('wf-alerts:svNotify', {
dispatchData = {
displayCode = data.code or '211',
description = data.message or "Alert",
isImportant = 0,
recipientList = data.jobs or {'police'},
length = (data.alertTime * 1000) or '10000',
infoM = data.icon or 'fas fa-question',
info = data.message or "Alert"
},
caller = 'Anonymous',
coords = data.coords or GetEntityCoords(cache.ped)
})
end
@@ -0,0 +1,2 @@
if GetResourceState('linden_outlawalert') ~= 'started' then return end
Dispatch = Dispatch or {}