# Commands (/docs/orbit-studios-resources/orbit-dynamichud/commands)



# Commands [#commands]

<Callout type="warn" title="Framework note">
  The shipped `cash` and `bank` command implementation reads QB/QBX-style `PlayerData.money` from `QBCore.Functions.GetPlayer`. Disable or adapt those commands if you run ESX or standalone mode.
</Callout>

Command names come from the locale files, so the default English names are shown below. If you translate `locales/en.json` or change locale strings, use the translated command names in-game.

<TypeTable
  type="{
  restarthud: {
    type: 'client command',
    description: 'Restarts or refreshes the HUD state. Parameters: none.',
  },
  engine: {
    type: 'client command',
    description: 'Toggles vehicle engine behavior when enabled by the HUD. Parameters: none.',
  },
  onboarding: {
    type: 'client command',
    description: 'Reopens onboarding when onboarding is enabled. Parameters: none.',
  },
  cash: {
    type: 'server command',
    description: 'Shows cash account value when enabled. Parameters: optional target player ID.',
  },
  bank: {
    type: 'server command',
    description: 'Shows bank account value when enabled. Parameters: optional target player ID.',
  },
  setstress: {
    type: 'server command',
    description: 'Sets player stress when enabled and allowed. Parameters: stress amount, or target player ID plus stress amount.',
  },
}"
/>

## Parameters [#parameters]

<TypeTable
  type="{
  restarthud: {
    type: '/restarthud',
    description: 'No parameters.',
  },
  engine: {
    type: '/engine',
    description: 'No parameters. Only works from the driver seat while in a vehicle.',
  },
  onboarding: {
    type: '/onboarding',
    description: 'No parameters. Opens onboarding UI when the player is logged in and UI focus is available.',
  },
  cash: {
    type: '/cash [targetId]',
    description: 'If targetId is omitted, shows the command user cash. If targetId is provided, shows that player cash.',
  },
  bank: {
    type: '/bank [targetId]',
    description: 'If targetId is omitted, shows the command user bank balance. If targetId is provided, shows that player bank balance.',
  },
  setstress: {
    type: '/setstress <stress> | /setstress <targetId> <stress>',
    description: 'With one argument, sets your stress. With two arguments, sets target player stress. Stress is clamped from 0 to 100.',
  },
}"
/>

```text title="FiveM console"
/cash
/cash 12
/bank
/bank 12
/setstress 25
/setstress 12 25
```

Square brackets mean optional. Angle brackets mean required. For example, `/cash [targetId]` can be used as `/cash` or `/cash 12`, while `/setstress <stress>` needs a stress value.

Server command availability is controlled from `server/config.lua`.

```lua title="resources/[orbit]/orbit-dynamichud/server/config.lua"
Config.Commands.setstress = {
    enabled = true,
    allow = 'group.admin'
}
```

`allow` is the `ox_lib` restricted command group. Use the same shape for `cash`, `bank`, and `setstress`. Leave it empty only if normal players should be able to run the command.

```lua title="resources/[orbit]/orbit-dynamichud/server/config.lua"
Config.Commands.cash = {
    enabled = false,
    allow = 'group.admin'
}
```
