crg-nonpc

🤖 NPC State Manager

A lightweight administrative tool allowing specific whitelisted identifiers to manage or modify NPC-related states on the server. This is ideal for developers, staff members, or automated systems that require controlled access to NPC functionality.


📁 Files

This script contains one primary configuration file:

  • main.lua (Config) — Identifier whitelist controlling who can manage NPC states


⚙️ Main Configuration

Below is the exact configuration structure used in the script: main

Config = {
    -- SUPPORTED Identifiers
        -- steamid
        -- license
        -- discord
        -- xbl
        -- liveid
        -- ip

    WhitelistToManageNpcState = {
        "discord:xxxxxxxx"
    }
}

🧩 Supported Identifiers

You can whitelist users using any of the following identifier types:

  • steamid

  • license (Rockstar license)

  • discord

  • xbl

  • liveid

  • ip

This flexibility allows full compatibility with all frameworks and authentication methods.


🔐 Whitelist System

Only players whose identifiers match entries inside Config.WhitelistToManageNpcState will gain access to NPC management features.

Example

You can add as many identifiers as you want.


🎮 What Can Whitelisted Users Do?

Depending on your implementation, whitelisted users can perform NPC management tasks such as:

  • Enabling or disabling NPC spawning

  • Modifying NPC behavior or density

  • Resetting or refreshing NPC states

  • Developer testing features

  • Admin-level NPC controls

(Exact functionality depends on how the script is integrated into your server.)


➕ Adding New Whitelisted Users

Simply place any valid identifier inside the array:

There is no limit to how many you can add.


🛡️ Security Note

To prevent unauthorized access:

  • Always use full identifiers

  • Avoid public distribution of your whitelist

  • Do not expose your server’s sensitive identifiers

Last updated