# How to Change the Dispatch

To customize the dispatch system used in our scripts, follow these steps:

* **Locate the Config File**: Find the `config.lua` file in your script directory. This file contains various configuration options for the script.
* **Edit the Dispatch Setting**: Open the `config.lua` file with a text editor. Look for the line that defines the dispatch setting:

```lua
dispatch = 'default',  -- cd_dispatch | qs-dispatch | ps-dispatch | rcore_dispatch | default
```

* **Choose Your Dispatch System**: Replace `'default'` with one of the following options based on the dispatch system you want to use:
  * `'cd_dispatch'` – For CD Dispatch
  * `'qs-dispatch'` – For QS Dispatch
  * `'ps-dispatch'` – For PS Dispatch
  * `'rcore_dispatch'` – For RCore Dispatch
  * `'default'` – For the default dispatch system (blip)
* **Save Your Changes**: After selecting the desired dispatch system, save the changes to the `config.lua` file.
* **Restart Your Server**: To apply the changes, restart your FiveM server.

## PS Dispatch

If you are using ps-dispatch, you should replace the dispatch jobs with the corresponding job types found in qb-core/shared/jobs.lua. Additionally, if you want a custom blip, you should add a blip option with the codeName found in the editable part of our scripts.

<figure><img src="/files/NwOYMTWYO35i2he7Lroo" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/D1ZfvCLr7hpk4XR0MtTg" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/9UkGCp3ae2Hx9SPyapys" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/8eFVXBkaLlWYdlyUaA88" alt=""><figcaption></figcaption></figure>

## Custom Dispatch

{% hint style="warning" %}
Our scripts generally support cd dispatch, qs-dispatch, ps-dispatch, rcore dispatch. If you are using a different dispatch, find the madCore.policeAlert function in the editable sections of our scripts and add your own dispatch script's export, trigger, etc. to the default section.&#x20;
{% endhint %}

By following these steps, you can configure the dispatch system that best fits your server’s needs. If you encounter any issues or need further assistance, please refer to the support section or reach out via our Discord server.


---

# 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.rainmad.com/development-guide/how-to-change-the-dispatch.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.
