> For the complete documentation index, see [llms.txt](https://mango-5m.gitbook.io/mango5m-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mango-5m.gitbook.io/mango5m-docs/free-resources/mango-positions/configuration.md).

# Configuration

Every option in config.lua — commands, permissions, movement, the freecam, poses, props and formats.

Everything lives in `config.lua`, and it stays readable after escrow — poses, props, commands and keys are all meant to be edited.

## Options

| Option                      | Default         | Does                                                       |
| --------------------------- | --------------- | ---------------------------------------------------------- |
| `Config.Command`            | `'mpos'`        | The command that opens the tool                            |
| `Config.PropCommand`        | `false`         | Optional extra command opening straight into the prop tool |
| `Config.FitCommand`         | `false`         | Optional extra command opening straight into the fit tool  |
| `Config.Restricted`         | `'group.admin'` | Ace group allowed to use them. `false` = everyone          |
| `Config.MoveSpeed`          | `0.12`          | Metres per frame                                           |
| `Config.FastFactor`         | `4.0`           | `SHIFT` multiplier                                         |
| `Config.SlowFactor`         | `0.25`          | `ALT` multiplier                                           |
| `Config.RotateStep`         | `1.5`           | Degrees per frame on the arrow keys                        |
| `Config.FitRotateStep`      | `0.8`           | Degrees per frame when turning a fitted clone              |
| `Config.FitReach`           | `12.0`          | How far the fit picker looks, in metres                    |
| `Config.SnapToGround`       | `true`          | Snap the copied Z to the ground under the ghost            |
| `Config.PrintToConsole`     | `true`          | Also print each copy to F8                                 |
| `Config.GhostAlpha`         | `160`           | Ghost transparency, 0–255                                  |
| `Config.Formats`            | 4 entries       | Output formats cycled with `F`                             |
| `Config.Poses`              | 39 entries      | Poses cycled with `E` / `Q`                                |
| `Config.PropModels`         | 38 entries      | Props cycled with `E` / `Q`                                |
| `Config.FreecamControl`     | `0` (`V`)       | Cycles the freecam                                         |
| `Config.FreecamSpeed`       | `0.9`           | Freecam metres per frame                                   |
| `Config.FreecamSensitivity` | `6.0`           | Freecam mouse sensitivity                                  |
| `Config.SwitchPedControl`   | `157` (`1`)     | Jump to the ped tool                                       |
| `Config.SwitchPropControl`  | `158` (`2`)     | Jump to the prop tool                                      |
| `Config.SwitchFitControl`   | `159` (`3`)     | Jump to the fit tool                                       |

Key numbers are FiveM control IDs — see the [control reference](https://docs.fivem.net/docs/game-references/controls/). Set any of the switch or freecam options to `false` to disable that key entirely.

## Permissions

The command is registered **on the server**, and the ace check runs there too, so a modified client cannot open a tool it is not allowed to.

One line:

```cfg
add_ace group.admin command.mpos allow
```

{% hint style="info" %}
**One line covers all three tools**, because all three are reached through `/mpos`. If you switch on the optional `Config.PropCommand` or `Config.FitCommand`, they are allowed by that same ace — a per-command ace (`command.mprop`, `command.mfit`) is honoured too if you already have one, but nobody needs to add it.

This is deliberate: it means a tool added in a later update is not silently dead for everyone who set the resource up before it existed. Being denied is announced in chat rather than doing nothing.
{% endhint %}

Rename `Config.Command` and the ace name changes with it — `Config.Command = 'coords'` needs `add_ace group.admin command.coords allow`.

## Extra commands

`Config.PropCommand` and `Config.FitCommand` are `false` out of the box. `1`, `2` and `3` already move between the tools, so a command per tool is three things to remember for something one key does. Give either a name if you would rather jump straight in:

```lua
Config.PropCommand = 'mprop'
Config.FitCommand  = 'mfit'
```

Set `Config.Restricted = false` to let anyone use the tools. Reasonable on a private development server, not on a live one.

## Adding poses

Any animation dictionary and clip:

```lua
Config.Poses = {
    { name = 'Standing',  dict = nil,                                clip = nil },
    { name = 'Welding',   dict = 'amb@world_human_welding@male@base', clip = 'base' },
}
```

`dict = nil` means "no animation" — that is how `Standing` works.

{% hint style="warning" %}
An invalid clip name leaves a T-posing ped. The tool checks the animation actually started and prints the offending dict and clip to F8 if it did not, so a bad entry is obvious rather than mysterious.
{% endhint %}

## Adding formats

`%.4f` is substituted with X, Y, Z and heading, in that order:

```lua
Config.Formats = {
    { name = 'vec4',  fmt = 'vec4(%.4f, %.4f, %.4f, %.4f)' },
    { name = 'spawn', fmt = 'coords = vec3(%.4f, %.4f, %.4f), heading = %.4f' },
}
```

A format may use fewer than four — `vec3` simply stops after three.

## Adding props

```lua
Config.PropModels = {
    { name = 'Server rack', model = 'ch_prop_ch_server_01a' },
}
```

{% hint style="info" %}
A model name that does not exist in your game files cannot load. The tool waits about a second, then reports it to F8 by the `name` you gave it and leaves the previous ghost in place.
{% endhint %}

## The fit tool

`Config.FitReach` is how far the picker looks, and it is also how long the aim line is drawn — raise it to fit something large from further back, lower it if you keep catching scenery in front of your target. `Config.FitRotateStep` is deliberately finer than `Config.RotateStep`, because an attach rotation usually needs smaller adjustments than a heading does.
