# ESX Installation

## 🛠️ ESX Installation Guide

Follow these steps to install KVL GoDeliver on your ESX Legacy server.

### 📋 Requirements

Ensure you have the following resources installed:

* Framework: `ESX Legacy`
* Target: `ox_target` (or `qtarget`)
* Menu: `ox_lib` (Required for menus)
* Inventory: `ox_inventory`, `qs-inventory`, or `esx_inventoryhud`

***

### 🚀 Step 1: Download & Install

1. Download the `kvl-godeliver` resource from Keymaster.
2. Extract the folder into your server's `resources` directory.
3. Important: Rename the folder to exactly `kvl-godeliver` (remove any version tags).
4. Remove the ox\_lib brackets (on the fxmanifest.lua)

***

### 📦 Step 2: Register Items

You need to register the items in your database or inventory configuration. Choose the option that matches your inventory system.

#### 🟢 Option A: Using Ox Inventory (Recommended)

If you use ox\_inventory, open `ox_inventory/data/items.lua` and paste this code inside the `return { ... }` block:

Lua

```
-- KVL GoDeliver Items
['tablet_kurye'] = { label = 'Courier Tablet', weight = 100, stack = false, close = true, description = 'Tablet used to manage courier jobs.' },
['burgershot_bag'] = { label = 'Burgershot Bag', weight = 100, stack = true, close = true },
['pizzathis_box'] = { label = 'Pizza Box', weight = 100, stack = true, close = true },
['cluckinbell_bag'] = { label = 'CluckinBell Bag', weight = 100, stack = true, close = true },
['beanmachine_cup'] = { label = 'Bean Machine Cup', weight = 100, stack = true, close = true },

-- Fragile & Special Items
['electronics_tv'] = { label = 'Television', weight = 8000, stack = true, close = false, description = 'Contains sensitive components. Handle with care.' },
['glassware_vase'] = { label = 'Vase', weight = 8000, stack = true, close = false, description = 'Fragile item. Handle with care.' },
['electronics_pc'] = { label = 'Computer Case', weight = 8000, stack = true, close = false, description = 'Contains sensitive components. Handle with care.' },
['antique_clock'] = { label = 'Antique Wall Clock', weight = 3500, stack = true, close = false, description = 'A very valuable and fragile antique clock.' },
['furniture_mirror'] = { label = 'Large Mirror', weight = 6000, stack = true, close = false, description = 'Large surface area, easily breakable.' },
['grocery_wine'] = { label = 'Crate of Wine', weight = 4000, stack = true, close = false, description = 'Expensive wine bottles. Do not let them clash.' },
['medical_glassware'] = { label = 'Laboratory Supplies', weight = 1000, stack = true, close = false, description = 'Sterile and fragile glassware. Carry with extreme care!' },
['art_sculpture'] = { label = 'Small Sculpture', weight = 7000, stack = true, close = false, description = 'Unique art piece. Do not scratch or break.' },
['cold_package'] = { label = 'Cold Package', weight = 7000, stack = true, close = false, description = 'A package that must be delivered on time.' },
['important_documents'] = { label = 'Important Documents', weight = 500, stack = true, close = false, description = 'An envelope requiring urgent delivery.' },
['suspicious_package'] = { label = 'Suspicious Package', weight = 2000, stack = true, close = false, description = 'Better not to ask what is inside.' },
['broken_parts_box'] = { label = 'Broken Parts Box', weight = 7000, stack = true, close = false, description = 'Looks heavy and greasy.' },
```

#### 🟠 Option B: Using SQL (Standard ESX)

If you are not using Ox Inventory (e.g., using `qs-inventory`, `esx_inventoryhud`), run this SQL query in your database:

SQL

```
INSERT INTO `items` (`name`, `label`, `weight`) VALUES
	('tablet_kurye', 'Courier Tablet', 1),
	('burgershot_bag', 'Burgershot Bag', 1),
	('pizzathis_box', 'Pizza Box', 1),
	('cluckinbell_bag', 'CluckinBell Bag', 1),
	('beanmachine_cup', 'Bean Machine Cup', 1),
	('electronics_tv', 'Television', 8),
	('glassware_vase', 'Vase', 5),
	('electronics_pc', 'Computer Case', 5),
	('antique_clock', 'Antique Clock', 3),
	('furniture_mirror', 'Large Mirror', 6),
	('grocery_wine', 'Wine Crate', 4),
	('medical_glassware', 'Lab Supplies', 1),
	('art_sculpture', 'Sculpture', 7),
	('cold_package', 'Cold Package', 5),
	('important_documents', 'Important Docs', 1),
	('suspicious_package', 'Suspicious Pkg', 2),
	('broken_parts_box', 'Broken Parts', 7);
```

***

### 🖼️ Step 3: Setup Images

You need to place the item images into your inventory resource so they appear in-game.

1. Navigate to `kvl-godeliver/images`
2. Copy ALL .png files.
3. Paste them into your inventory images folder.
   * Ox Inventory: `ox_inventory/web/images/`
   * QS Inventory: `qs-inventory/html/images/`
   * Standard: `esx_inventoryhud/html/img/`

***

### ⚙️ Step 4: Configuration

Open `config.lua` in the script folder and ensure the framework is set correctly.

Lua

```
Config = {}
Config.Language = 'en' -- Options: 'tr' or 'en'

Config.Framework = 'ESX'
Config.Target = 'ox_target' -- or 'qtarget'
```

***

### ✅ Step 5: Start the Script

1. Add the following line to your `server.cfg` file:

   ```
   ensure kvl-godeliver
   ```
2. Restart your server. *(Note: If you used SQL, you might only need a script restart, but for Ox Inventory changes, a full server restart is required.)*


---

# 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://kavl.gitbook.io/kvl-store/scripts/godeliver/esx-installation.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.
