Custom Dispatch Calls
How do I ensure that I receive notifications about robberies and other custom calls in the dispatch? It is necessary to make changes to the exports that scripts have or that have been changed to cust
How to create complete new call:
local function PlaneHeist()
local function ArtGalleryHeist()
local function TrainHeist()local function MyNewDispatchCall()
local plyData = QBCore.Functions.GetPlayerData() -- or for ESX = local plyData = ESX.GetPlayerData()
local ped = PlayerPedId()
local coords = GetEntityCoords(ped)
local substreet = GetStreetNameAtCoord(coords.x, coords.y, coords.z)
local streetname = GetStreetNameFromHashKey(substreet)
local title = _L['your_tittle_name'] -- Go to locale/loc.lua and add ['your_tittle_name'] = 'Code|Tittle',
local text = "On the " .. streetname .. " has been a " .. gender .. '.'
for k, v in pairs(Config.Jobs) do
local job = v
TriggerServerEvent('akre-dispatch:server:NewDispatch', job, title, text, coords)
end
end
exports('MyNewDispatchCall', MyNewDispatchCall)
```Examples how to add calls to dispatch
QB-Jewelery




Last updated