Kartik Scripts

Emergency Buttons (10-13A / 10-13B)

Two panic buttons for on-duty police, EMS and fire. Press one and every on-duty emergency unit gets a flashing blip on your position, an alert sound and a notification. They work whether you are standing, downed or dead.


๐Ÿ”˜ The two codes

CodeMeaningWhat responders get
10-13AUnit needs urgent helpRed flashing blip, a loud repeating alarm, a red notification
10-13BUnit needs help, not urgentOrange flashing blip, a single tone, an orange notification

The notification shows the unit's name, their department and the street they are on, for example John Smith (LSPD) at Alta St.

The alert is always placed where the unit really is. The person who pressed the button does not get the alert themselves, only a "sent" confirmation.


๐ŸŽฎ How to send one

Way10-13A10-13B
Radial menuEmergency โ†’ 10-13A Urgent backupEmergency โ†’ 10-13B Non-urgent backup
Chat command/1013a/1013b
Keybindunboundunbound

The Emergency radial sub-menu only shows for on-duty police, EMS and fire. Players can bind both buttons in GTA Settings โ†’ Key Bindings โ†’ FiveM (look for Emergency: 10-13A and Emergency: 10-13B).

While downed or dead, use the command or a keybind. Some radial menus do not open while you are down.


๐Ÿ‘ฎ Who can use it and who receives it

The same players send and receive:

  • Police: every job in Config.PoliceJobs
  • EMS: every EMS job you set up in /emsadmin โ†’ Jobs
  • Fire: every job in Config.Panic.fireJobs (fire by default)
  • Anything else: every job in Config.Panic.extraJobs

They must be on duty, unless Config.RequireDuty = false. Each player can send one alert every 30 seconds (Config.Panic.cooldown).


๐Ÿ“ก Dispatch scripts

With Config.Panic.external = true, the alert is also sent to your dispatch script with the code 10-13A or 10-13B and every responder job listed above. It works with the same dispatch scripts as distress calls: kartik-mdt, lb-tablet, ps-dispatch, cd_dispatch, qs-dispatch, core_dispatch, rcore_dispatch and tk_dispatch. In kartik-mdt a 10-13A shows as a panic call.

Set it to false if you only want the built-in blip, sound and notification.


โš™๏ธ Configuration

In shared/config/dispatch.lua:

Config.Panic = {
    enabled = true,
    fireJobs = { 'fire' },
    extraJobs = {},
    cooldown = 30,
    radial = true,
    external = true,
    commands = { urgent = '1013a', routine = '1013b' },
    keybinds = { urgent = '', routine = '' },
    urgent = {
        code = '10-13A',
        blip = { sprite = 161, color = 1, scale = 1.4, duration = 180 },
        sound = { name = 'Beep_Red', set = 'DLC_HEIST_HACKING_SNAKE_SOUNDS', repeats = 4 },
    },
    routine = {
        code = '10-13B',
        blip = { sprite = 161, color = 47, scale = 1.1, duration = 180 },
        sound = { name = 'TIMER_STOP', set = 'HUD_MINI_GAME_SOUNDSET', repeats = 1 },
    },
}
Option
enabledTurn the whole feature on or off
fireJobsYour fire department job names
extraJobsAny other job names that should send and receive the alerts (for example a ranger or DOJ job)
cooldownSeconds between alerts from the same player
radialShow the Emergency sub-menu in the radial menu
externalAlso send the alert to your dispatch script
commandsChat command names. Set one to false to remove it
keybindsDefault keys, for example 'F9'. Leave empty so players bind their own
codeThe code shown everywhere, change it to match your server's radio codes
blipBlip sprite, color, scale and how long it stays in seconds (duration)
soundA GTA frontend sound name and set, and how many times it plays (repeats)

๐Ÿ”Œ For developers

Every alert also fires a server event you can listen to, for example to log it to Discord or your own CAD:

AddEventHandler('kartik-ambulancejob:server:panic', function(source, data)
    -- data.kind   'urgent' or 'routine'
    -- data.code   '10-13A' or '10-13B'
    -- data.job    the sender's job name
    -- data.coords where the sender is
    print(('%s sent %s'):format(GetPlayerName(source), data.code))
end)

The event only fires on the server, after the sender's job, duty and cooldown have been checked. See Events & State Bags.

On this page