Exports
createAlert
Allows for triggering a dispatch alert on the player’s screen. Used for dispatching and robbery scripts.
Important: The jobs parameter is critical for segregating alerts (LSPD / EMS).
- Police (LSPD): Alerts with
jobs = {'police'}will go to the LSPD module and be blue. - EMS: Alerts with
jobs = {'ambulance'}will go to the EMS module and be red.
TriggerDispatch
A wrapper in editable/client/main.lua to simplify sending dispatch alerts directly from an external client script (e.g., jeweler script).
| Argument | Type | Description |
|---|---|---|
code | string | 10-code (e.g., “10-90”). |
title | string | Alert title. |
description | string | Event details. |
location | string | Street name or area. |
jobs | table | Job groups (e.g., {'police'}). |
openTablet
Opens the tablet for the current player (automatically detects if they should open LSPD, EMS, or DOJ based on their job).
getCurrentCode
Returns the current active LSPD code (threat level) object.
updateCode
Changes the current LSPD code (threat level).
| Argument | Type | Description |
|---|---|---|
codeId | string | The ID of the code from Config (e.g., ‘green’, ‘red’). |
