T3 // Public Safety

coe_dispatch

Emergency Dispatch

Calls and alerts for on-duty police and EMS, with priority and blips

HEADLESS SERVICE (NO UI)
DEPENDS ON coe_corecoe_loggingcoe_businesses
coe_dispatch 4 exports · 4 commands

Runs without a NUI: nothing is rendered on the client and the resource stays idle until events arrive.

01 // OVERVIEW

Call dispatch for police and EMS on top of coe_businesses: whoever is on duty in a business of the call category receives it. Each code (robbery, shots_fired, person_down...) sets category, priority and label; nearby identical reports merge, and the call becomes a blip with an alert. Citizens ask for help with /chamado; crews use /chamados, /atender and /encerrar.

On FiveM Enhanced

No parallel player list, with radius and time deduplication: ten reports of the same shootout become one call.

02 // FEATURES

What the module delivers

01

Prioritized Codes

Category, priority and label per code.

02

Deduplication

Nearby reports merged into one call.

03

Blips & Route

Blip flashes on priority 1, route on accept.

04

For Any Resource

Police, EMS, heists and races open calls.

ARCHITECTURAL LAYERS // CLEAN ARCHITECTURE

4-Layer Isolation with 0.00 ms Idle

Every COE Framework script strictly follows the principle of separation of concerns. Interact with the 3D stack below:

L4
Headless Operation (No UI)
Zero DOM · CoE UI Delegation
Headless
L3
Application & Server
Atomic locks · Rate limiting
Auth Server
L2
Platform & HAL
Core.Platform · Mock natives
Gen9 HAL
L1
Domain & ACID Database
Prepared SQL · MariaDB pool
ACID Pool
LAYER 04 // HEADLESS SERVICE

Headless Service (No Dedicated NUI)

Operates strictly within layers L1–L3 (domain, HAL, and server-authoritative application logic). Visual interactions and management flows are delegated to centralized ecosystem apps (coe_ui / coe_tablet), guaranteeing 0.00 ms idle client overhead in FiveM DX12.

Zero CEF graphic overhead: no background web pages or NUI bridges loaded
Typed public contracts (types.lua) consumed directly by external resources and UIs
Strict adherence to the Server-Authoritative model with zero direct DOM manipulation
ADMIN POWERS // OPERATION & MANAGEMENT

What this script delivers to Server Owners

Manage your city without relying on developers. Runtime parameters, auditing, and ACE-protected commands:

🛡️
ACE Permissions
Administrative operations strictly protected by coe.staff and coe.admin principals.
IsPlayerAceAllowed(src, "coe.admin")
📊
Ledger Auditing
Relevant actions write audit records to the database through coe_audit.
exports.coe_audit:Record(severity, category, event, context)
⚡
0.00ms Idle Telemetry
Event-driven thread dispatch that stays dormant until network events fire.
Clean Architecture & HAL
03 // EXPORTS

Public API 4

Typed contracts to call from other resources. Full types live in types.lua and in the docs reference.

exports['coe_dispatch']:Accept(source, id) → any

Export server Accept (server/main.lua).

ParameterType
sourceany
idany
LUA
local result = exports['coe_dispatch']:Accept(source, id)
exports['coe_dispatch']:Active(source) → any

Export server Active (server/main.lua).

ParameterType
sourceany
LUA
local result = exports['coe_dispatch']:Active(source)
exports['coe_dispatch']:Alert(code, x, y, z) → any

Submits an automatic alert from another resource: Alert(code, x, y, z). Returns the alert ID or { error }.

ParameterType
codeany
xany
yany
zany
LUA
local result = exports['coe_dispatch']:Alert(code, x, y, z)
exports['coe_dispatch']:Close(source, id) → any

Export server Close (server/main.lua).

ParameterType
sourceany
idany
LUA
local result = exports['coe_dispatch']:Close(source, id)
04 // COMMANDS

In-game commands 4

/atender <id>

Accepts a dispatch call and sets the route (requires being on duty in the category).

/chamado <codigo>

Asks police or EMS for help at your position (help_police, help_ems).

/chamados

Lists the calls of your category by urgency.

/encerrar <id>

Closes a dispatch call.