> For the complete documentation index, see [llms.txt](https://tru-development.gitbook.io/tru-development-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tru-development.gitbook.io/tru-development-docs/tru-radio/configuration.md). Agents can also search and read this documentation through its [MCP server](https://tru-development.gitbook.io/tru-development-docs/~gitbook/mcp).

# Configuration

Documentation / Tru-Radio

## Configuration

Edit `shared/config.lua`.

```lua
Config.Framework = 'auto'
Config.Inventory = 'auto'
Config.Voice = 'auto'
Config.DefaultVolume = 50
Config.MinFrequency = 1.00
Config.MaxFrequency = 999.99
```

Review `Config.WhitelistedAccess`, `Config.AcePerms`, `Config.Jammer`, `Config.Scanner`, `Config.AmbientRadioTraffic` and `Config.UI` for your server.

### Configuration reference <a href="#configuration-reference" id="configuration-reference"></a>

The following settings are present in the supplied configuration. Edit the existing entries rather than adding duplicate definitions. Table settings contain additional options in the original configuration file.

| Setting                                     | Supplied value or type     |
| ------------------------------------------- | -------------------------- |
| `Config.ItemName`                           | `'radio'`                  |
| `Config.Framework`                          | `'auto'`                   |
| `Config.Inventory`                          | `'auto'`                   |
| `Config.Voice`                              | `'auto'`                   |
| `Config.EnableCommand`                      | `true`                     |
| `Config.Command`                            | `'radio'`                  |
| `Config.RadioListCommand`                   | `'rlist'`                  |
| `Config.DefaultVolume`                      | `50`                       |
| `Config.MicClicks`                          | `true`                     |
| `Config.Animation`                          | Configuration table        |
| `Config.RemoveWeaponOnOpenRadio`            | `true`                     |
| `Config.DisableShootingWhileTalkingOnRadio` | `true`                     |
| `Config.DisconnectOnDeath`                  | `true`                     |
| `Config.RemoveOnOffDuty`                    | `true`                     |
| `Config.MinFrequency`                       | `1.00`                     |
| `Config.MaxFrequency`                       | `999.99`                   |
| `Config.EnableRadioList`                    | `true`                     |
| `Config.ShowSelf`                           | `true`                     |
| `Config.AllowEditName`                      | `true`                     |
| `Config.AllowEditCallsign`                  | `true`                     |
| `Config.ChannelNames`                       | Configuration table        |
| `Config.WhitelistedAccess`                  | Configuration table        |
| `Config.RestrictedChannels`                 | `Config.WhitelistedAccess` |
| `Config.AcePerms`                           | Configuration table        |
| `Config.Anonymous`                          | Configuration table        |
| `Config.Jammer`                             | Configuration table        |
| `Config.Scanner`                            | Configuration table        |
| `Config.AmbientRadioTraffic`                | Configuration table        |
| `Config.UI`                                 | Configuration table        |
| `Config.Locale`                             | Configuration table        |

### Testing changes <a href="#testing-changes" id="testing-changes"></a>

Test ordinary and restricted channels separately. Confirm voice works independently before diagnosing the radio interface. Restart the resource after editing configuration and check the console for Lua syntax errors. Keep a copy of your previous working settings.

### Additional configuration reference <a href="#additional-configuration-reference" id="additional-configuration-reference"></a>

The following top-level declarations are taken from the supplied configuration. Table openings indicate a nested configuration block; edit its existing fields in the original file rather than copying an incomplete table. Review inline comments and preserve Lua syntax.

```lua
Config.ItemName = 'radio'
Config.Framework = 'auto'
Config.Inventory = 'auto'
Config.Voice = 'auto'
Config.EnableCommand = true
Config.Command = 'radio'
Config.RadioListCommand = 'rlist'
Config.DefaultVolume = 50
Config.MicClicks = true
Config.Animation = {
Config.RemoveWeaponOnOpenRadio = true
Config.DisableShootingWhileTalkingOnRadio = true
Config.DisconnectOnDeath = true
Config.RemoveOnOffDuty = true
Config.MinFrequency = 1.00
Config.MaxFrequency = 999.99
Config.EnableRadioList = true
Config.ShowSelf = true
Config.AllowEditName = true
Config.AllowEditCallsign = true
Config.ChannelNames = {
Config.WhitelistedAccess = {}
Config.RestrictedChannels = Config.WhitelistedAccess
Config.AcePerms = {
Config.Anonymous = {
Config.Jammer = {
Config.Scanner = {
Config.AmbientRadioTraffic = {
Config.UI = {
Config.Locale = {
```

### Safe configuration workflow <a href="#safe-configuration-workflow" id="safe-configuration-workflow"></a>

Change one setting at a time on a staging server. Keep a known-working copy of the configuration, restart the resource after changes and test the affected workflow with a normal player. If a change causes a startup error, restore the previous configuration and inspect the first error in the console.

### Frequency policy and device settings <a href="#frequency-policy-and-device-settings" id="frequency-policy-and-device-settings"></a>

The supplied configuration uses a default volume of 50 and a frequency range from 1.00 to 999.99. Review WhitelistedAccess and AcePerms before assigning restricted frequencies. DisconnectOnDeath and RemoveOnOffDuty affect when a player loses access. Configure jammer, scanner and ambient traffic independently so that a problem with an optional device does not obscure basic voice testing.
