🛠️ How to Install and Use the Shopkeepers Plugin
- PixelHost
- 16 ago 2024
- 5 Min. de lectura
Actualizado: 28 ago 2024
Creating a shop on a Minecraft server comes with its own set of challenges. Without some kind of security system, you're relying on trust that no one will come and steal all the items from your shop. If you opt for using redstone, an angry creeper might blow up your entire setup. Plugins like Shopkeepers are an excellent way to solve these problems. With Shopkeepers, you can create custom NPC shops to securely sell your items. Here’s a quick guide on how to install and use the Shopkeepers plugin with PixelHost.
📝 Overview
Shopkeepers allows you to create custom NPC shops for you or your players to use. The plugin works well on its own but can also integrate with Citizens for more control. These shops can be edited through a simple graphical interface to add items, set prices, and modify the shopkeeper’s appearance. Admins can also create shops with infinite items to sell things like loot crate keys or unique player heads. Here’s how to install the plugin and get it running on your server.
💻 Plugin Download
Go to the Shopkeepers Spigot page.
In the top right corner, click on the blue "Download" button.
Save the file in a secure location for later use.
🖥️ Server Installation
Navigate to your PixelHost Server Panel, then stop the server.
Scroll down to the Game Files section and take note of your server version.
Ensure the version is compatible with plugins, such as PaperMC or Spigot.
Common Issue: Not checking the server version can lead to incompatibility errors. Make sure you’re using a plugin-compatible server type.
Next, go to FTP Access in the left menu and log in.
Locate or create the "plugins" folder and enter it.
Click "Upload" in the top-left menu and drag the .jar file(s) you downloaded.
Once fully uploaded, return to the main page and restart the server.
Pro Tip: Double-check that the plugin has successfully loaded by typing /plugins in the server console. If Shopkeepers appears in green, you're good to go!
🛒 Player Shops
Player shops are the default shop type used by the plugin. Players can create a shop via commands or using the unique "Shopkeeper Egg" item. We recommend using the egg as it comes with instructions that will appear in chat when held by a player.
Run the /shopkeeper give command to get a shopkeeper egg, or purchase it in an admin shop if your server has one.
Common Issue: Forgetting to give players permission to use this command can cause frustration. Ensure permissions are set correctly in your server's permissions plugin.
Place a chest or another container near your shopkeeper. This is where your items will be stored.
Without looking at any blocks, right-click while holding the shopkeeper egg. This will set up the type of shop you want and give a description of each shop type.
Pro Tip: If you see a message saying you’re unable to place a shopkeeper, check the region or block protection settings.
With the egg still in hand, right-click the container you want the shopkeeper to use. This container will be protected by the plugin, so no other players can break or modify it.
Hold Shift to crouch and right-click with the egg to choose what type of NPC you want the shopkeeper to be.
Aim at the block where you want the shopkeeper to stand, then right-click with the egg to create the shopkeeper.
Finally, add the items you want to buy or sell to the shopkeeper's chest and right-click the shopkeeper while crouching to set the prices.
Pro Tip: If you notice items not being bought or sold, ensure that you’ve correctly set the currency and prices in the configuration.
👑 Admin Shops
Admin shops are easier to create than player shops. You just need to run a command to create the shop and then configure it with the items you want to sell. Unlike player shops, admin shops have infinite items, so you don’t need a storage chest for the shop to function.
Look at the block where you want the shopkeeper to stand, then run the command /shopkeeper [mob].
Replace [mob] with the name of the creature you want to use as an NPC. You can choose any in-game creature.
Common Issue: Be careful when choosing mobs that can be hostile, as this could confuse players. Stick to neutral or passive mobs for best results.
Hold Shift to crouch and right-click on the new shopkeeper to edit it.
Place the items you want to sell in the top row of boxes in the menu.
Place the items you want to use as currency in the second row of boxes.
Once the items are in place, you’re done! There are no additional settings you need to change for the shops to be usable right away. We recommend creating an admin shop like this to sell shopkeeper eggs. This will allow your players to easily create their own shops (for a price) without using commands.
Pro Tip: To prevent unintended changes, consider locking the shop after setup by disabling editing through permissions.
💰 Changing the Currency (Optional)
By default, the Shopkeepers plugin uses emeralds and emerald blocks as currency. This can be changed to a different item in the plugin’s configuration files. In the example below, we’ll change the currency from Emeralds to Diamonds. You can follow these steps to alter the currency to any item you prefer.
Go to your server’s control panel and click on the Config Files tab in the left menu.
Find the config.yml file for Shopkeepers in the list. The description will say something like Plugin Configuration File: plugins/Shopkeepers/config.yml.
Click the file to open it in our web editor.
Scroll down to the bottom of the page to find the currency-item: option.
The original currency is shown in the configuration file.
You can change the currency to whatever you want. This allows you to use any in-game block or adjust the currency value.
Pro Tip: Always backup your config files before making changes to avoid accidental loss of settings.
Once you’ve completed your changes, click the green Save button at the top of the page and restart the server.
Common Issue: If the currency doesn’t change as expected, ensure that the item ID or name is correctly entered in the config file.
🎉 Conclusion
With this guide, you’re ready to start creating your own shopkeepers on your Minecraft server. Adding shopkeepers to your server is an excellent way for your players to create their own automated shops. The plugin will automatically protect shops from potential thieves or griefers attempting to steal your inventory. You can watch your server’s economy grow as players get more involved without breaking any role-playing elements.
Best Regards,
João @PixelHost.
Comments