RELEASE 1.1.0
Warning: There could be possible bugs happen when there are many different players involved.
This is a script where you can spawn an NPC to a certain target ID, either the NPC can be attacking them or protecting them, or just idle.ย
NPC On Command | Advanced NPC Spawner & Controller
By Apollo Flight Program
OVERVIEW
You can take full control of NPCs with this powerful admin tool. Spawn aggressive enemies, assign defensive bodyguards to players, or set up idle NPCs โ all through an intuitive in-game UI. Perfect for events, roleplay scenarios, or adding dynamic encounters to your server.
FEATURES
๐ฏ Three NPC Behaviors
- Aggressive โ NPCs attack the target player on sight
- Defensive โ Bodyguard NPCs that follow and protect the assigned player
- Idle โ Stationary guard NPCs
๐ก๏ธ Smart Defensive AI
- NPCs automatically follow their assigned player
- Enter vehicles with the player (finds available seats)
- Engage threats that attack their owner
- Teleport to player if they get too far behind
- Stay/Hold position command support
๐ฎ Player Controls (for assigned NPCs)
- [G] Follow Me
- [H] Stay/Hold Position
- [J] Disband All
- Fully rebindable in FiveM Settings
๐ Admin NPC Monitor
- View all players with assigned NPCs
- Add or remove NPCs from any player
- Mass disband options (all defensive / all aggressive)
- Real-time NPC counts
๐ง Additional Features
- Set player ped models
- Pre-configured ped groups (Military, BlackOps, Mercenary, Mexican Gang, Motor Club, and more!)
- ACE permission system (
npc.admin) - Auto-cleanup on resource stop
- Optimized performance
๐ WHAT'S INCLUDED
| Escrowed (Protected) | Open Source (Customizable) |
|---|---|
| client.lua | ped_groups.lua (Config) |
| server.lua | index.html |
| script.js | style.css |
โ๏ธ CUSTOMIZABLE CONFIG
Buyers can fully customize:
- NPC Stats (armor, accuracy, combat ability)
- AI Behavior (follow distance, combat range, teleport distance)
- Ped Groups (add your own custom NPC model lists)
- UI Styling (colors, fonts, layout)
๐ COMMANDS
| Command | Description |
|---|---|
/npctool | Open the admin NPC menu |
/npcclear | Clear all spawned NPCs |
/npcfollow | NPCs follow you |
/npcstay | NPCs hold position |
/npcdisband | Disband your NPCs |
๐ REQUIREMENTS
- FiveM Server
- ACE Permissions (for admin access)
๐ ๏ธ INSTALLATION
- Extract to your resources folder
- Add
ensure AFP_NPCOnCommand_V1to your server.cfg - Add ACE permission:
add_ace group.admin npc.admin allow - Restart your server
๐ฌ SUPPORT
Join our Discord for support and updates!
Version: 1.1.0
Game: GTA V (FiveM)