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.
Features
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.
Installation
- Install Citizens2 You must use the correct version for your version of Bukkit
- Download the correct Sentry from the Citizens Wiki. You must use the correct version for your version of Bukkit
- 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
Configuration
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.
I will love you long time if you can make crackshot weapons hurt sentries.
Please please pleeeeaaasssseee.
Here is their API stuff: https://github.com/Shampaggon/CrackShot/wiki/Hooking-into-CrackShot
I like.. need this for my life to continue.
@Blamo27
Have to be version-compatible.
@Blamo27
Don't complain about weird behavior in /old versions/ - we can only fix current versions, not old ones.
And also... a TPS drop when you have too many NPCs... that's inevitable. If it drops when you only have a few NPCs, then there's a problem. (And it's only a valid problem if it's confirmed on the latest versions)
Thanks, resolved but when we are over a lot of NPC's, the TPS drops dramatically .. (In 1.8.0 or 1.7.1)
Please repare it ^^
Thanks, for all
So, we can't use Citizens 1.7.9, Sentry and Quests in 1.7.9 too, with CB or Spigot in 1.7.2 ?
@Blamo27
Hm... stuck on 1.7.2? Try Sentry v1.7.1 http://wiki.citizensnpcs.co/Sentry#Updates rather than 1.8.0, it might help
if not, well... upgrade to 1.7.9 and use latest builds rather than old ones.
[Server thread/WARN]: [Sentry] Task #6230 for Sentry v1.8.0 generated an exception java.lang.NoSuchMethodError: net.citizensnpcs.util.NMS.sendPacketsNearby(Lorg/bukkit/Location;[Lnet/minecraft/server/v1_7_R1/Packet;)V at net.aufdemrand.sentry.SentryInstance$SentryLogic.run(SentryInstance.java:1420) [?:?] at org.bukkit.craftbukkit.v1_7_R1.scheduler.CraftTask.run(CraftTask.java:58) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277] at org.bukkit.craftbukkit.v1_7_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:345) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277] at net.minecraft.server.v1_7_R1.MinecraftServer.u(MinecraftServer.java:614) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277] at net.minecraft.server.v1_7_R1.DedicatedServer.u(DedicatedServer.java:273) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277] at net.minecraft.server.v1_7_R1.MinecraftServer.t(MinecraftServer.java:562) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277] at net.minecraft.server.v1_7_R1.MinecraftServer.run(MinecraftServer.java:469) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277] at net.minecraft.server.v1_7_R1.ThreadServerApplication.run(SourceFile:617) [spigot.jar:git-Spigot-1.7.2-R0.3-122-gb58e277]
I have this error always > Citizens version: 2.011-SNAPSHOT (build 1098) Sentry version: 1.8.0
Please, help me :s (I tried all versions, and I can't update my bukkit.jar) Bukkit: Spigot-1.7.2-R0.3-122-gb58e277 (MC: 1.7.2)
This error is freezing my server (TPS: >= 6)
@Mekbot
Possibly just jrbudda wearing a different skin.
It's listed on the wiki as 'Knight', and I can't find it on http://mcmonkey.org/skin/knight/per/100/page/1 (but there are /thousands/ of other armored knight skins)
@Mekbot
That'd be the job of Denizen http://wiki.citizensnpcs.co/Denizen (The NPC scripting plugin)
is there a plugin that can make something like in mineplex, when you right click a npc it does a command, like get you a kit or teleport you, is that posible with citicens or any other plugin related
WHATS THE USERNAME OF THE GUY IN THE PICTURE
@rockdude3512
There's a list of target types here: http://wiki.citizensnpcs.co/Sentry#Targets
You're looking for /npc targets add event:pvp
@mcmonkey4eva Is there support for npc's to target players who are pvping? I'm about sure its implemented in Sentry, but how can I do it? Thanks - Rockdude
@Supershadow95
Builds for alternate versions are available on the wiki: http://wiki.citizensnpcs.co/Sentry#Updates
v1.8.1 is 1.7.5 compatible.
Can you release a version for 1.7.5? it would help quite a few server owners including myself who have stayed on this version due to plugin breakage
@mcmonkey4eva
my apologies, going to try to test what u recommended tonight and get back to you<sub>,</sub> I sure do miss having my Sentries wax people.
@cricketcricketcricket
And answered (and to be eventually dealt with) on github - no need to send something in twice!
Submitted to github - Budda today:
The Sentry plugin is dropping my server TPS from 20% to 1%. I just have the latest citizens2 dev build loaded as well as the latest dev of Sentry. If I create 1 NPC as a test(the only npc) everything is ok until i add the sentry trait then immiedetly the server TPS drops to 1%. I also tried this scenario with the latest dev build of denizen disabled. If I then remove the sentry trait; the server TPS goes back to 20%. This s just using fresh generated configs.
Thank you, LArry
@Crasher545
That Denizen action is designed to handle punching-type combat - firing arrows is a whole different thing!
You would probably need to listen to this world event: http://mcmonkey.org/evts/entity%20damages%20entity -> specifically, "on npc damages entity" and from there check tags like <npc.script> or whatever you prefer to identify the NPC. Perhaps even just check "<context.projectile||null> != null && <context.damager.as_npc.has_trait[Sentry]>" - if you want more help with Denizen, I highly recommend the IRC channel at http://webchat.esper.net/?nick=r_denizen_...&channels=denizen-dev&prompt=1 (Best to come online closer to US daylight hours though, when more people will be online)
If sentry is "brawler" action <attack on entity> occure right, but if sentry is "archer" <attack on entity> is not occure. Where may be bug? in sentry? or in denizen or may be in citizens.
@Dahvir
Don't blame Citizens for weird functionality in Sentry - a plugin made by a third party developer. It's like saying a given smartphone sucks because you downloaded a bad app.
You might be interested in something you can control yourself, rather than relying on weird devs to make things work - in which case, the Denizen scripting language (primarily for Citizens stuff) would interest you -> http://wiki.citizensnpcs.co/Denizen - here's an example of a Denizen script that replaces Sentry's functionality - http://mcmonkey.org/haste/4996
I am 500% done with this plugin. The sentries don't work at all. They won't move to attack, they won't equip weapons, they won't do anything! Severely disappointed in this, since it worked properly for about 20 minutes. After that, nothing. Tried reinstalling every plugin with the latest versions, even ones that had nothing to do with Sentry in the first place. I am just done with the Citizens plugin entirely if this is what to expect from it.