> For the complete documentation index, see [llms.txt](https://acestudios.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://acestudios.gitbook.io/docs/tactical-and-military/squad-link-v2/configuration.md).

# Configuration

Configure ace\_squadlinkV2 through config.lua.

All settings are in `Config.Settings` in `ace_squadlinkV2/config.lua`.

Useful references: [FiveM controls](https://docs.fivem.net/docs/game-references/controls/) · [blips and colors](https://docs.fivem.net/docs/game-references/blips/) · [text formatting](https://docs.fivem.net/docs/game-references/text-formatting/)

## Device

| Option             | Type   | Default        | Description                                                                                  |
| ------------------ | ------ | -------------- | -------------------------------------------------------------------------------------------- |
| `DeviceName`       | string | `'Squad-Link'` | Name used when the script shows the device name.                                             |
| `DeviceStyle`      | number | `1`            | `1` = phone style, `2` = tablet style.                                                       |
| `SquadLinkModel`   | number | `1`            | Default device color.                                                                        |
| `DevicePosition`   | string | `'Down-Right'` | Default screen position: `'Left'`, `'Middle'`, `'Right'`, `'Upper-Right'` or `'Down-Right'`. |
| `HideDeviceButton` | string | `'LMENU'`      | Key that hides or shows the device (Left Alt).                                               |

## Usage

| Option                             | Type    | Default         | Description                                                              |
| ---------------------------------- | ------- | --------------- | ------------------------------------------------------------------------ |
| `ShowStatsByDefault`               | boolean | `true`          | Statistics are on when the player joins. Players can always toggle them. |
| `ShowStatisticsCommand`            | string  | `'AtacStats'`   | Command that shows/hides statistics.                                     |
| `ShowStatisticsButton`             | string  | `'H'`           | Key that shows/hides statistics.                                         |
| `SetFrequencyCommand`              | string  | `'atac'`        | Command that changes frequency. It also toggles enlarged mode.           |
| `AllowInGameModelChange`           | boolean | `true`          | Lets players cycle device colors with a command.                         |
| `AllowInGameModelChangeCommand`    | string  | `'togglemodel'` | Command that cycles device colors.                                       |
| `AllowInGamePositionChange`        | boolean | `true`          | Lets players move the device with a command.                             |
| `AllowInGamePositionChangeCommand` | string  | `'changepos'`   | Command that changes device position.                                    |
| `ShowEnlargedVersionButton`        | string  | `'slash'`       | Key that toggles enlarged mode.                                          |
| `IncreaseZoomButton`               | string  | `'up'`          | Zooms in while enlarged.                                                 |
| `DecreaseZoomButton`               | string  | `'down'`        | Zooms out while enlarged.                                                |
| `ZoomIncreamentAmmount`            | number  | `50`            | Zoom step size. Smaller numbers give finer control.                      |

## Blips

| Option               | Type    | Default   | Description                                                                                                 |
| -------------------- | ------- | --------- | ----------------------------------------------------------------------------------------------------------- |
| `UsePlayerBlipNames` | boolean | `false`   | `true` = blips show players' in-game names. `false` = blips use `UseCustomBlipName`.                        |
| `UseCustomBlipName`  | string  | `'Allie'` | Blip label when `UsePlayerBlipNames = false`.                                                               |
| `DeadPlayerBlip`     | boolean | `true`    | Uses a different blip for dead players, labeled `KIA - <name>`.                                             |
| `DisplayVehBlips`    | boolean | `true`    | Changes the blip when a player is on foot vs. in a vehicle or aircraft. If `false`, the icon never changes. |
| `AliveBlipStyle`     | number  | `1`       | Blip sprite for alive players.                                                                              |
| `AliveBlipColour`    | number  | `77`      | Blip color for alive players.                                                                               |
| `DeadBlipStyle`      | number  | `310`     | Blip sprite for dead players.                                                                               |
| `DeadBlipColour`     | number  | `79`      | Blip color for dead players.                                                                                |

## Frequencies

| Option                | Type    | Default | Description                                                                 |
| --------------------- | ------- | ------- | --------------------------------------------------------------------------- |
| `RandomFirstTimeFreq` | boolean | `false` | `true` = new players get a random frequency between `0` and `MaxFrequency`. |
| `MaxFrequency`        | number  | `400`   | Highest allowed frequency. The minimum is always `0`.                       |
| `DefaultFrequency`    | number  | `101.1` | Frequency given to new players when `RandomFirstTimeFreq = false`.          |

{% hint style="info" %}
**Frequency rules**

* A frequency can have at most **2 decimal places**, and this can't be changed. `100.12` is valid, but `100.123` is not.
* `101.1` and `101.10` are the same frequency.
* The ReadMe says `MaxFrequency = 400` gives 40,000 possible frequencies.
  {% endhint %}

## Notifications

`Config.NotifactionsHolder` holds all player-facing messages, such as frequency changed, invalid frequency, and max/min frequency. You don't need to edit them, but you can translate them. `HelpWhenEnlarged` fills in the configured zoom and statistics keys automatically.
