Skip to content

Events, state bags & commands ​

Events ​

EventSideArgumentsNotes
np_hud:client:notifyclient netdataSame as the client Notify export: TriggerClientEvent('np_hud:client:notify', src, data)
np_hud:notifyActionclient localid, actionEvery toast action (click or key)
np_hud:notifyActionserver localsrc, id, actionFired only after validation. Listen to this one
np_hud:server:notifyActionserver netid, actionInternal. Sent by the client for sv:* toasts. Don't listen to it

State bags ​

BagReplicatedDescription
LocalPlayer.state.seatbeltyesBuckled. np_hud sets it; other scripts may set it too (the server reads Player(src).state.seatbelt)
LocalPlayer.state.cruisenoSet by a cruise-control script to light up the cruise indicator
GlobalState.np_hud_players–Player count, maintained by np_hud's server script
GlobalState.np_hud_maxPlayers–Max players

Commands ​

CommandDescription
/hudToggle the HUD (Config.Commands.toggle)
/hudtheme <#hex|reset|none> [accent|tiles|glass]Preview a theme for yourself only (Config.Commands.theme)
/hud_demoOnly with Config.Debug: every toast variant, a prompt and a progress bar

Key mappings (hudseatbelt, hudaccept, huddecline, hudcancel) are listed under Configuration → Key mappings.

np_* FiveM resources