LogoLogo
  • Codesign Documentation
  • Information
    • Discord Roles
    • FiveM Asset Escrow System
    • Authentication & Transfers
  • Coding Information
    • Register Key Mapping
    • Code Snippets
    • Self Debugging
  • Paid scripts
    • Arm Wrestling
      • Configs, Locales & SQL
    • Car HUD
      • Configs, Locales & SQL
    • CCTV Cameras
      • Configs, Locales & SQL
    • Darts
      • Configs, Locales & SQL
    • Dispatch
      • Configs, Locales & SQL
      • Resource Integration
    • Door Lock
      • Configs, Locales & SQL
    • Garage
      • Keys/Chat/Events/Exports
      • Optional Features
      • Configs, Locales & SQL
      • Resource Integration
    • Gun Range
      • Configs, Locales & SQL
    • Identity
      • Configs, Locales & SQL
    • Multicharacter
      • Configs, Locales & SQL
    • Player HUD
      • Configs, Locales & SQL
    • Props
      • Configs, Locales & SQL
    • Radar
      • Configs, Locales & SQL
    • Spawn Select
      • Configs, Locales & SQL
    • Terminal Hacker
      • Configs, Locales & SQL
    • Vehicle Control
      • Configs, Locales & SQL
    • VIP Shop
      • Configs, Locales & SQL
  • Free Scripts
    • Easytime
      • Keys/Chat/Events/Exports
      • Optional Features
      • Configs & Locales
    • Drawtext UI
    • Devtools
    • Keymaster - Minigame
    • Staff Support
    • Notifications
Powered by GitBook
LogoLogo

Codesign Software © All rights reserved

On this page
  • ESX Resources
  • QBCore Resources
  • Paid Resources

Was this helpful?

  1. Paid scripts
  2. Dispatch

Resource Integration

A guide to help customers understand where to replace default police notifications with cd_dispatch notifications.

PreviousConfigs, Locales & SQLNextDoor Lock

Last updated 12 months ago

Was this helpful?

ESX Resources

The links below will take you to resources from the official ESX GitHub. The highlighted line you will see is the default dispatch alert. All you need to do is replace that line with the code snippet we have provided below. Be sure to customise the in the event to suit your server's needs.

Step 1 - Find the default dispatch alert

Click any of the links below and find the highlighted line; this will be the default dispatch alert for that resource - .

Step 2 - Replace the default dispatch alert

Find the same line in that resource on your server and replace that line with the code snippet provided below.

Copy and paste this code snippet over the existing police alert.
local data = exports['cd_dispatch']:GetPlayerInfo()
TriggerServerEvent('cd_dispatch:AddNotification', {
    job_table = {'police', }, 
    coords = data.coords,
    title = '10-15 - Store Robbery',
    message = 'A '..data.sex..' robbing a store at '..data.street, 
    flash = 0,
    unique_id = data.unique_id,
    sound = 1,
    blip = {
        sprite = 431, 
        scale = 1.2, 
        colour = 3,
        flashes = false, 
        text = '911 - Store Robbery',
        time = 5,
        radius = 0,
    }
})

Step 3 - Customise the variables

QBCore Resources

Step 1 - Find the default dispatch alert

Step 2 - Replace the default dispatch alert

Find the same line in that resource on your server and replace that line with the code snippet provided below.

Copy and paste this code snippet over the existing police alert.
local data = exports['cd_dispatch']:GetPlayerInfo()
TriggerServerEvent('cd_dispatch:AddNotification', {
    job_table = {'police', }, 
    coords = data.coords,
    title = '10-15 - Store Robbery',
    message = 'A '..data.sex..' robbing a store at '..data.street, 
    flash = 0,
    unique_id = data.unique_id,
    sound = 1,
    blip = {
        sprite = 431, 
        scale = 1.2, 
        colour = 3,
        flashes = false, 
        text = '911 - Store Robbery',
        time = 5,
        radius = 0,
    }
})

Step 3 - Customise the variables

Paid Resources

Our goal is to get as many resources pre-configured to be compatible with our dispatch, or at the very least; we will try to add them here for you to do yourself.

You can find this event in [robberies_creator/integrations/sv_integrations.lua].

Fully replace the existing event with this new edited one.
RegisterNetEvent("robberies_creator:alertedPolice", function(coords, message)
    TriggerClientEvent('cd_dispatch:AddNotification', -1, {
        job_table = {'police', },
        coords = coords,
        title = '10-15 - Robbery',
        message = message,
        flash = 0,
        unique_id = tostring(math.random(0000000,9999999)),
        sound = 1,
        blip = {
            sprite = 431,
            scale = 1.2,
            colour = 3,
            flashes = false,
            text = '911 - Robbery',
            time = 5,
            radius = 0,
        }
    })
  end)

You can find this event in [drugs_creator/integrations/sv_integrations.lua].

Fully replace the existing event with this new edited one.
RegisterNetEvent("drugs_creator:alertedPolice", function(coords, message)
    TriggerClientEvent('cd_dispatch:AddNotification', -1, {
        job_table = {'police', },
        coords = coords,
        title = '10-15 - Drugs',
        message = message,
        flash = 0,
        unique_id = tostring(math.random(0000000,9999999)),
        sound = 1,
        blip = {
            sprite = 431,
            scale = 1.2,
            colour = 3,
            flashes = false,
            text = '911 - Drugs',
            time = 5,
            radius = 0,
        }
    })
  end)

Be sure to customise the in the event to suit your server's needs.

The links below will take you to resources from the official QBCore GitHub. The highlighted line you will see is the default dispatch alert. All you need to do is replace that line with the code snippet we have provided below. Be sure to customise the in the event to suit your server's needs.

Click any of the links below and find the highlighted line; this will be the default dispatch alert for that resource - .

Be sure to customise the in the event to suit your server's needs.

Be sure to customise the in the event to suit your server's needs.

Be sure to customise the in the event to suit your server's needs.

variables
EXAMPLE
esx_ambulancejob
variables
variables
EXAMPLE
qb-drugs
qb-police (anpr)
qb-ambulancejob (1)
qb-ambulancejob (2)
qb-ambulancejob (3)
qb-bakrobbery (fleeca)
qb-bankrobbery (pacific 1)
qb-bankrobbery (pacific 2)
qb-bankrobbery (paleto)
qb-storerobbery (1)
qb-storerobbery (2)
qb-storerobbery (3)
qb-truckrobbery
qb-jewelery
qb-houserobbery
variables
variables
variables
Before and after example from a random resource.
Before and after example from a random resource.