# Installation

### Dependencies

<details>

<summary>oxmysql</summary>

#### Installation

* Download the [latest build](https://github.com/overextended/oxmysql/releases/latest) of oxmysql (not the source code).
* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

#### Required version

Your oxmysql version must be <mark style="color:yellow;">2.0.0 or above</mark> in order to work with our system.

#### Use the built version

Make sure you have downloaded the <mark style="color:yellow;">built version</mark> of oxmysql! If you download the source code, then the resource won't start and queries are unable to execute.&#x20;

The built version can be downloaded from the [releases page](https://github.com/overextended/oxmysql/releases/latest) (oxmysql.zip).

</details>

### Installing the resource

1. Make sure you have the [dependencies](#dependencies) listed above installed.
2. Extract the contents of the archive to your resources folder.
3. Run the SQL queries provided in <mark style="color:blue;">rahe-drifting/db.sql</mark>.
4. Choose your framework tab from the section below & follow the instructions.

{% tabs %}
{% tab title="QB" %}
Open <mark style="color:blue;">rahe-drifting/config/shared.lua</mark> and set line 4 to <mark style="color:blue;">framework = 'QB'</mark>
{% endtab %}

{% tab title="ESX" %}
Open <mark style="color:blue;">rahe-drifting/config/shared.lua</mark> and set line 4 to <mark style="color:blue;">framework = 'ESX'</mark>
{% endtab %}

{% tab title="Custom" %}
Open <mark style="color:blue;">rahe-drifting/config/shared.lua</mark> and set line 4 to <mark style="color:blue;">framework = 'CUSTOM'</mark>
{% endtab %}
{% endtabs %}

### Using the resource

Use the command <mark style="color:blue;">/drifting</mark> in-game to open the application tablet.

### Importing tracks

There are 9 custom-made tracks included with the resource. If you wish, you can import these into your database to have some inital tracks. This is completely voluntary and is not required if you want to create your own tracks.

To import them, just run the SQL query provided in <mark style="color:blue;">rahe-drifting/tracks.sql</mark>

{% hint style="warning" %}
The drifting system is quite similar to our racing. Please refer to racing common questions / explanations if you encounter any issues or would like to know more.
{% endhint %}

{% content-ref url="../racing/common-questions" %}
[common-questions](https://docs.rahe.dev/our-scripts/racing/common-questions)
{% endcontent-ref %}

{% content-ref url="../racing/race-types-explained" %}
[race-types-explained](https://docs.rahe.dev/our-scripts/racing/race-types-explained)
{% endcontent-ref %}
