CommandNPC
CommandNPC is a plugin inspired by the server Mineplex, which adds a new function to NPCs. It allows users to run commands by simply right clicking on a Citizens NPC. Requires Citizens 2! Now requires Java 8
Commands and Permissions
(Now supports PlaceholderAPI)
To set up the npc with the commands you need the permission 'commandnpc.admin'
Be aware that flags that require additional input like [--v price], you need 2 dashes(-)!
-
/npc cmdadd [-c console] [-o Op] [-r random] [-i ignorePermMsg] [-l ignoreMoneyMsg] [--v price] [--t clickType] [--d delay] [--cd cooldown] [--p custom.permission.node] <command...> - Add a command to be executed upon clicking the selected NPC.
-
The -c flag runs the command through the console.
-
The -o flag runs the command as an op.
- The -r flag picks a random command and executes that one command only.
- The -i flag when true, noPerm message doesn't send
- The -l flag when true, noMoney message doesn't send
- The --v flag charges the player the specified amount, when running the command. (Numeric with decimal)
-
The --p flag requires the player to have the specified permission.
- The --d flag is the amount of ticks that the command will be delayed by. (Integer input)
- The --cd flag is a cooldown for the command in ticks. (20 ticks in a second)
- The --t flag sets the clickType('left', 'right', or 'both') | This will default to the global setting in config.yml
-
-
/npc cmdinfo [id] - Gets various information about all the NPC commands
-
If you include the command 'id' it will only show information for that command.
- You get the 'id' from using the 'cmdinfo' command
-
-
/npc cmdremove <id> - Removes a specific command
- You get the 'id' from using the 'cmdinfo' command
-
/npc cmdset <id> [-c console] [-o Op] [-r random] [-m cdMsg] [-i ignorePermMsg] [-l ignoreMoneyMsg] [--v price] [--t clickType] [--d delay] [--cd cooldown] [--p custom.permission.node] [command | cdMsg...] - Set various variables for the command
-
The -c flag runs the command through the console. (This will toggle between true/false)
- The -o flag runs the command as an op. (This will toggle between true/false)
- The -r flag picks a random command and executes that one command only.
- The -m flag is when you have a cooldown amount specified. When the player is in a cooldown and attempt to use the NPC, it will send them this message. (Usage: /npc cmdset -m [cdMsg...]) Note: When using other flags the cdMsg as to be the last things within the command.
- The -i flag when true, noPerm message doesn't send
- The -l flag when true, noMoney message doesn't send
- The --v flag charges the player the specified amount, when running the command. (Numeric with decimal)
- The --p flag requires the player to have the specified permission.
- The --d flag is the amount of ticks that the command will be delayed by. (Integer input)
- The --cd flag is a cooldown for the command in ticks. (20 ticks in a second)
- The --t flag sets the clickType ('left', 'right', or 'both')
- You get the 'id' from using the 'cmdinfo' command
-
-
/npc cmdreset - Remove all commands from the selected NPC.
-
You can use '%name' in commands as a placeholder for the user who is clicking the NPC.
- This plugin now supports a BungeeCord command. You may now use 'server <serverName>' to teleport people between servers!
How to setup the NPC
-
Edit config.yml to your likings
-
Select the NPC you wish to add commands too.
-
Use the command 'cmdadd' (Syntax listed above) to add the commands you wish.
-
These commands will be saved.
-
If you wish to remove the commands simply use the 'resetcmds' command. (Syntax listed above)
Metrics by bStats
Github
===== Donations =====
If you like what you see and want to support the development of this plugin and any other plugins I decide to create, you can donate to the developers! Just check the upper right of the page.
-
View User Profile
-
Send Message
Posted Dec 28, 20158.12 21:47:03 [Server] INFO at net.minecraft.server.v1_8_R3.PlayerConnection.handleCommand(PlayerConnection.java:1162) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at org.bukkit.craftbukkit.v1_8_R3.CraftServer.dispatchCommand(CraftServer.java:641) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at me.incomprehendable.dev.pwp.FakeSimpleCommandMap.dispatch(FakeSimpleCommandMap.java:98) [PerWorldPlugins.jar:?]
28.12 21:47:03 [Server] INFO at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at com.rylinaux.plugman.PlugManCommandHandler.onCommand(PlugManCommandHandler.java:104) [PlugMan.jar:?]
28.12 21:47:03 [Server] INFO at com.rylinaux.plugman.command.EnableCommand.execute(EnableCommand.java:127) [PlugMan.jar:?]
28.12 21:47:03 [Server] INFO at com.rylinaux.plugman.util.PluginUtil.enable(PluginUtil.java:72) [PlugMan.jar:?]
28.12 21:47:03 [Server] INFO at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:405) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at me.incomprehendable.dev.pwp.transparentlisteners.PerWorldPluginLoader.enablePlugin(PerWorldPluginLoader.java:141) [PerWorldPlugins.jar:?]
28.12 21:47:03 [Server] INFO at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:340) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:321) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at org.inventivetalent.cmdnpc.CommandNPCs.onEnable(CommandNPCs.java:91) [CommandNPC_v1.0.9.jar:?]
28.12 21:47:03 [Server] INFO at org.bukkit.plugin.SimplePluginManager.disablePlugin(SimplePluginManager.java:424) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at me.incomprehendable.dev.pwp.transparentlisteners.PerWorldPluginLoader.disablePlugin(PerWorldPluginLoader.java:136) [PerWorldPlugins.jar:?]
28.12 21:47:03 [Server] INFO at org.bukkit.plugin.java.JavaPluginLoader.disablePlugin(JavaPluginLoader.java:364) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:323) [spigot-1.8.8-20150820a.jar:git-Spigot-fdc1440-53fac9f]
28.12 21:47:03 [Server] INFO at org.inventivetalent.cmdnpc.CommandNPCs.onDisable(CommandNPCs.java:200) [?:?]
28.12 21:47:03 [Server] INFO at org.inventivetalent.cmdnpc.CommandNPCs.saveNPCs(CommandNPCs.java:206) [?:?]
28.12 21:47:03 [Server] INFO java.lang.NoClassDefFoundError: de/inventivegames/npc/NPCLib
28.12 21:47:03 [Server] ERROR Error occurred while disabling CommandNPCs v1.0.9 (Is it up to date?)
28.12 21:47:03 [Server] INFO Disabling CommandNPCs v1.0.9
28.12 21:47:03 [Server] ERROR ********
28.12 21:47:03 [Server] ERROR http://www.spigotmc.org/resources/5853
28.12 21:47:03 [Server] ERROR This plugin depends on NPCLib!
28.12 21:47:03 [Server] ERROR ********
28.12 21:47:03 [Server] INFO Enabling CommandNPCs v1.0.9
28.12 21:47:03 [Server] INFO AsasinTreepig: /plugman enable commandnpcs
28.12 21:46:51 [Server] INFO AsasinTreepig: /pl
I have the plugin installed but for some reason it will not work
-
View User Profile
-
Send Message
Posted Dec 27, 2015Some of them can only be executed with left click
-
View User Profile
-
Send Message
Posted Dec 25, 2015@Melonendk
You need Citizens plugin ^^
-
View User Profile
-
Send Message
Posted Dec 3, 2015Might it be possible to add a feature to attach command's to an armor stand?
-
View User Profile
-
Send Message
Posted Nov 21, 2015Yea i see its not working in spigot 1.8.8 when i put it in and load it this come up :)
Found out also that people need to download Citizens
-
View User Profile
-
Send Message
Posted Nov 20, 2015the commands.yml file is empty
-
View User Profile
-
Send Message
Posted Nov 15, 2015@wsos This should work perfectly. It works by forcing the player to chat it. Which in turn the command gets intercepted by the plugin it's by normally rather than through the API.
-
View User Profile
-
Send Message
Posted Nov 9, 2015Does this work with bungee? Such as using /send command to send players to a new server from a hub?
-
View User Profile
-
Send Message
Posted Nov 8, 2015OMG! new update! :D
-
View User Profile
-
Send Message
Posted Nov 8, 2015I haven't been around in a while. But when I put Spigot 1.8.8 server with this the latest build it works just as expected. Can someone come forward and offer how it's not working other than just saying it's not working. In my testing environment it works perfectly fine.
-
View User Profile
-
Send Message
Posted Oct 14, 2015@T6xyz
This is a very difficult thing to recreate exactly, as Mineplex pays big money to keep their plugins private. I have been working on something that is similar, but not exact. I'd be willing to give you a copy when it's finished.
NOTE: BungeeCord ONLY!
-
View User Profile
-
Send Message
Posted Oct 7, 2015update this plugin
-
View User Profile
-
Send Message
Posted Sep 20, 2015Please update to 1.8.8 thank you....
-
View User Profile
-
Send Message
Posted Sep 16, 2015I have one question, is there a way to make a delay on when ppl can click or no
i want to set so they can claim kit only once but i cannot
-
View User Profile
-
Send Message
Posted Sep 14, 2015How do I make the warp like in mineplex!!!
Help me!!!
-
View User Profile
-
Send Message
Posted Sep 14, 2015How to I make the warp npc i cant it says unknown command I have apex minecraft
-
View User Profile
-
Send Message
Posted Sep 9, 2015Hey guys guess what it works in 1.8!
-
View User Profile
-
Send Message
Posted Sep 1, 2015pls update to bukkit 1.8.8
-
View User Profile
-
Send Message
Posted Aug 30, 2015Join everyone / Csatlakozzon mindenki!
> southforest.servegame.com <
-
View User Profile
-
Send Message
Posted Aug 28, 2015update1.8please thanks