RD NPCs V1.0 - Advanced NPC Control System | Density | Zones | Spawner | Blacklist | Discord Logs

by RoxDev

Take full control of your server’s NPC population from a clean,
modern in-game panel. No framework required works on any FiveM server.


:movie_camera: Preview




















:sparkles: Features

Density Control

  • Walker and driver density sliders (0–100%)
  • Master toggles for walkers, drivers, emergency NPCs and scenario peds
  • Changes apply instantly across all players
  • Ambient sound toggle

Zone System

  • Create blackout, density, and spawn zones
  • Circle and rectangle shapes with full rotation support
  • Per-zone walker/driver targeting
  • Map blips and in-world markers for every active zone
  • Teleport to any zone from the panel
  • Deleting a zone instantly removes its NPCs from the world

NPC Spawner

  • Spawn any ped model at your position
  • Behaviors: wander, stand, flee, follow, guard, drive, scenario
  • Weapon assignment with ammo control
  • Protection modes: none, invincible, defend (bodyguard AI)
  • Temporary or persistent spawns

Blacklist

  • Ban any NPC model from spawning
  • Auto-purged on every density tick
  • Default blacklist configurable in config.lua

Preset System

  • Built-in presets: normal, roleplay, empty, populated
  • Apply from the panel or via command
  • Fully customizable in config.lua

Persistence

  • All settings, zones, and blacklist survive resource restarts
  • Uses native KVP storage β€” no database required

Discord Logging

  • Rich embeds for toggles, density changes, zone events, spawns
  • Per-category toggle from the Settings tab
  • Webhook configurable at runtime without restart

Access Control

  • Single ACE permission node (rd-npcs.admin)
  • Works with any permission system (txAdmin, ESX, QBCore groups, etc.)

:wrench: Commands

/rdnpcs β€” Open the panel
/rdnpcs_density walker <0-100> β€” Set walker density
/rdnpcs_density driver <0-100> β€” Set driver density
/rdnpcs_toggle walkers true β€” Toggle walkers
/rdnpcs_toggle emergency false β€” Toggle emergency NPCs
/rdnpcs_preset roleplay β€” Apply a preset
/rdnpcs_blacklist add β€” Blacklist a model
/rdnpcs_reload β€” Restart the resource

Default keybind: F6 (rebindable in GTA key settings)


:package: Installation

  1. Drop rd-npcs into your resources folder
  2. Add β€œensure rd-npcs” to server.cfg
  3. Grant the ACE permission:
    add_principal identifier.steam:XXXXXXXXXXXXXXX rd-npcs.admin
  4. Restart your server

No database required. No framework dependency.


:gear: Configuration (config.lua)

-- ─────────────────────────────────────────────────────────────────────────────
--  ACE PERMISSION
-- ─────────────────────────────────────────────────────────────────────────────
Config.AcePermission = 'rd-npcs.admin'
-- Grant in server.cfg:
--   add_principal identifier.steam:XXXXXXXXXXXXXXX  rd-npcs.admin
--   add_principal group.admin  rd-npcs.admin

-- ─────────────────────────────────────────────────────────────────────────────
--  DEFAULT STATE ON START
-- ─────────────────────────────────────────────────────────────────────────────
Config.Defaults = {
    walkers       = true,   -- pedestrians on/off
    drivers       = true,   -- vehicles on/off
    emergency     = true,   -- police on/off
    scenarios     = true,   -- scenario peds on/off
    walkerDensity = 100,    -- 0 to 100
    driverDensity = 100,    -- 0 to 100
}

-- ─────────────────────────────────────────────────────────────────────────────
--  PERSISTENCE
-- ─────────────────────────────────────────────────────────────────────────────
Config.Persistence = true
-- true  β†’ settings, zones and blacklist survive restarts (KVP, no database)
-- false β†’ resets to defaults on every restart

-- ─────────────────────────────────────────────────────────────────────────────
--  TICK RATES
-- ─────────────────────────────────────────────────────────────────────────────
Config.DensityTickRate = 500   -- ms, how often density is applied
Config.ZoneTickRate    = 1000  -- ms, how often zone detection runs
-- Raise these values to reduce client CPU usage

-- ─────────────────────────────────────────────────────────────────────────────
--  DEFAULT BLACKLIST
-- ─────────────────────────────────────────────────────────────────────────────
Config.DefaultBlacklist = { 'a_m_y_hipster_01', 'ig_barry' }
-- Models listed here are auto-deleted before any admin opens the panel

-- ─────────────────────────────────────────────────────────────────────────────
--  PRESETS
-- ─────────────────────────────────────────────────────────────────────────────
Config.Presets = {
    normal    = { walkerDensity = 100, driverDensity = 100, walkers = true,  drivers = true  },
    roleplay  = { walkerDensity = 25,  driverDensity = 15,  walkers = true,  drivers = true  },
    empty     = { walkerDensity = 0,   driverDensity = 0,   walkers = false, drivers = false },
    populated = { walkerDensity = 100, driverDensity = 100, walkers = true,  drivers = true  },
}

-- ─────────────────────────────────────────────────────────────────────────────
--  DISCORD WEBHOOK
-- ─────────────────────────────────────────────────────────────────────────────
Config.Discord = {
    enabled    = true,
    webhook    = 'https://discord.com/api/webhooks/...',
    botName    = 'RD-NPCs',
    botAvatar  = '',
    logSpawns  = true,
    logZones   = true,
    logToggles = false,
}

-- ─────────────────────────────────────────────────────────────────────────────
--  SERVER NAME
-- ─────────────────────────────────────────────────────────────────────────────
Config.ServerName = ''
-- Leave blank to auto-detect from sv_hostname / sv_projectName

:speech_balloon: Feedback & Support

Found a bug? Have a suggestion? Drop a comment below
I read every reply and push updates regularly.


:unlocked: Tiers (Tebex)

The free version is escrowed only config.lua is editable.
If you want to modify or learn from the source:

Tier Price What you get
Trial Free Escrowed, config.lua editable

[:backhand_index_pointing_right: Get it on Tebex β€” HERE]


:clipboard: Resource Info

Code is accessible Yes (config.lua) / Full on Tebex
Subscription-based No
Lines (approximately) ~1,800
Requirements None
Support Yes
3 Likes

When a zone is added, a red circle remains visible even after moving away from it. Is there a way to remove it?

1 Like

Hey, the red circle is part of the zone visualization in the free version and isn’t configurable without access to the source.

If you want full control over that and everything else, we have two options:

:wrench: Lua Source β†’ $4.99
Full access to all lua logic, tweak whatever you need

:star: Full Source (Lua + NUI) β†’ $12.99 ← recommended
Full control over ui + lua rebuild and customize everything

Need guidance on any edit? hit us on Discord: nyr_x. we’re happy to help

2 Likes

Looks good, but it’s a shame it still shows up on the minimap even when you’re all the way across the map.

1 Like

Yeah good catch we’re aware of it we’ll push a fix for that as soon as possible we’re currently heads down on another project but it’s on our list stay tuned and thanks for the feedback :handshake: