# Configuration

This page provides a breakdown of the configuration settings available for the Airplane Heist script for FiveM. Customize the settings to suit your server's requirements.

### Core Configuration

* **Config.core**: Defines the core framework.
  * `'qb-core'`: For QBCore-based servers.
  * `'ESX'`: For ESX-based servers.
* **Config.target**: Defines the targeting system for interactions.
  * `'default'`: No special targeting system.
  * `'ox'`: Ox Target.
  * `'qb'`: QB Target.

### Inventory System Configuration

* **Config.inventory**: Specifies the inventory system.
  * `'qb'`: qb-inventory (QBCore).
  * `'ox'`: ox-inventory (QBCore and ESX).
  * `'origen'`: origen\_inventory (QBCore).
  * `'ps'`: ps-inventory (QBCore).
  * `'qs'`: qs-inventory (QBCore).

### Dispatch System Configuration

* **Config.dispatch**: Specifies the dispatch system used.
  * `'default'`: Default dispatch message.
  * `'qs'`: QS-Dispatch.
  * `'rcore'`: RCore-Dispatch.
  * `'cd'`: CD-Dispatch.
  * `'ps'`: PS-Dispatch.

### Language Configuration

* **Config.language**: Language used in menus and notifications.
  * Choose from available languages: `'English'`, `'Arabic'`, `'Chinese'`, `'Spanish'`, `'French'`, `'German'`.
  * You can also add custom languages in the `/locales` folder.

### Heist Start Configuration

* **Config.startHeist**: Defines the start location and NPC setup for the heist.
  * **pos**: Starting position for the heist (vector3 coordinates).
  * **peds**: List of NPCs with their position, heading, and model.
  * **missionPlane**: Configuration for the mission plane (coordinates, heading, model).

Example:

```lua
Config.startHeist = { 
    pos = vector3(1700.9922, 3292.5791, 48.9221),
    peds = {
        { pos = vector3(1700.9922, 3292.5791, 48.9221), heading = 150.0, ped = 's_m_m_fiboffice_02' },
        { pos = vector3(1701.7700, 3291.4956, 48.9221), heading = 100.0, ped = 's_m_m_highsec_02' },
        { pos = vector3(1699.9771, 3292.7766, 48.9221), heading = 200.0, ped = 's_m_m_highsec_02' }
    },
    missionPlane = {
        pos = vector3(1715.5820, 3256.2510, 41.1183),
        heading = 98.2535,
        model = 'vestra'
    },
}
```

### Plane Mission Setup Configuration

* **Config.setupPlaneMission**: Defines the mission path, plane models, and fighter jets for the heist.
  * **path\_start**: Starting coordinates of the plane path.
  * **path\_end**: Ending coordinates of the plane path.
  * **cargoModel**: Model for the cargo plane.
  * **fighterModel**: Model for the fighter jets.

### Heist Items Configuration

* **Config.heistItems**: Defines the items required to participate in the heist.
  * **openContainer**: Item required to unlock the container (e.g., `'cutter'`).
  * **lootGold**: Item for carrying loot (e.g., `'bag'`).
  * **bombPlane**: Item required for bombing the plane (e.g., `'c4'`).
  * **parachute**: Item for parachuting (e.g., `'parachute'`).
  * **hackDevice**: Item for hacking (e.g., `'laptop'`).

**Config.oneTimeUse**: Set to `true` to remove items after single use.

Example:

```lua
Config.heistItems = { 
    openContainer = 'cutter',
    lootGold = 'bag',
    bombPlane = 'c4',
    parachute = 'parachute',
    hackDevice = 'laptop',
}
```

### Heist Rewards Configuration

* **Config.reward**: Defines the reward for completing the heist.
  * **itemName**: Name of the reward item (e.g., `'goldbar'`).
  * **grabCount**: Quantity of the reward.
  * **sellPrice**: Price of the reward at the buyer's location.
  * **rareItem**: A rare item that can be dropped (e.g., `'weapon_doubleaction'`).
  * **rareDrop**: Percentage chance of the rare item drop.

Example:

```lua
Config.reward = {
    itemName = 'goldbar',
    grabCount = 5,
    sellPrice = 1000,
    rareItem = 'weapon_doubleaction',
    rareDrop = 0,
}
```

### Police Requirements and Cooldowns

* **Config.requiredPoliceCount**: The required number of police to initiate the heist.
* **Config.nextRob**: Cooldown period in seconds before the heist can be triggered again.

### Hacking System Configuration

* **Config.customHack**: Set to `true` to use a custom hacking system (editable in `client/editable-main.lua`).

### Debugging Configuration

* **Config.debug**: Enable debug mode for testing and troubleshooting. Set to `true` to print debug info and allow test commands (e.g., `/hack`, `/hack1`, `/hack2`, `/bomb1`).

### Discord Webhook

* **Config.discord**: Set the webhook for sending messages to Discord.
  * **webhook**: The Discord webhook URL.

Example:

```lua
Config.discord = {
    ['webhook'] = 'WEBHOOKLINK',
}
```

***

### Notes

For advanced configurations, modify the editable files in accordance with your server's requirements.


---

# 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://enyo-scripts.gitbook.io/documentations/fivem-scripts/sky-heist/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.
