control panel
How the Panel Works
The control panel is a NUI-based interface that appears when you enter a supported emergency vehicle. It dynamically shows only the buttons that are relevant to the vehicle you're in — determined by the vehicle's configuration file.
Dynamic Button Visibility
When you enter a vehicle, the script reads its config and sends the available features to the UI. For example:
A police car with
blauw,directLinks,directRechts,directCenter,sirene,steadyBlue, andsteadyWhiteconfigured will show buttons for all those features.A fire truck that also has
pitjeandwaterSpraysconfigured will show those additional buttons.Features set to
"geen"(none) or omitted entirely will not show a button.
State Indicators
Each button reflects its current state visually:
Inactive — Default appearance, feature is off
Active — Highlighted or lit up, feature is on
The siren, dual siren, and rumbler siren each have their own independent state indicators.
Panel Position & Appearance
By default, the panel appears in the bottom-right corner of the screen. You can:
Drag it to a custom position using
/CP-editReset to default with
/CP-resetChange theme via the settings panel (
/cp-settings)Hide completely with
/hideUI
Your position and theme preferences are stored locally (via FiveM's KVP system) and persist across sessions.
Panel Commands
/hideUI
Toggle the control panel visibility
/cp-settings
Open the settings panel
/CP-edit
Enter drag mode to reposition the panel
/CP-reset
Reset the panel to its default position
/debugConfig
Print the current vehicle's model hash and config to the F8 console
Multiplayer Synchronization
All actions performed via the control panel are synchronized across all players. This includes:
Blue lights and all other extras-based lighting
Siren start, stop, and tone changes
Horn activation
Dual siren and rumbler siren toggles
Indicator states (left, right, hazard)
Traffic adviser position
The sync system uses a combination of StateBag change handlers and server events to ensure that nearby players hear and see the same state. When a new player joins or enters the area, active vehicle states are synced to them automatically.

