---
description: Configuration guide of Admin Menu System.
---

# Configuration

### Admin Menu Script – Configuration Guide

> This page explains every option inside <mark style="color:green;">`config.lua`</mark> so you can quickly adapt the Admin Menu to **ESX**, **QBCore**, or any custom framework.

***

#### <mark style="color:green;">1. Core Settings</mark>

```lua
Config.Framework = "auto" -- auto, esx, qb
Config.Language  = "en"   -- en, de, fr, es, pt
Config.isWeaponItem = true -- treat weapons as inventory items
Config.SpeedType = "km/h"  -- km/h or mph
Config.inventory  = "qb-inventory" -- qb‑inventory, ox_inventory, qs‑inventory, origen_inventory, custom
```

* **Framework** – chooses which core to load. `auto` picks the one that is running.
* **Language** – default locale (see `Config.Locales`).
* **isWeaponItem** – `true` if guns live in the inventory system.
* **SpeedType** – speed units shown in UI.
* **inventory** – name of the inventory resource. Set to `custom` and edit `server/editable.lua` if yours is different.

***

#### <mark style="color:green;">2. Opening the Menu</mark>

```lua
Config.Command = {
    active  = true,   -- enable / disable command
    command = "admin" -- /admin
}
Config.Key = {
    active = true,  -- hotkey toggle
    key    = "F6"  -- any FiveM key ID (e.g. F2, F10)
}
```

If both **Command** and **Key** are disabled, the menu can only be opened from code.

***

#### <mark style="color:green;">3. Revive Triggers</mark>

```lua
Config.ReviveTriggers = {
    "esx_ambulancejob:revive",
    "hospital:client:Revive"
}
```

Add **client event names** here so the Revive button works with your medical script.

***

#### <mark style="color:green;">4. Noclip Controls & Speed Steps</mark>

```lua
Config.NoclipControls = {
   goUp        = 85, -- Q
   goDown      = 48, -- Z
   turnLeft    = 34, -- A
   turnRight   = 35, -- D
   goForward   = 32, -- W
   goBackward  = 33, -- S
   changeSpeed = 21  -- L‑Shift
}

Config.noclipSpeeds = {
   {label = "verySlow",       speed = 0},
   {label = "normal",         speed = 2},
   {label = "extremelyFast",  speed = 10},
   {label = "maxSpeed",       speed = 25}
}
```

Feel free to remove or add speed tiers – the menu will list them automatically.

***

#### <mark style="color:green;">5. Fuel Callback</mark>

```lua
Config.getFuel = function(vehicle)
   if vehicle and GetResourceState('LegacyFuel') == 'started' then
       return exports["LegacyFuel"].getFuel(vehicle)
   end
   return 100 -- fallback
end
```

Edit this wrapper if you use a different fuel script.

***

#### <mark style="color:green;">6. Plate Generator</mark>

```lua
Config.Plate = {
   Letters   = 3,   -- A‑Z
   Numbers   = 3,   -- 0‑9
   UseDash   = true,
   Prefix    = "STG",
   UsePrefix = true
}
```

Plates created via the _Spawn Vehicle_ dialog follow these rules.

***

#### <mark style="color:green;">7. Pre‑defined Admins (optional)</mark>

```lua
Config.Admins = {
   {id = "VKQ84978", rank = "god"}
}
```

Add staff **Discord Snowflake** or **license hash** here to auto‑assign a rank on join.

***

#### <mark style="color:green;">8. Ticket System</mark>

```lua
Config.Ticket = {
   active  = true,
   command = "ticket",
   categories = {
      {id = "bug",        label = "Bug"},
      {id = "suggestion", label = "Suggestion"},
      {id = "question",   label = "Question"}
   }
}
```

Disable the module by setting `active = false`.

***

#### <mark style="color:green;">9. Permissions</mark>

The menu uses a **rank → permission tree**. Each rank inherits nothing, so explicitly set what you want.

Below is a **minimal example** — copy & extend it for real use.

```lua
Config.Permissions = {
  ["god"] = {
      label = "God",
      perms = {
          dashboard = {announcement = true, admin_tag = true},
          players   = {revive = true, ban = true},
      }
  },
  ["admin"] = {
      label = "Admin",
      perms = {
          dashboard = {announcement = true},
          players   = {revive = true},
      }
  }
}
```

_Any key omitted or set to `false` will be hidden in the UI for that rank._

***

#### 10. Need Help?

For support join [**STG Discord**](http://discord.gg/invite/stg).
