Page cover

🧬API

Integrate the Dispatch script with more of your scripts

Calls are used in case of an incident (like robbery). Messages are used for citizens to contact authorities

πŸ€™ CALLS

Use these Exports or Triggers to integrate Calls into your server

In client file:

every export can take coords as parameters (vector3), if not pass it will use the player position by default

exports['core_dispatch']:sendShootingAlert() -- Alert for shooting
exports['core_dispatch']:sendCarjackAlert() -- Alert for carjacking
exports['core_dispatch']:sendCarTheftAlert() -- Alert for car theft
exports['core_dispatch']:sendStoreRobbery() -- Alert for store robbery
exports['core_dispatch']:sendBankRobbery() -- Alert for bank robbery
exports['core_dispatch']:sendHouseRobbery() -- Alert for House robbery
exports['core_dispatch']:sendDrugSellAlert() -- Alert for Drug sell
exports['core_dispatch']:sendInjuredPersonAlert() -- Alert for injured person
exports['core_dispatch']:sendOfficerDown() -- Alert for officer down (priority alert)

In server file:

coords is the position where you want to trigger the alert

gender is the gender of a player you want to include in the notification (unknow if not set)

exports['core_dispatch']:sendShootingAlert(coords, gender) -- Alert for shooting
exports['core_dispatch']:sendStoreRobbery(coords, gender) -- Alert for store robbery
exports['core_dispatch']:sendBankRobbery(coords, gender) -- Alert for bank robbery
exports['core_dispatch']:sendHouseRobbery(coords, gender) -- Alert for House robbery
exports['core_dispatch']:sendDrugSellAlert(coords, gender) -- Alert for Drug sell
exports['core_dispatch']:sendInjuredPersonAlert(coords, gender) -- Alert for injured person
exports['core_dispatch']:sendOfficerDown(coords, gender) -- Alert for officer down (priority alert)

βœ‰οΈ MESSAGES

Use these Exports or Triggers to integrate Messages into your server

With export :

Example:

With event:

Example:

Last updated