EN · $ USD
Survival and Sandbox Servers

How to Set Up a GMod DarkRP Server

7 min read Updated: OyunBulut technical team

In short

To set up a DarkRP server, put the DarkRP gamemode in garrysmod/gamemodes/darkrp, put the darkrpmodification addon in garrysmod/addons and start the server with +gamemode darkrp. Jobs go in jobs.lua, weapon sales in shipments.lua and general settings in the darkrp_config folder. Because all customizations stay inside darkrpmodification and the core files are never touched, DarkRP updates don't wipe out your work.

In this guide
  1. DarkRP vs. darkrpmodification
  2. Prerequisite: a working GMod server
  3. Step-by-step DarkRP installation
  4. darkrpmodification folder structure
  5. Adding jobs (jobs.lua)
  6. Adding shop items (shipments.lua and entities.lua)
  7. Language settings (Turkish example)
  8. Core settings (settings.lua)
  9. Essential addons for an RP server
  10. Pre-launch test checklist
  11. Updates and backups
  12. How many resources does a DarkRP server need?
  13. Next step: open your city

DarkRP is Garry's Mod's most popular roleplay gamemode: players live in a city with jobs like police officer, medic, gun dealer or thief, earn money and roleplay within the rules. The foundation of a solid DarkRP server is installing the gamemode correctly and keeping every customization in the darkrpmodification addon. In this guide you'll find every step, from installation to adding jobs and shop items, language settings and the essential addons.

DarkRP vs. darkrpmodification

DarkRP comes in two parts, and this split is the most important thing to get right during setup:

  • DarkRP (gamemode): The actual game code. You never edit the files in this folder; that way, when an update comes out, you just replace the files.
  • darkrpmodification (addon): Where all your customizations live, such as jobs, shop items, settings and language files. DarkRP reads these files at startup and uses them to override the defaults.

Servers that edit the gamemode directly lose all their work with the first update. So the rule is simple: if you're changing something, do it in darkrpmodification.

Prerequisite: a working GMod server

DarkRP is installed on top of a standard Garry's Mod server. If you haven't prepared the server files, GSLT token and server.cfg settings yet, finish the Garry's Mod server setup guide first.

Step-by-step DarkRP installation

  1. Download DarkRP. The official source is DarkRP's GitHub repository (FPtje/DarkRP). Download the repository as a ZIP.
  2. Place the gamemode folder. Rename the extracted folder to darkrp and put it in garrysmod/gamemodes/. The resulting path must be garrysmod/gamemodes/darkrp/; if the folder has a different name (for example, DarkRP-master), the gamemode won't load.
  3. Download darkrpmodification. Get it from its official GitHub repository too (FPtje/darkrpmodification) and place it as garrysmod/addons/darkrpmodification/.
  4. Change the launch parameter. Enter +gamemode darkrp in the gamemode field on your web panel or on the launch line.
  5. Pick a suitable map. DarkRP uses city maps (maps starting with rp_). Add the map to your Workshop collection and put its name in the +map parameter.
  6. Start the server and check that there are no red Lua errors in the console.
./srcds_run -game garrysmod -console -port 27015 +maxplayers 40 +map rp_haritaadi +gamemode darkrp +host_workshop_collection KOLEKSIYON_ID +sv_setsteamaccount GSLT_TOKENINIZ

darkrpmodification folder structure

addons/darkrpmodification/lua/
  darkrp_config/
    settings.lua           -> general settings (salary, starting money, rules)
    disabled_defaults.lua  -> disable default jobs and items
    mysql.lua              -> optional MySQL connection
  darkrp_customthings/
    jobs.lua               -> jobs
    shipments.lua          -> weapon shipments and single weapons
    entities.lua           -> buyable entities
    categories.lua         -> F4 menu categories
  darkrp_language/         -> language files

Adding jobs (jobs.lua)

Each job is defined with DarkRP.createJob. The example below adds a police officer job that players are voted into:

TEAM_POLIS = DarkRP.createJob("Polis Memuru", {
    color = Color(25, 25, 170, 255),
    model = {"models/player/police.mdl"},
    description = [[Şehirde düzeni sağlar, suçluları tutuklarsınız.]],
    weapons = {"arrest_stick", "unarrest_stick", "stunstick", "door_ram", "weaponchecker"},
    command = "polis",
    max = 4,
    salary = GAMEMODE.Config.normalsalary * 1.45,
    admin = 0,
    vote = true,
    hasLicense = true,
    category = "Civil Protection",
})
  • command: Lets players switch to the job by typing /polis in chat; don't use spaces or non-ASCII characters.
  • max: How many players can have this job at the same time.
  • vote: If true, switching to the job requires a vote.
  • category: The category in the F4 menu; it must be defined in categories.lua.

If you want to replace the default jobs with your own custom jobs, disable them by setting the matching lines to true in disabled_defaults.lua.

Adding shop items (shipments.lua and entities.lua)

Shipments sold by the gun dealer are added with DarkRP.createShipment:

DarkRP.createShipment("Desert Eagle", {
    model = "models/weapons/w_pist_deagle.mdl",
    entity = "weapon_deagle2",
    price = 2150,
    amount = 10,
    separate = true,
    pricesep = 215,
    noship = false,
    allowed = {TEAM_GUN},
    category = "Pistols",
})

The job in the allowed list must be a TEAM_ variable defined in jobs.lua. Entities like money printers and microwaves are added in entities.lua with DarkRP.createEntity. The prices here are in-game DarkRP money; balance them together with salaries and starting money when you design your economy.

Language settings (Turkish example)

DarkRP is multilingual, and the language shown to each player is chosen based on that player's game language setting (gmod_language). To translate the interface text into Turkish, or to adjust existing translations for your server's language, you can add a language file to the darkrp_language folder:

-- addons/darkrpmodification/lua/darkrp_language/turkce.lua
local turkce = {
    -- Text keys you want to change
    -- copy the key names from DarkRP's English language file
}

DarkRP.addLanguage("tr", turkce)

Don't make up key names; copy them exactly from the English language file in the DarkRP gamemode folder and translate only the values. Job names, descriptions and F4 category names can be written in your server's language directly in jobs.lua and categories.lua.

Core settings (settings.lua)

The darkrp_config/settings.lua file holds starting money, salary range, door purchase cost, prop limits and many other rules. The file is long; on first launch, change only a few values, test the server, then keep going. On roleplay servers, economy balance comes down to how jobs and money work together; the principles in our roleplay economy guide, written for FiveM, apply to DarkRP as well.

Essential addons for an RP server

  • Admin mod: DarkRP includes its own FAdmin tool; most servers use a more advanced admin mod. To choose one, see the ULX vs. SAM guide.
  • Prop protection: DarkRP ships with Falco's Prop Protection (FPP); don't add another prop protection addon, as they conflict.
  • HUD and F4 menu: You can use custom HUD addons for your server's look; pick just one HUD.
  • Workshop content: Player models, vehicles and map content are delivered through a Workshop collection. You need a server with enough resources and the resource.AddWorkshop setting.
  • Persistent data: DarkRP uses SQLite by default. If you'll run several servers with shared data, you can connect MySQL through mysql.lua (requires the MySQLOO module).

Only install addons from sources you trust. Leaked (distributed without permission) addons can contain backdoors and hand control of your server to someone else. A backdoored addon can let an attacker make themselves superadmin, delete player data or download other code onto the server; that risk costs far more than buying the addon.

Pre-launch test checklist

Testing a DarkRP server for a few hours before opening it to players prevents most of the chaos on day one:

  1. Switch to every job. Check that weapons are given, the model looks right and that a vote starts for jobs that require one.
  2. Go through the F4 menu. An empty category or an item with an ERROR icon means a typo in that definition or missing Workshop content.
  3. Simulate the economy. Wait through one salary cycle, buy a door, order a shipment; do the prices make sense relative to salaries?
  4. Watch the console. By the end of testing, there shouldn't be a single red Lua error left in the server console.
  5. Write your rules. Make the basic RP rules, such as RDM (random deathmatch), NLR (new life rule) and metagaming, visible on the server and on Discord.

Updates and backups

Before updating DarkRP, back up the garrysmod/sv.db file (where player money and records are stored) and the addons/darkrpmodification folder. Then replace only the gamemodes/darkrp folder with the new version. As long as you don't touch darkrpmodification, your jobs and settings are kept.

How many resources does a DarkRP server need?

DarkRP is a gamemode that gets heavy fast as you add addons. Each addon adds Lua load, every model and vehicle takes up memory, and in busy cities the prop count drives up the physics load. As a general guideline, around 12 GB RAM is a comfortable start for a DarkRP server aiming for 30-60 players with Workshop content and dozens of addons; the exact need depends on your addon list.

For that scale, the OB-GMOD-4 DarkRP server plan with 4 CPUs and 12 GB RAM is a good fit. If you're planning a smaller test server or a bigger city, you can compare Garry's Mod server plans.

Next step: open your city

The fun part of DarkRP is shaping jobs, the economy and the rules around your own community; the technical side shouldn't slow that down. OyunBulut Garry's Mod servers run in our Istanbul data center; plans include DDoS protection, automatic setup and a web panel to manage your files, and you can open a support ticket whenever you get stuck. For an RP server with addons, check out the 12 GB RAM OB-GMOD-4 plan.

Frequently asked questions

Which folders do the DarkRP files go in?

The DarkRP gamemode goes in garrysmod/gamemodes/darkrp, and darkrpmodification goes in garrysmod/addons/darkrpmodification. The gamemode folder must be named exactly darkrp.

How do I add a new job to DarkRP?

Add a new definition with DarkRP.createJob to the addons/darkrpmodification/lua/darkrp_customthings/jobs.lua file. The category you use must be defined in categories.lua.

Why shouldn't I edit the DarkRP gamemode files directly?

When DarkRP updates, the gamemode folder is replaced and any direct edits are lost. Changes made inside darkrpmodification aren't affected by updates.

Can I translate DarkRP into another language, such as Turkish?

Yes. You can write job, shop and category names directly in your language, and add a language file with DarkRP.addLanguage to the darkrp_language folder for the interface text.

How much RAM does a DarkRP server need?

It depends on your addons and Workshop content. As a general guideline, around 12 GB RAM is a comfortable start for a DarkRP server with addons and 30-60 players.

For this guide

Recommended plans

With 12 GB RAM and 4 CPUs, OB-GMOD-4 gives you the room to run a DarkRP city packed with Workshop content and addons smoothly, even at peak hours.

OB-GMOD-4

Recommended

12 GB RAM

$9.24/mo

+VAT

  • Processor4 CPU
  • Disk60 GB NVMe
  • LocationIstanbul
  • DDoS Protection
  • Automatic Setup
  • Web Panel
  • 7/24 Support

4 GB RAM

$3.54/mo

+VAT

  • Processor4 CPU
  • Disk30 GB NVMe
  • LocationIstanbul
  • DDoS Protection
  • Automatic Setup
  • Web Panel
  • 7/24 Support

6 GB RAM

$5.31/mo

+VAT

  • Processor4 CPU
  • Disk35 GB NVMe
  • LocationIstanbul
  • DDoS Protection
  • Automatic Setup
  • Web Panel
  • 7/24 Support

Garry’s Mod — tüm paketler

Need help with setup?

Send questions about your service in a support ticket, and our technical team will walk you through it step by step.