Breadcrumb's Awesome NPC Guard Shop

Breadcrumb's Awesome NPC Guard Shop 1.0.0

Denizen Version
# +--------------------------------------
# | Breadcrumb's Awesome NPC Guard Shop
# |
# | Your very own bodyguards in Minecraft!
# +--------------------------------------

This is a Denizen Bounty project.
It has been reviewed but not officially approved yet however.

This script will let you create bodyguards for players in Minecraft using Citizens and Sentinel!
Each Guard will have a set of commands that changes the current status of the Guard. Players can say the commands in chat or manage the statuses in an inventory GUI.

Plugin dependencies:
Denizen (to run this script)​
Citizens (NPCs)​
Sentinel (NPC combat!)​
Vault (Economy)​
Install all the plugins required above and put them into your plugins folder.​
After you run the server, a bunch of plugin folders will be created.​
Go into plugins/Denizen/scripts/ and drag this file into it.​
In game, use the command "/ex reload" to reload Denizen's scripts.​
How to use:
Configure all the config values below in "guard_shop_config".​
Create an NPC for the shopkeeper and assign it the "guard_shop_shopkeeper" assignment. (/ex assignment add script:guard_shop_shopkeeper)​
To open the shop inventory, the player must right click the Shopkeeper NPC.​
Some config values will need to be reloaded to take effect. Use the command "/reloadguards" to get the data updated.​
You can customize colors for chat, nametags, etc. by adding config values into your Denizen config.yml file.​
Here is a list of config values that you can set:​
guard_shop -- Colors the words "Guard Shop". Shows up in chat said by the Shopkeeper and in its GUI.​
guard_name -- The color that changes the Guard's name. Shows up in nametag and in chat.​
shopkeeper_name -- The color that changes the Shopkeeper's name. Shows up in nametag and in chat.​
toggleable_items -- The color of the display name of items that let you edit the Guards. Shows up in an inventory.​
use_guard_tip -- The color of the display name of the item in the Guard list that explains how to use the Guard.​
guard_status -- The color that indicates the status of the Guard. Shows up in item lores.​
reload_success -- The color that indicates the Guards have successfully reloaded. Shows up in chat.​
currency_color -- The color that colors the display of currency. Shows up in an inventory when buying a Guard.​
shopkeeper_dialogue -- The color of the Shopkeeper's dialogue.​
guard_dialogue -- The color of the Guard's dialogue.​
Here are some defaults that you can copy/paste into your config.yml file:​
guard_shop: <dark_aqua>
guard_name: <gold>
shopkeeper_name: <red>
toggleable_items: <red>
guard_status: <blue>
use_guard_tip: <green>
reload_success: <green>
currency_color: <green>
shopkeeper_dialogue: <white>
guard_dialogue: <white>
Guard commands
When in the proximity range specified in the "guard_shop_config" container, you can give the Guards commands by typing them in chat, or by using the command: /listguards and clicking on a specific Guard.​
The commands are "stay", "follow", "passive", "aggressive", and "remove".​
The "stay" command will make the Guards not follow the owner when the owner moves outside of the Guard's proximity range.​
The "follow" command will make the Guards follow the owner again.​
The "passive" command will make the Guard not harm any entity.​
The "aggressive" command will make the Guard attack entities.​
The "remove" command will remove the Guard completely.​


edit a guards statuses.png
Guard list inventory GUI
First release
Last update
0.00 star(s) 0 ratings

Share this resource