Sentry for Citizens2

Sentry for Citizens2

Sentry is a character plugin for the NPC plugin Citizens2. With Sentry, NPC's can be set to guard areas or act as bodyguards. Hostile targeting, retaliation, and a variety of options and stats allow a Sentry NPC to be customized to almost any guarding or combat situation.


Sentries Can:

  • Attack monsters, players, and groups automatically. Sentry also has built-in support for Factions, Towny, War and SimpleClans
  • Kill, and be killed by, players, monsters, and the environment.
  • Guard locations, paths, players, or other NPCs.
  • Use ranged or melee weapons. Shoot arrows, fireballs, snowballs, eggs, lightning, and potions with deadly accuracy.
  • Be configured with stats such as Strength, Health, Armor, Speed, Range and even Night Vision!
  • Ride mounts!
  • Work with Denizen to become Bosses and Quest NPCs that run scripts upon death.


  • Install Citizens2 Please use latest build
  • Place Sentry.jar in your minecraft /plugins/ directory. Start your server.
  • Create a NPC with Citizens and give it the 'sentry' trait.
    •  /npc create Town Guard --trait sentry 
  • Customize your Sentry's stats and options and you're ready to go.

A full list of commands and options is available on the Citizens 2 Wiki


Sentry makes a config.yml in the plugins/Sentry folder on first load. Use this to tailor Sentry to your server. You can:

  • Set defaults for new sentries
  • Change or disable the item used for various attack types
  • Add potion effects like slow or blindness to certain Sentry weapons.
  • Add armor, strength and speed buffs to armor and weapons for Sentries.
  • Set critical hit chances and messages.

The config.yml is commented with instructions.

You must login to post a comment. Don't have an account? Register to get one!

  • Avatar of mcmonkey4eva mcmonkey4eva Jul 21, 2014 at 21:12 UTC - 0 likes

    @thor54: Go

    You updated Bukkit to 1.7.10 but not Sentry. Get Sentry 1.8.2 Build 3 for 1.7.10 compatibility.

  • Avatar of thor54 thor54 Jul 21, 2014 at 03:03 UTC - 0 likes

    hi I am having problems since the 1.7.10 udate it can not load my sentry npc;s i deleted all citizen file all citizen file u dated to new file and i create and sentry npc and i cant equip it inless i do a manul select and then it doesn't safe the sentry next time i reboot the server its gone. and i keep getting errors on my sever console and this is in the log when i try to set trait: [20:55:32] [Server thread/INFO]: thorfinns[/] logged in with entity id 216 at ([world] 1274.9688067219029, 67.0, -1003.0314882685009) [20:56:00] [Server thread/INFO]: [WorldEdit] Using external NmsBlock for this version: CBXNmsBlock_1710 [20:57:14] [Server thread/INFO]: thorfinns issued server command: /npc select 0 [20:57:27] [Server thread/INFO]: thorfinns issued server command: /npc trait senrty [20:57:42] [Server thread/INFO]: thorfinns issued server command: /npc help [20:58:39] [Server thread/INFO]: thorfinns issued server command: /trait sentry [20:58:39] [Server thread/WARN]: java.lang.NoClassDefFoundError: net/minecraft/server/v1_7_R3/Packet [20:58:39] [Server thread/WARN]: at net.aufdemrand.sentry.SentryTrait.ensureInst( [20:58:39] [Server thread/WARN]: at net.aufdemrand.sentry.SentryTrait.onSpawn( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.api.npc.AbstractNPC.addTrait( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.api.npc.AbstractNPC.addTrait( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.commands.TraitCommands.addTrait( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.commands.TraitCommands.toggle( [20:58:39] [Server thread/WARN]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [20:58:39] [Server thread/WARN]: at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [20:58:39] [Server thread/WARN]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [20:58:39] [Server thread/WARN]: at java.lang.reflect.Method.invoke(Unknown Source) [20:58:39] [Server thread/WARN]: at net.citizensnpcs.api.command.CommandManager.executeMethod( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.api.command.CommandManager.execute( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.api.command.CommandManager.executeSafe( [20:58:39] [Server thread/WARN]: at net.citizensnpcs.Citizens.onCommand( [20:58:39] [Server thread/WARN]: at org.bukkit.command.PluginCommand.execute( [20:58:39] [Server thread/WARN]: at org.bukkit.command.SimpleCommandMap.dispatch( [20:58:39] [Server thread/WARN]: at org.bukkit.craftbukkit.v1_7_R4.CraftServer.dispatchCommand( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.PlayerConnection.handleCommand( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.PlayerConnection.a( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.PacketPlayInChat.a( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.PacketPlayInChat.handle( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.NetworkManager.a( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.ServerConnection.c(SourceFile:134) [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.MinecraftServer.v( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.DedicatedServer.v( [20:58:39] [Server thread/WARN]: at net.minecraft.server.v1_7_R4.MinecraftServer.u( [20:58:39] [Server thread/WARN]: at [20:58:39] [Server thread/WARN]: at [20:58:39] [Server thread/WARN]: Caused by: java.lang.ClassNotFoundException: net.minecraft.server.v1_7_R3.Packet [20:58:39] [Server thread/WARN]: at [20:58:39] [Server thread/WARN]: at [20:58:39] [Server thread/WARN]: at java.lang.ClassLoader.loadClass(Unknown Source) [20:58:39] [Server thread/WARN]: at java.lang.ClassLoader.loadClass(Unknown Source) [20:58:39] [Server thread/WARN]: ... 28 more

  • Avatar of mcmonkey4eva mcmonkey4eva Jul 18, 2014 at 18:18 UTC - 0 likes

    @Mexbotdude: Go

    For some reason, Sentry forces combat mode for mods. Fixing that requires either a code fix or switching to a different system, like dSentry.

    If you do something like "/npc sound -x" it'll error and show you the full help output. Which might help you understand.

  • Avatar of Mexbotdude Mexbotdude Jul 18, 2014 at 15:48 UTC - 0 likes

    @mcmonkey4eva: Go

    ok thanks

    I would like to ask you if there is any way to make skeletons and wither skeletons to attack me without shooting me. Im equipped a Wither Skeleton with a sword but he still attacks me bows and he won't walk to attack me

    P.D Do you know how to use the new citizens commands /npc sound and /npc effect. I need them but I can't find any tutorials

    Last edited Jul 18, 2014 by Mexbotdude
  • Avatar of mcmonkey4eva mcmonkey4eva Jul 16, 2014 at 22:13 UTC - 0 likes

    @Mexbotdude: Go

    Not natively with Sentry, but if you add something like Denizen ( ) you could use that to accomplish it.

  • Avatar of Mexbotdude Mexbotdude Jul 16, 2014 at 21:17 UTC - 0 likes

    Is there any way to make sentries make damage with effects?

    for example:

    I make a npc with type spider and when this sentry hit me, I get poisoned

  • Avatar of mcmonkey4eva mcmonkey4eva Jul 16, 2014 at 18:34 UTC - 0 likes

    @Homer04: Go

    ... What. Can you please clarify, or have a more English-experienced member of your server's staff post the question?

  • Avatar of Homer04 Homer04 Jul 16, 2014 at 11:23 UTC - 0 likes

    i make it and icant make the command what should i do when i make no thing come like i wasnt rite and thing why

  • Avatar of mcmonkey4eva mcmonkey4eva Jul 12, 2014 at 22:40 UTC - 0 likes

    @tdbulldog: Go

    Add target 'event:pvp' and give it a sword.

  • Avatar of tdbulldog tdbulldog Jul 12, 2014 at 20:21 UTC - 0 likes

    I want the Sentry to be in an area, and watch for players engaging in PVP, and if the players are, quickly run over, attack to kill both players, then after they PVP'ers dead, return to their post. Is this possible?

Your favorite Brigade?

  1. Choice:

  1. Results
  2. 0 comments


Date created
Sep 11, 2012
Last update
Jun 03, 2014
Development stage
  • enUS
Public Domain
Curse link
Sentry for Citizens2
Recent files