# Installation

### 📥 Step 1: Download

1. Download the latest version from your purchase source
2. Extract the downloaded archive
3. Rename the folder to `0r-multicharacterv3` (remove any version numbers)

***

### 📁 Step 2: Place Resource

Move the `0r-multicharacterv3` folder to your server's resources directory:

```
resources/
├── [framework]/
├── [0resmon]/
│   └── 0r-multicharacterv3/    <-- Place here
├── [standalone]/
└── ...
```

{% hint style="info" %}
The folder structure doesn't matter as long as FiveM can find the resource.
{% endhint %}

***

### 🗄️ Step 3: Database Setup

#### Option A: Automatic Setup

The script will automatically create required tables on first start. However, we recommend manual setup for better control.

#### Option B: Manual Setup (Recommended)

1. Open `insert-me.sql` in the resource folder
2. Execute the SQL in your database management tool (HeidiSQL, phpMyAdmin, etc.)

```sql
-- The SQL file creates:
-- 1. 0r_multicharacterv3 - Stores character slot data
-- 2. 0r_multicharacterv3_code - Stores redeemable codes
```

***

### ⚙️ Step 4: Server Configuration

Add the following to your `server.cfg`:

```cfg
# Make sure these are started BEFORE 0r-multicharacterv3
ensure oxmysql
ensure ox_lib
ensure qb-core          # or es_extended / qbx_core
ensure ox_inventory     # or your inventory
ensure illenium-appearance    # or your clothing script

# Start other scripts
ensure [other_scripts]

# Start multicharacter
ensure 0r-multicharacterv3
```

{% hint style="danger" %}
**Critical:** Remove or disable these conflicting resources:

* `basic-gamemode`
* `spawnmanager` (if using standalone)
* `qb-multicharacter` (if migrating)
* Any other spawn/multicharacter scripts
  {% endhint %}

***

### 🔧 Step 5: Framework Configuration

#### For QBox (qbx\_core)

Edit `qbx_core/config/client.lua`:

```lua
 -- Whether you have an external character management resource. (If true, disables the character management inside the core)
useExternalCharacters = false,
```

#### For ESX

Edit `es_extended/shared/config/main.lua`:

```lua
Config.Multichar = true  -- Enable multicharacter support
```

***

### 🚀 Step 6: First Start

1. Start your server
2. Check the console for any errors
3. Connect to your server
4. You should see the multicharacter selection screen

***

### ✅ Verification Checklist

After installation, verify these work:

* [ ] Character selection screen appears on connect
* [ ] You can create a new character
* [ ] Character data saves to database
* [ ] Clothing/appearance saves correctly
* [ ] Spawn location works
* [ ] No console errors

***

### 🔄 Migrating from Another Multicharacter

#### From qb-multicharacter

1. Stop `qb-multicharacter`
2. Remove from server.cfg
3. Your existing player data will work automatically

#### From esx\_multicharacter

1. Stop `esx_multicharacter`
2. Remove from server.cfg
3. Character data uses the same table structure

{% hint style="warning" %}
Always backup your database before migrating!
{% endhint %}

***

### ❓ Need Help?

If you encounter issues during installation:

1. Check Common Issues
2. Review the FAQ
3. Join our [Discord](https://discord.gg/0resmon) for support


---

# 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://docs.0resmon.org/0resmon/0r-resources/0r-multicharacter-v3/getting-started/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.
