> For the complete documentation index, see [llms.txt](https://docs.lokiscripts.com/loki-scripts-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.lokiscripts.com/loki-scripts-documentation/loki_impound/home-en/installation-and-configuration.md).

# Installation and configuration

## **1. Database Setup**

First, we need to setup the needed additions to your database. By default the setting Config.CreateTables is turned on and creates everything needed automatically for you on startup. If you disabled this, execute the required.sql file,

## **2. Configuring the Config File**

Now you need to adjust the config file to your liking. All points in the config are explained below. you can also see a full preview of the Config on the page [Config Preview](/loki-scripts-documentation/loki_impound/home-en/config-preview.md)

### ESX Export

```lua
Tax.EsxExport = true
```

This setting is used for never ESX versions that use the export on server side to get the ESX data instead of TriggerServerEvent. I think this is used for everything after 1.8.5, if you use 1.8.5 or below, turn this setting off.

### Create Tables

```lua
Tax.CreateTables = true
```

If this is set to true, on first startup the script will automatically do the needed changes to your database such as creating the table for the registered vehicles. After this is done, this setting has no effect and can be turned off.

### **Impounds**

```lua
Config.Impounds = {

  Police = {
    Position = vector3(453.1104, -1145.9418, 28.5141),
    VehicleSpawn = vector3(440.3765, -1150.2145, 29.2919),
    VehicleSpawnRotation = 270,
    Size = { x = 2.5, y = 2.5, z = 2.5 },
    Color = { r = 110, g = 243, b = 113}, 
    Type = 27,
    Blip = 67,
    BlipColor = 3, 
    Society = 'society_police',
    police = 0,
  },
  Mechanic = {
    Position = vector3(-392.9936, -144.1660, 37.5322),
    VehicleSpawn = vector3(-387.4104, -142.0013, 38.5234),
    VehicleSpawnRotation = 215,
    Size = { x = 2.5, y = 2.5, z = 2.5 },
    Color = { r = 110, g = 243, b = 113}, 
    Type = 27,
    Blip = 67,
    BlipColor = 5, 
    Society = 'society_mechanic',
    mechanic = 0,
  },
}
```

Here you can configure the individual impounds. For example, Police is the name of the first impound, Position specifies the coordinates of the impound or marker as a Vector3(x, y, z). VehicleSpawn, also specified as a vector3, determins where vehicles are spawned when a player unparks them. VehicleSpawnRotation specifies the direction they are facing (0°-360°). Size is simply the size of the marker, make sure all 3 values are the same. Color is the color of the marker in RGB format (0 to 255 per color). Type is the type of marker, 27 is a simple circle on the ground. You can find the different types here: [markers](https://docs.fivem.net/docs/game-references/markers/). Blip is the blip that is displayed on the map, you can find the available ones here: [blips](https://docs.fivem.net/docs/game-references/blips/). BlipColor is the color of the marker on the map, you can find the available colors here as code: [colors](https://wiki.rage.mp/index.php?title=Blip::color). Society is the society to which the money from the bail etc. is transferred. Make sure it is specified correctly, these are usually listed as society\_\[jobname] in the addon\_account\_data table. police = 0 specifies the job and rank that can impound vehicles at this impound, police is the job, 0 is the rank. You can add as many more jobs as you like using the same schema. You can add as many more impounds as you like.

### **Locale**

```lua
Config.Locale = 'en'
```

Here you can find the language of the script. Currently available are de and en for German and English. You can also view and edit the translations yourself, open the corresponding file in the locales folder.

### **Currency**

```lua
Config.Currency = '$'
```

This specifies the currency you want to use. This is irrelevant for the system, it only changes whether 500€ or 500$ or something else is displayed in notifications, for example.

### **Webhook Discord Logs**

```lua
Config.Webhook = true

Config.WebhookLink = ''
```

Set Config.Webhook to true to enable logs via Discord. You also need to insert the link to your Discord Webhook in Config.WebhookLink. To get it, go to the channel on your Discord where you want the log to be. Go to the gear icon there and then to Integrations in the menu. Now you can create a new Webhook under Webhooks and then New WebHook and copy the link there.

### Auctions

```lua
Config.AuctionDelay = 28
Config.AuctionDuration = 4
```

**Config.AuctionDelay** specifies the number of days after a vehicle is released for impound that the auction will start. 28 here means that the auction will start if the owner has not picked up their vehicle after 4 weeks. **Config.AuctionDuration** is the duration of the auction in days.

### Bail

```lua
Config.MaxBail = 50000
Config.MaxBailDays = 14
```

**Config.MaxBail** is the maximum bail that can be set for a vehicle. **MaxBailDays** is the maximum duration that can be specified before a vehicle is released for impound.

### JacksamVehicleKeys

```lua
Config.JacksamVehicleKeys = false
```

If you use Jacksams vehicle keys script, set this to true. All this does is refresh the players keys when spawning a vehicle.

### zapps\_billing

```lua
Config.zapps_billing = false
```

If your server uses zapps\_billing, you can set this entry to true, then everything will be entered into the billing menu. Otherwise, just leave it at false.

### Menu

```lua
Config.Menu = 'context' -- context = esx_context, default = esx_menu_default, esx_menu_dialog, esx_menu_list
Config.MenuPosition = 'top-left'-- top-left | top-right | bottom-left | bottom-right | center - for default only
```

Here you can switch between an esx\_context and an esx\_default menu. Whe using a default menu, you can also choose the position.

### Notifications

```lua
Config.Notification = 'esx' -- available options: okokNotify, RiP-Notify, esx, custom

function CustomNotify(type, msg, heading, currentID) 
    print('customNotify')
end
```

Here you can set your notifications. Config.Notification has esx, okokNotify, RiP-Notify and custom available, if you select custom you can insert your own function for notifications below. type is the type of message, info, success, or error. msg contains the message itself, heading the heading if supported by your system and currentID the serverID of the player.

## 3. LOKI\_TAX Integration

```lua
Config.UseTax = false

Config.BailTax = 0.05 -- ~5%
Config.AuctionTax = 0.05 -- ~5%
Config.TaxSociety = 'society_unemployed'
```

If you own our loki\_tax script, you can use these features. Simply set Config.UseTax to true. Then, a percentage specified below will be automatically deducted from auctions and bails and transferred to the specified society. 0.05 corresponds to 5%. You can also set that registered vehicles will be automatically impounded if the owner cannot pay the tax. For more information, please refer to the documentation and config of loki\_tax.


---

# 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 dynamically by asking a question.

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

```
GET https://docs.lokiscripts.com/loki-scripts-documentation/loki_impound/home-en/installation-and-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.
