eShop
This is a Shop plugin supporting the major economy plugins (iConomy, BOSEconomy, Essentials', and MultiCurrency). This was coded from the ground up with the intent to return the shop commands that seem to be disappearing from servers. The plugin requires you have This Register Jar in your plugins folder too.
Commands
All the shop commands can be found under "/shop".
The first argument is "buy", "sell", or "check". "buy" gives the player the item for the amount of money defined in the configuration files. "sell" gives the player the money for the items. "check" allows the player to see how much the items go for.
The second argument is the item. This is either a name as given by bukkit (ex. "diamond_pick_axe"), Essentials if you have it installed (ex. "diamondpickaxe"), or any names defined in the configuration. you can add a colon (:) and put a number after it (no spaces) for a specific material data. You can also use a name for the type (ex. "blue" or "birch") based on the item type itself.
The third argument is optional, and it's the amount to buy or sell. If you don't define it, it implies 1. Define a number to purchase or sell that amount. If you're selling, you can use "all" and it will sell all the items of that type in your inventory. Defining a material data will force only that type to be sold.
Configuration
The first time you run the server with the plugin, it will make three files in the folder "plugins/eShop/".
item.price.txt
This holds all the costs for the command. Format each line with the numbers as follows:
<Item ID> [Data] <Buy Amount> <Sell Amount>
You can add the data value to the line, however that will force the price to only apply to that data value alone. The Item ID and the Data are both positive integers, while the buy and sell amounts are doubles. Some economy plugins round the values of the prices. If that happens, it will report a warning just before the plugin loads (look out for it). If you set any of the prices to 0, it will prevent that specific action (example: setting buy as 0 will prevent the purchase of the item, but still allow it to be sold).
item.local.txt
This allows you to set names used to find items. The file reads as so:
<Name> <Item ID> [Data]
You can define a data value for the name. The Item ID and Data are both positive integers. Name can be any string unless it contains a space or a colon (:) (although use common sense and don't use something not on standard keyboards).
plugin.local.txt
This is the localization for the plugin. Almost all the player messages are stored here and can be edited to either change my horrible messages or to even use a different language. The escape character for this is '&', so &[0-F] will be that color, &g will return the variable (ex. the price or the item type), and && will return a '&' character.
Also, there is a commented out line in this file, "Permissions = true". If you use a permissions plugin that doesn't use bukkit's built in system, uncommenting this line should get it to work. Doing so will activate the Permissions hook, so Permissions 2.7, 3.x, and GroupManagerBridge should all work.
Permissions
This plugin has three permissions nodes and one parent node that covers all three. They are as follows:
eShop.buy = allows player to use /shop buy eShop.sell = allows player to use /shop sell eShop.check = allows player to check prices (implied if they have .buy or .sell) eShop = all of the above
I made updated version for Mc / Bukkit 1.6.4 -> This is working version of eShop with mod's blocks and items
1) You have to download new version compatible with Bukkit 1.6.4
2) You have to create money account in Iconomy with name "eShop"
This version is using eShop account for storing eshop money.
3) You have to download and use Register plugin (it's like Vault plugin)
4) You have to set prices (here is example how to make it)
EXAMPLE
Link to register: uloz.to/xXko8kSA/register-0-2-jar
Link to updated version by me: uloz.to/xyYJQ9PD/eshop-1-3-jar
I made updated version for Mc / Bukkit 1.6.4 -> This is working version of eShop with mod's blocks and items
1) You have to download new version compatible with Bukkit 1.6.4
2) You have to create money account in Iconomy with name "eShop"
This version is using eShop account for storing eshop money.
3) You have to download and use Register plugin (it's like Vault plugin)
4) You have to set prices (here is example how to make it)
EXAMPLE
@saxon564
Try it :)
I think that
+
Will work OK even on MCPC+ server with forge mods :)
Does this plugin even work with the most recent craftbukkit? i ask because of how outdated it is.
@LRFLEW
Hi, nice to meet You again.
I'd like to paste it to your github but I think that I need access for that or not? You can contact me with Skype (nick: Sharp.man Country: Czech Republic, Prague). Or ICQ: 331-186-272
I'm sorry I haven't updated this. I have been really busy lately, and I neglected to update all of my plugins. I remember I have a lot of work on an update that allows this plugin to use Vault instead of Register. I will upload the changes I have to GitHub, take one last look at it, and release it as a beta build. I will try to test it myself, but I realize I need some help with it.
@Sharpman
Can you please send me the code change you made in your update? If you can, please submit it as a pull request on GitHub. That's the easiest way to get it to me.
Hi, because LRFLEW not responding.. and this bug was so anoying.
I repaired his eShop
Here is Download:
Btw: For blocks with meta values.. You have to set even 0 meta value.
ex:
35 0 2 1 this must be set with meta 0
35 1 2 1 here is meta 1
35 2 2 1 here is meta 2
35 3 2 1 here is meta 3
@LRFLEW:
Still here is bug with prices and metadata:
If you have block price with metadata in item.price.txt
ex:
35 0 0.2 0.1
35 1 0.4 0.2
And you try to buy /shop buy 35:0 1 It will cost you 0.4 not 0.2..
If you try to buy /shop sell 35:0 1 It will give you 0.2 not 0.1..
The last metadata overwrite the buying and selling price for whole one ID..
Please just update this thing. There are no necessary new features.. just bug fix ;)
Thanks :)
@iMineing
Its should be:
40 0 100
42 0 25
57 0 400
351 4 0 12.5
etc ;)
I cant get the right price. It keeps saying "error on line 1, price not an integer" (Not exact quote) but its annoying even when i do it right
my file:
@LRFLEW
Hey i just wanted to say im running a 1.4.5 R0.3 snapshot and this plugin makes my players very happy! it works perfectly, a bit laggy at times when people attempt to use the signs too fast, but i solved it by changing the sign usage to 3 per second in essentials and it works fine! thanks you so much for this plugin! i look forward to its continued development!
@briandmk99
Yeah... I'm working on that. I'm completely rewriting it to work with Vault, but it's taking some time, and I don't have a lot of free time to commit to it :(
This plugin does not work at all.
@arkan01d
Oh, I see the issue. I'm working on revamping the whole system soon, but for now, it would be /shop buy 35:14 64
Hope that helps
@arkan01d
To simplify what I said, bc the way I wrote it was a little confusing: How do you set prices for objects that have different meta-values? Like wool and dye have a sub value that defines the colors. Also, how do you buy / sell those items in-game.
I can give myself 64 red wool with '/give <name> 35 64 14' that tells the game I want 64 wool of 14 meta-value. But if I try that with '/shop buy <name> 35 64 14' I get 64 white wool.
how do you configure prices for different wool and dye types? I have a price set for wool as: '35 40 2' but when I try to buy any color: '/shop buy 35 1 3' I only get wool(0).
you need to make default prices for buying and selling.
@Sharpman
Can you submit this as a ticket please. It's hard to figure out what the problem is from the information given.
Hi, i found bug in eShop on CB 1.2.5-R4
If you set something what have data values.. and you set in one of that data values that it can not be bought.. it will disallow you buying anything from the same ID.
EX: 35 1.40 0.40 35 1 0 0.40 35 2 1.40 0.40 35 3 1.40 0.40
No wool can be bought.. just sold.
@LRFLEW
Thank you, your Shop is one that works with things from modes. It's very simple to use without the unnecessary functions.
The only thing that does not work is buying blocks with ID greater than 255. (4096 ID BLOCK FIX)
But I suppose that most people will not use this option.
Thanks for your work.