Docs/Multicharacter/Features/Character States

Character States

Multicharacter
Updated 7 months ago · v1.5.0

Character states are admin-defined flags attached to a character. They can be purely visual (a status icon + message on the multichar selector) or fully blocking (disable the character entirely so the player can't pick it).

Common use cases: Coma, In Hospital, Detained, Banned, AFK — anything where you want to show or restrict a character's availability.


Defining a State

In the configurator's States tab, each state has:

FieldPurpose
IconFontAwesome icon shown next to the character on the selector.
ColourTint applied to the icon + status pill.
MessageShort text shown to the player ("Currently in hospital — back in 15 minutes").
Disabled toggleWhen on, the character can't be selected. The slot greys out.

Applying a State to a Character

Two ways:

1. From the configurator (admin)

The States tab has an Online Players sub-panel. Search any online character → pick a state from the dropdown → apply. Useful for moderation actions (Detained, Coma).

2. From a Lua resource (programmatic)

Use the setCharacterState export. Useful for jobs / scripts (e.g. ambulance script applying "In Hospital" automatically):

lua
exports.dirk_multichar:setCharacterState(charId, 'in_hospital', {
  -- optional payload, e.g. timer / extra data shown to the player
  endsAt = os.time() + 900,
})

State Visibility

States are visible to the player when they next open the multichar selector — they see exactly why a character is unavailable and the configured message. No cryptic "you can't play this character right now".


Live Editing

lib.scriptConfig.on('characterStates', ...) keeps Lua-side and React-side in sync. The React copy reads from useScriptConfig.characterStates directly (no parallel hardcoded store) so admin saves propagate everywhere live.

Was this page helpful?
This page was last updated on 14 May 2026
DIRKSCRIPTS
All you need for your FiveM server.10% off your first order

Unsubscribe any time.

Copyright © 2026 DirkScripts. Not affiliated with or endorsed by Rockstar North or Take-Two Interactive.