possible redutzu-mdt support.
I looked at the docs, I dont have this to test though
This commit is contained in:
1 parent
6bdee6ad91
commit
6ed438a609
2 files changed
+26
No files matched your search
@@ -0,0 +1,14 @@
|
||||
if GetResourceState('redutzu-mdt') ~= 'started' then return end
|
||||
Dispatch = Dispatch or {}
|
||||
|
||||
Dispatch.SendAlert = function(data)
|
||||
local streetName, _ = Utility.GetStreetNameAtCoords(data.coords)
|
||||
local alertData = {
|
||||
code = data.code or '10-80',
|
||||
message = data.message or "Dispatch Alert",
|
||||
street = streetName,
|
||||
time = data.time or 10000,
|
||||
coords = data.coords,
|
||||
}
|
||||
TriggerServerEvent("community_bridge:server:dispatch:sendAlert", alertData)
|
||||
end
|
||||
@@ -0,0 +1,12 @@
|
||||
if GetResourceState('redutzu-mdt') ~= 'started' then return end
|
||||
Dispatch = Dispatch or {}
|
||||
|
||||
RegisterNetEvent("community_bridge:server:dispatch:sendAlert", function(data)
|
||||
TriggerEvent('redutzu-mdt:server:addDispatchToMDT', {
|
||||
code = data.code,
|
||||
title = data.message,
|
||||
street = data.street,
|
||||
duration = data.time,
|
||||
coords = data.coords
|
||||
})
|
||||
end)
|
||||
Reference in new issue
Block a user