Installation

Step-by-step guide to install Tommy's Radio on your FiveM server.

Setup

Prerequisites

  • FiveM server artifact 4752 or newer (run version in your server console to check)
  • tLib v0.6+ — install the release zip (not the source zip — source lacks the built files), add ensure tLib to server.cfg above tRadio
  • A free port for the voice server (default 7777)

Extract Files

Download the release zip, transfer it to your server, and unzip on the server — don't copy individual files. Place the extracted folder in resources/.

Folder name

Name the folder anything. provide 'tRadio' in fxmanifest.lua aliases exports — scripts calling exports['tRadio']:someExport() find it regardless of folder name. Use your actual folder name in server.cfg.

Configure Settings

Edit config/config.lua. These four fields must be set before starting:

config/config.lua
Config = {
    serverPort    = 7777,        -- Port for the voice server (must be unused)
    authToken     = "CHANGE_ME", -- Secret key — change before going live
    adminPassword = "CHANGE_ME", -- Web admin panel password — change before going live
    dispatchNacId = "141",       -- NAC ID required to log into the dispatch panel
}

Change dispatchNacId

The default "141" is also the public demo server's dispatch login code. Leave it unchanged and anyone who knows it can access your dispatch panel.

Open Your Port

The radio voice server needs its own port — separate from FiveM (30120) and txAdmin (40120). You cannot reuse an existing port.

Web Panel Hosting (Pterodactyl / Most Providers)

  1. In your hosting panel find Network, Ports, or Allocations and add a new port (e.g., 50978)
  2. Update config/config.lua:
config/config.lua
Config = {
    serverPort    = 50978,
    serverAddress = "http://YOUR_SERVER_IP:50978/",
}
  1. Restart the entire server from the panel — not just the resource
  2. Verify at portchecker.co while the resource is running

Many providers require a support ticket

Pterodactyl-based hosts (Gravel Host, RocketNode, VibeGames, etc.) often require a support ticket to actually open the port after you add it in the panel. Tell them: "I need port [PORT] opened for a custom voice server resource."

VPS / Dedicated Server

Open the port in your firewall. Leave serverAddress blank — the script auto-detects your IP.

# Ubuntu/Debian
sudo ufw allow 7777

# CentOS/RHEL
sudo firewall-cmd --permanent --add-port=7777/tcp && sudo firewall-cmd --reload
# Windows Server
netsh advfirewall firewall add rule name="Radio" dir=in action=allow protocol=TCP localport=7777

Home Server

Forward port 7777 (TCP) in your router settings and set your public IP in serverAddress:

config/config.lua
Config = { serverPort = 7777, serverAddress = "http://YOUR_PUBLIC_IP:7777/" }

Common Port Mistakes

  • Using port 30120 or 40120 — already taken by FiveM / txAdmin
  • serverPort and the port in serverAddress don't match
  • Wrong serverAddress format — must be "http://IP:PORT/" with http:// prefix and trailing /
  • Testing before the resource starts — the port only opens when tRadio is running
  • Assuming your hosting panel opened the port — always verify with portchecker.co

Start the Resource

server.cfg
ensure tLib
ensure tRadio

Use your actual folder name (e.g., ensure [tScripts]/tRadio if it's in a category bracket folder). Restart your server. A successful start prints:

 +----------------------------------------------------+
 |  Tommy's Radio - System Ready                      |
 |  Version: v6.0                                     |
 |  Panel:   http://192.0.2.100:7777/                 |
 |  NAC ID:  141                                      |
 +----------------------------------------------------+

Open http://your-server-ip:port/admin in a browser and log in with adminPassword to configure zones, audio, alerts, and everything else — no restart needed for any of those changes.


Minimal Working Example

The complete chain that puts a police officer on a working radio channel:

1 — Zone & channel (admin panel → Zones & Channels):

Zone: "Statewide"
  Channel: "DISPATCH"   type: conventional   frequency: 154.755

2 — Codeplug (admin panel → Codeplugs → New): Set Name to LSPD Patrol (ID auto-generates as lspd-patrol), NAC to 141, select at least one layout in Allowed Models. Under Channel Access, enable the DISPATCH channel. Save.

3 — Job mapping (config/sv_functions.lua):

local JOB_CODEPLUG_MAP = {
    ['police'] = 'lspd-patrol',   -- must match the codeplug ID above
}

4 — Restart the resource:

restart tRadio   (or your actual folder name)

A player with job police now opens a radio pre-loaded with the LSPD Patrol codeplug, sees the Statewide zone, and can transmit on DISPATCH. Add more zones, channels, and codeplugs from the admin panel at any time — no restart needed.


Updating tRadio

Replace everything except these files and folders:

KeepReplace
config/config.luaEverything else
data.json
config/cl_functions.lua
config/sv_functions.lua
layouts/
  1. Download the new release zip and extract it somewhere temporary
  2. Delete everything from your existing folder except the five items above
  3. Copy all files from the new zip into your folder
  4. Run restart tRadio in the server console (use your actual folder name)

Release notes call out any changes to config.lua keys. Check them before updating.

Resetting to defaults

To reset all admin panel settings to config.lua defaults: stop the resource, delete data.json, and restart. All zones, channels, codeplugs, and audio settings configured via the admin panel will be lost.

On this page

Need help?

Ask on Discord