> For the complete documentation index, see [llms.txt](https://visionstore.gitbook.io/visionstore-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://visionstore.gitbook.io/visionstore-docs/scripts/weaponhub/configuration/general.md).

# General

Language, integrations, admins, the inventory button, inventory rules, issued equipment and sounds.

Everything on this page is in `config/config.lua`.

## Language and debug

```lua
Config.Locale = 'en'            -- 'en' | 'ar' (any file in locales/)
Config.Debug = false            -- draws the bench zones and prints extra console lines
```

| Option          | Default | Meaning                                                                 |
| --------------- | ------- | ----------------------------------------------------------------------- |
| `Config.Locale` | `'en'`  | Any file in `locales/`: `en` (English) or `ar` (Egyptian Arabic)        |
| `Config.Debug`  | `false` | `true` draws the workbench zones in game and prints extra console lines |

## Framework and target

```lua
Config.Framework = 'auto'       -- 'auto' | 'qbx' | 'qb' | 'esx' | 'ox' | 'standalone'  (money, jobs, admins)
Config.Target = 'auto'          -- 'auto' | 'ox_target' | 'qb-target' | 'textui'
```

`auto` uses the first one that is running:

* **Framework:** qbx\_core, qb-core, es\_extended, ox\_core, then standalone.
* **Target:** ox\_target, qb-target, then the `[E]` prompt (`textui`).

Start the hub **after** them in `server.cfg`. What each framework provides is listed in [Framework bridge](/visionstore-docs/scripts/weaponhub/developers/framework-bridge.md).

## Admins

```lua
Config.Admin = {
    ace = 'vision_weaponhub.admin',
    groups = { 'admin', 'god', 'superadmin' },
    commands = true,
}
```

A player is an admin for `/weaponhub` and `/weaponhub_here` when **any** of these match:

| Option     | Default                            | Meaning                                                                                              |
| ---------- | ---------------------------------- | ---------------------------------------------------------------------------------------------------- |
| `ace`      | `'vision_weaponhub.admin'`         | `IsPlayerAceAllowed(source, ace)`, for example `add_ace group.admin vision_weaponhub.admin allow`    |
| `groups`   | `{ 'admin', 'god', 'superadmin' }` | The ace `<group>` or `group.<group>` (Qbox and txAdmin admins), QBCore permissions, or the ESX group |
| `commands` | `true`                             | `false` removes both commands                                                                        |

## Inventory button

```lua
Config.InventoryButton = {
    enabled = true,
    anywhere = false,
}
```

Only used when the "Customize" button is installed in ox\_inventory ([Installation](/visionstore-docs/scripts/weaponhub/installation.md)).

| Option     | Default | Meaning                                                                                                                                                                                                |
| ---------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `enabled`  | `true`  | Turn the button's action on or off                                                                                                                                                                     |
| `anywhere` | `false` | `false`: only next to a workbench, and that bench's rules apply. Away from one, the player gets a waypoint to the nearest bench. `true`: opens where the player stands, with no job, item or fee rules |

## Inventory rules

```lua
Config.MaxDistance = 4.0
Config.ReturnOnRemove = true
Config.KeepPartMetadata = true
Config.AllowUnownedPreview = true
```

| Option                       | Default | Meaning                                                                                                                   |
| ---------------------------- | ------- | ------------------------------------------------------------------------------------------------------------------------- |
| `Config.MaxDistance`         | `4.0`   | Metres between the player and the bench before the server refuses a request. The hub closes when the player walks further |
| `Config.ReturnOnRemove`      | `true`  | A removed attachment goes back into the inventory. `false` destroys it (the interface warns before saving)                |
| `Config.KeepPartMetadata`    | `true`  | An attachment's metadata (for example an "issued" flag) is kept on the weapon and given back when the part is removed     |
| `Config.AllowUnownedPreview` | `true`  | Players may preview parts they don't own. Fitting always needs the item                                                   |

## Issued equipment

```lua
Config.IssuedEquipment = {
    key = 'policeArmory',
    jobs = { police = 0, sheriff = 0 },
}
```

Weapons and attachments whose ox\_inventory metadata has `policeArmory = true` (set by your armory script) can only be changed by these jobs (job → minimum grade).

* A civilian holding an issued gun can't open it in the hub. Issued weapons are marked in the weapon list.
* An issued attachment can only be fitted by those jobs. Plain stacks of the same item are used first.
* With `Config.KeepPartMetadata`, an issued part keeps its metadata on the weapon and gets it back when removed, so issued parts can't be turned into personal ones.

Set `key = false` to turn the rule off. To use your armory's own check, see [Framework bridge](/visionstore-docs/scripts/weaponhub/developers/framework-bridge.md#issued-equipment).

## Sound and interface

```lua
Config.Sound = {
    enabled = true,
    volume = 0.6,               -- 0.0 - 1.0
}

Config.UI = {
    ServerName = 'VISION',      -- shown in the footer of the hub
}
```

| Option                 | Default    | Meaning                                                                                      |
| ---------------------- | ---------- | -------------------------------------------------------------------------------------------- |
| `Config.Sound.enabled` | `true`     | Synthesised interface sounds (no audio files). Players can mute them, and that is remembered |
| `Config.Sound.volume`  | `0.6`      | `0.0` to `1.0`                                                                               |
| `Config.UI.ServerName` | `'VISION'` | Your server name in the footer of the hub                                                    |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://visionstore.gitbook.io/visionstore-docs/scripts/weaponhub/configuration/general.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
