VillagerShop
Latest Version: 0.4d
Description:
This version is dead since 2014 now
I switched to Sponge - The Bukkit Version does not Work!
This is here for archive purposes ONLY!
This plugin allows you to set up villagers as shops. They will sell items as admin shop (this means infinite stock). The shop will be displayed as two row inventory you can modify with chat commands as admin. Buy items from the top row and sell them at the bottom row. You may give custom names to shops and also use color codes (&). Please note that this plugin requires VAULT and a economy plugin like iConomy or Essentials. Villagers with no player in a range of 32 blocks will be despawned and as always - they should'n duplicate anymore ;D
List of commands:
To use this commads you have to position yourself at the spawn location of the shop.
Get a list of professions or items
/vshop create [PROFESSION] [NAME] creates a new shop at your location. name is optional./vshop delete deletes the shop at your current location/vshop add <ITEM> <AMMOUNT> [BUYPRICE]:[SELLPRICE] [NAME] add an item of type ITEM, stack size AMMOUNT and optional display name NAME. Please don't use this method, as it's pretty limited./vshop add hand [BUYPRICE]:[SELLPRICE] add the item you are currently holding including meta values like enchantmentsThe buy and sell price need to be seperated with a colon, NOT space. if you dont want a item to be sold or bought, leave that value empty. To put a price less than 1$ use two digits (e.g. 0.20 -> 0.2$)/vshop remove <SLOT> removes the item from the given SLOT if possible./vshop permission <SOMETHING> sets the permission required to interact with this villager to SOMETHING. You may think of a new permission or use any existing permission. OPs will automatically bypass this. Use "none" as <SOMETHING> to make the shop public again./vshop reload tries to delete and recreate all villagers. (will also dump shops.yml to hard drive until 0.4)/vshop save will dump shops.yml to hard drive instead of /vshop reload as of 0.4
Argument syntax & colors: <required> - [optional] - Numeric - Text - Static
Permission:
villagershop.admin in order to create/edit/delete villager shops
Example:
Walk to the location you want the shop to be and type the following into the chat The shop will then offer {Oak Wood x 64; Oak Wood x 32; Oak Wood x 1}
/vshop create WoodShop /vshop add log 64 30:15 /vshop add log 32 16:8 /vshop add log 1 2:1
Now if you want to remove the 2nd entry type: The items will now be {Oak Wood x 64; Oak Wood x 1}
/vshop remove 2
You don't have to set a buy- AND sell price, but at least one of them. This will add an apple for 1 million credits, but you wont be able to sell such:
/vshop add golden_apple 1 1000000:
Images:
Two villagers chatting The shop inventory
Well yes I am standing right where I spawned it and when I spawned it. I do /shop delete when I am standing right next to it and like 20 seconds after I spawned it but it does nothing. Same with adding items like /shop add stone 64 128:128 it does absolutely nothing. No message and when I click on the villager still nothing in his shop inventory.
@delsolsi213
thx for this suggestion.
@DosMike
Why not make it so it adds the item you're holding? so we can add items with custom names and lores?
@jujulogey97
try using the material name as given here http://jd.bukkit.org/rb/apidocs/org/bukkit/Material.html (in your case Iron_sword)
@drewnewman
are you sure you're still standing at the location you spawned the villager? the plugin will check your current location to match with a villagers SPAWN location. thats why they are teleported every 2 seconds
The only part of your plugin that actually works is the /shop create name. You then can't delete the shop or add items to it. I have vault and iconomy. So it has to be the plugin.
./shop add 267 1 450:100
Does not work. Why?
Oh, good to know and yes it works now that I have updated. Good job on the plugin it works very well and was just what I was looking for.
@get_ripped
i personally did not test this on craftbukkit 1.7.2-R0.2 but it works for me on R0.3, please try updating your craftbukkit
I am getting an error when I first reload/start my server of this plugin not even loading. I have vault installed and I even went and got iconomy. Looked like this:
[12:07:01 ERROR]: Could not load 'plugins\VillagerShop.jar' in folder 'plugins'
org.bukkit.plugin.UnknownDependencyException Vault
at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager
.java:196) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at org.bukkit.craftbukkit.v1_7_R1.CraftServer.loadPlugins(CraftServer.ja
va:255) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at org.bukkit.craftbukkit.v1_7_R1.CraftServer.<init>(CraftServer.java:23
3) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at net.minecraft.server.v1_7_R1.PlayerList.<init>(PlayerList.java:63) [c
raftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at net.minecraft.server.v1_7_R1.DedicatedPlayerList.<init>(SourceFile:14
) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at net.minecraft.server.v1_7_R1.DedicatedServer.init(DedicatedServer.jav
a:126) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at net.minecraft.server.v1_7_R1.MinecraftServer.run(MinecraftServer.java
:424) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
at net.minecraft.server.v1_7_R1.ThreadServerApplication.run(SourceFile:6
17) [craftbukkit.jar:git-Bukkit-1.7.2-R0.2-b2974jnks]
@Slickmajek127
did you expand the region vertical? in case you did i'm sorry it's not working
i made a separate region allowing mob spawning in the 1x1 area even a 3x3 area but still no villager is spawning .however, when i leave the region it will allow me to spawn a villager
@Slickmajek127
i could try to spawn the villager somewhere and tp it, but what if THAT block is protected? :/ try to create a 1x1 block region that allows mob-spawning.
The Plugin works great I like it but, the villager will not spawn in a region (world Guard protected) that doesn't allow mob-spawning. Is there a way you can make them bypass this ?
I actually uploaded a file, but it sais "Needs Approval". Check my homepage, if you can't wait.
Just uploaded another update. :s
cant wait for the release! (need it for my Server!)
Nice Plugin (Pre-release Tester)