[INACTIVE][ECON] SignShop v1.1 - Commandless Multi-World Player Owned Shops [860] iConomy

Discussion in 'Inactive/Unsupported Plugins' started by Ne0nx3r0, May 3, 2011.

  1. Offline

    Ne0nx3r0

    Development on this plugin has stopped.
    [​IMG]
    Commandless Player Owned Shops
    Current Version:​
    v1.1 [860] June 19th, 2011

    *Requires iConomy (v5.0)​

    Some notes about upgrading from < 1.0:
    1. config.yml is the new messages.yml, you can delete messages.yml
    2. BACK UP YOUR sellers.yml BEFORE MAKING ANY CHANGES OR UPDATING (sorry, wanted to make that clear.)
    Create signs to sell goods from a chest you specify; allow your players to setup and run their own shops!

    Supported Signs:
    Supported Signs (open)

    [Buy] - Buys an item fro the shop chest for the price specified on the 4th line
    [Sell] - Sells an item to the shop chest for the price specified on the 4th line
    [Donate] - Gives an item to the shop chest
    [Slot] - Gives a random item from the selected chest items (not the entire inventory) to the player
    [DeviceOn] - Turns a lever on
    [DeviceOff] - Turns a lever off
    [DeviceToggle] - Toggles a lever
    [Device] - Temporarily turns on a lever
    *[gBuy] - Buys an item from the shop, but the owner receives no money
    *[gSell] - Sells an item to the shop, and the player receives money, but not from the owner.
    *[iBuy] - Buy an item from the "shop", but really the item is created from scratch whether the shop has it in stock or not.
    *[iSell] - Sells an item to the "shop", but really the item just disappears.
    *[Day] - Turns the time to day
    *[Night] - Turns the time to night
    *[Rain] - Turns on rain + thunder
    *[ClearSkies] - Turns off rain + thunder
    *[Repair] - Repairs the current item
    *[Heal] - Fully heals the player

    *Must be OP/SignShop.Admin to create

    Usage:
    Usage (open)


    1. Create a sign. Line 1 needs to be [Buy] (or whatever type of sign). Line 4 needs to be the price (aka 50, 50.25) of your item(s). lines 2&3 can describe your item(s), or be blank.
    2. While holding redstone, click on the sign. (you should get a message)
    3. Find a chest you want to use as your storage, put ONLY the items you want the sign to sell in it. For example, if you have a stack of 64 Cobblestone and want to sell two at a time, put only two in the chest.
    4. Click on the chest with redstone. (you should get a message)
    5. Put all of your cobblestone in the chest
    6. Now players can click on your sign (no redstone needed), purchase the cobbletone two at a time! (right click to buy without confirmation dialog)
    Note - One chest can maintain multiple signs, just take everything out and set the new sign up, then put all the items for both signs in so the shop has something to sell.

    Permissions Nodes:
    Permissions Nodes (open)

    • SignShop.Signs.*
    • SignShop.Admin.*

    Changelog:
    Version 1.1
    • Bug fix - creates the plugin directory if needed.
    Changelog (open)
    Version 1.1
    • Bug fix - creates the plugin directory if needed.
    Version 1.0
    • Added localization, scheduled saving, custom signs, better localized logging, backing up of sellers.yml, proof of god, etc.
    Version 0.7.2
    • Lost to the world
    Version 0.7.1
    • Bug fix for iSell/iBuy signs
    Version 0.7
    • Added a small gaggle of new sign operations, small bug fixes. updated messages.yml
    Version 0.6.1
    • Moved gBuy/gSell to OP/Admin operations, as gBuy is exploitable.
    Version 0.6
    • Added gBuy/gSell signs, renamed config.yml to messages.yml
    Version 0.5.4
    • Bug fix for slot shops
    Version 0.5.3
    • Bug fix, added check/msg for missing chests
    Version 0.5.2
    • Bug/exploit fix - cancels event if the user does't have enough items
    Version 0.5.1
    • Bug fix for signs clicked with less than 3 characters
    Version 0.5
    • Added Permissions support, added configurable messages, added [Redstone] sign. Set plugin to respect events being cancelled. Various bug fixes and code maintenance.
    Version 0.4.2
    • Bug fix with confirmation messages showing the owners name instead of the players name
    Version 0.4.1
    • Bug fix with [Sell] signs paying shop owners
    Version 0.4
    • iConomy 5.0 support, also added Sell, Donate, Slot, iBuy, iSell signs
    Version 0.3.1
    • Bug fix
    Version 0.3
    • iConomy 5.0 compatibility, also signs now need [Buy] to be the first line. (Making room for [Sell], [Donate] signs)
    Version 0.2
    • Added yml persistence
    Version 0.1
    • Initial release

    Known Issues:
    • Conflicts with Essentials; disable signs in the essentials config before adding this plugin.
    Coming soon:
    • Extra storage (still working on it... infinite storage would be better, and might be possible ;))
    Donations:
    • I develop this plugin because I enjoy it and want to give back to this community; however if you are interested in supporting it's future I gladly accept donations via PayPal, and BitCoin.
    Do you like this plugin? Click like so I know! ; )
     
  2. Offline

    Ne0nx3r0

    I'll address this in the next update; so far testing seems good. If a protection plugin stops a player from using a chest, it wont complete the setup.

    @Hamsta @nbirk94 @Gamuh @Ghkj2 @Racha

    Added permissions support in v0.5. (Some other things too)

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
  3. Offline

    Racha

    Tnx, but does it work on #766?
     
  4. Offline

    Ne0nx3r0

    I don't see why it wouldn't, but you'll need to test that with your plugins to be sure.
     
  5. Offline

    Tealk

    Server:
    http://pastebin.com/BwL48UBE

    I become the error:
    Code:
    2011-05-23 16:35:49 [SEVERE] Could not pass event PLAYER_INTERACT to SignShop
    java.lang.StringIndexOutOfBoundsException: String index out of range: -2
        at java.lang.String.substring(String.java:1937)
        at Ne0nx3r0.SignShop.SignShopPlayerListener.getOperation(SignShopPlayerListener.java:56)
        at Ne0nx3r0.SignShop.SignShopPlayerListener.onPlayerInteract(SignShopPlayerListener.java:263)
        at org.bukkit.plugin.java.JavaPluginLoader$9.execute(JavaPluginLoader.java:299)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:310)
        at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:162)
        at net.minecraft.server.ItemInWorldManager.interact(ItemInWorldManager.java:207)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:535)
        at net.minecraft.server.Packet15Place.a(SourceFile:57)
        at net.minecraft.server.NetworkManager.a(NetworkManager.java:196)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:100)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:377)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:292)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:394)
     
  6. Offline

    Ne0nx3r0

    Should be fixed in v0.5.1, download a fresh copy - thanks!
     
  7. Offline

    KillingSpread!

    Getting a error each time i try to buy something from a sign (after the setup part)

    my plugin list is
    -AssignPermission
    -Minequest
    -WorldEdit
    -WorldGuard
    -Permissions
    -IConomy
    -Magic Carpet
    -Sign Shop
    -Fall Protect

    Using bukkit 733
     
  8. Offline

    Pand3micc

    Got it running, but I am curious. What happens if someone buys from my shop when I am not online the server?

    Will i get a message when I come on that someone bought? Or do I just silently get the money without knowing.
     
  9. Offline

    Hyphe

    Can you make a permission node like SignShop.make so player with only that permission can make SignShop? Maybe when players doesn't have the permission to make one, the sign pops back out?

    I don't want to use ChestShop :(
     
  10. Offline

    Ziqh

    Great plugin, working great on my server thus far, just a couple of notes:

    Item trading would be very useful with this plugin, especially if it took all the functions of the old SignTrader plugin. Maybe a trade sign could be [Trade] on the first line, description second and third, and an ID with an amount as the fourth, which is the item and quantity it will take instead of money.
    Even better, if this could be done with the same chest system, and the fourth line left for a money cost, trade charges could be implamented.

    One other note, when you have a shop set up, and a linked chest is removed without a block break event (by removing with a superpick for example), clicking the sign crashes the server. A quick error check would be great on that.

    Thanks!
     
  11. Offline

    ScorchRaserik

    Found a VERY exploitable bug. Blocks (including other signs) can be placed on the shop signs. As shown in this video, this can lead to people getting infinite items and/or money with just a bit of time:
    http://www.youtube.com/watch?v=y4z5_kVYOps


    All you have to do is right click on a sign with enough room to place a block in the space of air in front of the sign. If you don't have the required amount of blocks (in this example, 64 pieces of gravel), it will place the gravel and tell you that you don't have enough to sell, but it won't deduct a piece from your inventory. You can then break the gravel and add to your stack until you DO have 64 pieces, which allows you to sell the stack. This works for any placeable block, including signs and maybe torches (but i didn't actually test torches).
     
  12. Offline

    Ne0nx3r0

    Thanks for the heads up, should be fixed in v0.5.2

    I'm surprised it -crashed- the server, but errors I could see. This should be fixed in v0.5.3; it's also worthwhile to note that the plugin removes any invalid signs with every server restart.

    That's essentially what the nodes are; anyone can use a sign, the nodes are setup to say who can create them.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
  13. Offline

    Hyphe

    Thank you kind sir.
     
  14. Offline

    Pand3micc

    and this?

    sorry for the bump, my question just seems to have been missed :S
     
  15. Offline

    Ne0nx3r0

    @Pand3micc Sorry, it will only message you if you are online at the time... At some point I might look at setting up some sort of messaging system, but for now you will just get the money in your account with no confirmation if you aren't on at the time.
     
  16. Offline

    Pand3micc

    @ne0nx3r0 Ah, well that's better then not getting the money :p

    Feature suggestion: There should be a way to set up a sign and chest that functions normally, but when someone buys an item, the money gets payed to nobody, and when someone sells an item, the money payed to that person comes from nowhere, kind of like BetterShop, but with realistic item stocks.

    I have already done this by temporarily setting my server to offline mode and going on a fake account called "TheBank"

    Then setting up the chests bla bla bla...

    But that feature would be nice
     
  17. Offline

    ephesian

    I cant get the admin sell and buy, i am a op but i cant sell how do i write out the sign?
     
  18. Offline

    filthyklean

    The [slot] sign doesn't seem to remove the item from inside the chest? Even when the item is removed manually it still continues to seem to give you another of that item. Unsure if this happens with more than one type of item within the chest.
     
  19. Offline

    Ne0nx3r0

    This should be fixed in 0.5.4

    Take a look at the "ghost" gBuy/gSell OP/Admin only signs I've added in 0.6.

    Lines:
    [Buy]
    <whatever>
    <whatever>
    10.0

    Then make sure you are using redstone on the sign and the chest.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
  20. Offline

    ephesian

    Take a look at the "ghost" gBuy/gSell OP/Admin only signs I've added in 0.6. for it to "sell pr buy to server" ?
     
  21. Offline

    Jaspah

    Nice plugin! I have two requests:

    • Change the color of the sign type ([Buy], [Sell], etc.) to something else. Some of my players tend to associate colored text on signs with them being interactive.
    • Automatically attach a currency suffix to the price of the item. For example, if my currency is set to "Dollars" in iConomy, the price I write on the fourth line will be changed to "## Dollars". If it was Coins, it would be "## Coins" and so forth.
     
  22. Offline

    Sazaraki

    I'm getting this error when starting the server:

    2011-05-26 18:04:52 [SEVERE] Error occurred while enabling SignShop v0.6.0 (Is it up to date?): For input string: "NewWorld"
    java.lang.NumberFormatException: For input string: "NewWorld"
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
    at java.lang.Integer.parseInt(Integer.java:481)
    at java.lang.Integer.parseInt(Integer.java:514)
    at Ne0nx3r0.SignShop.Storage.Load(Storage.java:47)
    at Ne0nx3r0.SignShop.Storage.<init>(Storage.java:22)
    at Ne0nx3r0.SignShop.SignShop.onEnable(SignShop.java:53)
    at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:125)
    at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:750)
    at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:253)
    at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:132)
    at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:110)
    at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:218)
    at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:205)
    at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:145)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:265)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:394)

    I think this started happening when I updated to the latest build for Bukkit. It also throws an error when I try to click a sign.
     
  23. Offline

    Pand3micc

    Broken in the latest test build for 1.6.4

    Code:
    2011-05-26 20:24:22 [SEVERE] Could not pass event PLAYER_INTERACT to SignShop
    java.lang.IllegalArgumentException: Listener already listening
        at net.minecraft.server.Container.a(SourceFile:28)
        at net.minecraft.server.EntityPlayer.syncInventory(EntityPlayer.java:70)
        at org.bukkit.craftbukkit.entity.CraftPlayer.updateInventory(CraftPlayer.java:217)
        at Ne0nx3r0.SignShop.SignShopPlayerListener.onPlayerInteract(SignShopPlayerListener.java:503)
        at org.bukkit.plugin.java.JavaPluginLoader$9.execute(JavaPluginLoader.java:299)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:310)
        at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:162)
        at net.minecraft.server.ItemInWorldManager.interact(ItemInWorldManager.java:209)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:544)
        at net.minecraft.server.Packet15Place.a(SourceFile:57)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:214)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:396)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:308)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
     
  24. Offline

    Ne0nx3r0

    Since I'm on vacation until Sunday, and there's no RB for Bukkit using 1.6 I'm waiting to update this. I'll take a look at night before bed each night and see if there's a recommended build for 1.6. So give it a few days and I should have an update.
     
  25. Offline

    filthyklean

    Another bug, When selling an item, if a player is holding the block they are selling, and right clicks the sign to sell, it places the block, gives them the money and places a duplicate in the chest, leaving the placed block able to be regathered.

    Great plugin by the way, my players are loving it :D
     
  26. Offline

    CoolJosh3k

    I've come here after looking at quite a few Shop plugins. This one so far has the most potential.

    My biggest question though; does it handle damage values, such as coloured wool? Would green wool, for example, stay green or turn white when bought/sold?

    Might I suggest some short tutorial vids? One for setting up a simple single-sign-single-chest, another for advanced multi-sign-single-chest, and of course a third for players making use of the shop.
     
    skech1080 likes this.
  27. Offline

    Tealk

    Bukkit:814 MC:1.6.4


    I become this Error:
    Code:
    2011-05-27 13:45:17 [SEVERE] Could not pass event PLAYER_INTERACT to SignShop
    java.lang.IllegalArgumentException: Listener already listening
        at net.minecraft.server.Container.a(SourceFile:28)
        at net.minecraft.server.EntityPlayer.syncInventory(EntityPlayer.java:70)
        at org.bukkit.craftbukkit.entity.CraftPlayer.updateInventory(CraftPlayer.java:217)
        at Ne0nx3r0.SignShop.SignShopPlayerListener.onPlayerInteract(SignShopPlayerListener.java:503)
        at org.bukkit.plugin.java.JavaPluginLoader$9.execute(JavaPluginLoader.java:299)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:310)
        at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:162)
        at net.minecraft.server.ItemInWorldManager.interact(ItemInWorldManager.java:209)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:544)
        at net.minecraft.server.Packet15Place.a(SourceFile:57)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:214)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:396)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:308)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
     
  28. Offline

    Sazaraki

    It does work for different colored wool, saplings, etc
     
  29. Offline

    CoolJosh3k

    Wonderful.

    Now I just need to find some good vids of how to set it up and how to use it.
     
  30. Offline

    Q3nz0

    I have a problem, the permissions is kinda stupid. WHen i have the - '*' i cant use [Buy] but [iBuy], any suggestions to fix it? Wanna have the possibility to trade like normal players :)
     
  31. Offline

    Sazaraki

    Once it works again for me I'll make A video :D
     

Share This Page