> ## Documentation Index
> Fetch the complete documentation index at: https://rust-co.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Installation

> Put RCO Vehicles and your vehicles on the server in a few minutes.

## What you need

* A RedM server with **RSG Core** or **VORP Core**.
* **oxmysql** (the database connection both frameworks already use).
* At least one RCO vehicle to sell, for example the **Wanderer** bicycle.

## Step by step

<Steps>
  <Step title="Copy the folders">
    Put the `rco-vehicles` folder and the folder of each vehicle (for example `rco-wanderer`) inside your server's `resources` folder.
  </Step>

  <Step title="Add them to server.cfg">
    Start them **after** your database and your framework:

    ```cfg theme={"dark"}
    ensure oxmysql
    ensure rsg-core        # or vorp_core

    ensure rco-wanderer    # each vehicle you bought, one line each
    ensure rco-vehicles
    ```

    Start your vehicles first, then RCO Vehicles. (If they end up in another order it still works: the shop notices vehicles starting at any time. What matters is that every vehicle has its own line, because a vehicle that is not running doesn't show up in the dealers.)
  </Step>

  <Step title="Start the server">
    The database table (`rco_vehicles`) is created by itself on the first start. You don't need to import anything.

    <Note>
      Only if your database user is not allowed to create tables: import `sql/rco_vehicles.sql` by hand once.
    </Note>
  </Step>

  <Step title="Test it">
    Go to the Saint Denis dealer, walk up to the clerk and press **J**. Buy a vehicle, ride it to a garage and press **R** to put it away. Then press **J** at the garage and take it out again.
  </Step>
</Steps>

## Changing things later

Every change in `config/config.lua` (prices, garages, keys...) needs a restart to show up.

<Warning>
  Close your game before restarting a vehicle resource, or restart the whole server. Restarting a resource that has 3D models while you are in the game can crash your game.
</Warning>

## Updating

Replace the folders with the new version. Your `config/config.lua` is yours: keep a copy before replacing and put your values back if the new version brings a new config. Players' vehicles are kept in the database and are not touched by an update.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.