โš™๏ธFull Configuration Breakdown

๐Ÿš€ X-NPC_Control Configuration Breakdown All settings are in config.lua โ€“ tweak values to match your serverโ€™s needs.


1. Debug Settings

For troubleshooting/development:

Config.Debug = {  
    RemoveAllNPCs = false,   -- [true/false] Wipe all NPCs on script start (use sparingly!)  
    Mode = false,            -- [true/false] Show debug text (FPS impact!)  
    Radius = 250.0,          -- Radius (meters) to scan for NPCs  
    RefreshRate = 1000       -- Debug UI update speed (ms)  
}  

Usage:

  • Set RemoveAllNPCs = true only to test performance.

  • Enable Mode = true to see NPC counts near players.


2. Population Control

Adjust NPC/vehicle density globally or dynamically:

Config.Population = {  
    PedBudget = 2,           -- 0=None, 1=Low, 2=Medium, 3=High  
    VehicleBudget = 2,       -- Same scale as above  
    MinBudgetLevel = 1,      -- Never go below this level  

    -- Dynamic adjustments:  
    EnableDynamicPopulation = true,   -- Master switch  
    PlayersPerLevel = 50,    -- Reduce density by 1 level per 50 players  
    NightTimeReduction = 1   -- Reduce by 1 level during nighttime  
}  

Recommended Presets:

Server Type
PedBudget
Dynamic Mode

Zombie Apocalypse

0

false

City Roleplay

2

true

Battle Royale

1

true


3. NPC-Free Zones

Create areas where NPCs vanish

Pro Tips:

  • Use /tp 323.26 -595.57 44.86 in-game to verify coordinates.

  • Set DrawZones = true temporarily to visualize boundaries.


4. Dispatch Services

Disable emergency responses:

Key IDs:

  • [1] Police cars

  • [5] Ambulances

  • [11] Gang activity


5. Scenario Control

Block annoying NPC behaviors:

Popular Scenarios to Disable:

  • WORLD_VEHICLE_MECHANIC โ€“ NPCs repairing cars

  • WORLD_VEHICLE_AMBULANCE โ€“ Random EMS spawns

  • WORLD_VEHICLE_BUSINESSMEN โ€“ Suit-clad NPCs


6. Gang Relationships

Control hostility levels:

Relationship Scale:

  • 0 Companion

  • 1 Respect

  • 2 Like

  • 3 Neutral

  • 4 Dislike

  • 5 Hate


7. Performance Tweaks

Reduce server strain:


8. Routing Buckets

Disable NPCs in specific dimensions (MLOs):

Common Uses:

  • Interior dimensions (e.g., apartments)

  • Event zones


โ— Troubleshooting

Issue
Quick Fix

NPCs still in zones

Increase zone radius by 10-20 meters

Police respond despite config

Set Config.DispatchServices[1] = true

FPS drops

Set PedBudget = 1 and disable scenarios


Need Help? Join FiveWorld Discord for config reviews and optimization! ๐Ÿš—๐Ÿ’จ

Last updated