# Configuration

{% hint style="info" %}
This section details all available options in the `config.lua` file of **B14ck MultiJob**. The script has been designed to be highly customizable without touching the core code.
{% endhint %}

### General Configuration

| Variable               | Description                                                                                                                     |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| `Config.Debug`         | If set to `true`, shows detailed logs in the server & client console (F8/Console).                                              |
| `Config.Locale`        | Default language. Values: `en`, `es`, `fr`, `de`, `it`, `pt`, `br`, `ru`, `tr`, `pl`, `ar`, `zh`, `ja`, `ko`, `nl`, `sv`, `sk`. |
| `Config.Command`       | Chat command to open the menu (default: `multijob`).                                                                            |
| `Config.DefaultKey`    | Default key to open the menu (e.g., `F10`).                                                                                     |
| `Config.UseKeyMapping` | If `true`, players can change their own key in FiveM settings.                                                                  |
| `Config.Cooldown`      | Wait seconds between job changes (0 to disable).                                                                                |

### Administration & Permissions

```lua
Config.Admin = {
    UseAce = true,             -- Use ACE permissions (recommended)
    DiscordIds = { 'ID_HERE' }, -- Discord IDs with full access
    DiscordRoles = { 'ID_HERE' }, -- Discord Role IDs (requires API)
    SteamLicenses = { ... },    -- Steam Licenses with full access
    IPs = { '127.0.0.1' }       -- Allowed IPs
}
```

### Job Slots System

Define colors, icons, and images for each profession.

```lua
Config.Jobs = {
    ['police'] = {
        color = '#3498db',
        icon = 'fas fa-shield-alt',
        image = 'img/police.png' -- Used if JobDisplayType = 'image'
    },
    -- Rest of the jobs...
}
```

### User Interface (UI)

Customize the visual appearance of the monochrome menu.

| Option            | Values                           | Description                                                                 |
| ----------------- | -------------------------------- | --------------------------------------------------------------------------- |
| `DefaultTheme`    | `'auto' / 'dark' / 'light'`      | `'auto'` changes theme based on server time.                                |
| `ShowAvatar`      | `boolean`                        | Shows or hides the profile picture in the menu.                             |
| `AvatarType`      | `'discord' / 'mugshot' / 'both'` | Choose the source of the player image.                                      |
| `StylePreset`     | `string`                         | Choose from presets like `black-white`, `ocean-blue`, `sunset-orange`, etc. |
| `UseGradient`     | `boolean`                        | If `true`, applies an elegant gradient to the background.                   |
| `EnableDuty`      | `boolean`                        | Shows or hides the duty toggle button.                                      |
| `EnableFavorites` | `boolean`                        | Enables the favorite jobs system.                                           |
| `EnableKeybinds`  | `boolean`                        | Enables fast switching using keys 1-5.                                      |
| `JobDisplayType`  | `string`                         | `'font-awesome'` for icons or `'image'` for images.                         |

### Background Image Support

You can disable colors and use images (local or URLs):

```lua
Config.UI.Backgrounds = {
    Enabled = true,
    Menu = {
        dark = 'https://i.imgur.com/dark_bg.png',
        light = 'img/light_bg.png',
        opacity = 0.5
    }
}
```

### Activity Logs

```lua
Config.Logs = {
    Enabled = true,
    ServerName = 'My RP Server',
    IncludeAvatar = true, -- Include player photo in webhook
    Webhooks = {
        ['default'] = 'WEBHOOK_URL',
        ['admin'] = 'WEBHOOK_URL',
        ['jobs'] = 'WEBHOOK_URL',
        ['security'] = 'WEBHOOK_URL'
    }
}
```

| Category   | Description                                               |
| ---------- | --------------------------------------------------------- |
| `default`  | General system logs.                                      |
| `admin`    | Actions performed in the admin panel.                     |
| `jobs`     | Job changes and duty status updates.                      |
| `security` | Unauthorized access attempts or resource rename attempts. |


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://b14ck.gitbook.io/b14ck-scripts/scripts/multijob/configuration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
