[ECON] ChestShop 3.7.18 (iConomyChestShop) - Chest&sign shop for economy plugins [1.8]

Discussion in 'Archived: Plugin Releases' started by Acrobot, Feb 12, 2011.

  1. Offline

    Acrobot

    An easy way to create shops - no protection plugin needed!
    You don't need to be on-line to earn money anymore!
    [​IMG]
    I've put a LOT of effort into making this plugin,
    you can donate if you appreciate my effort =)

    Requirements:
    - An economy plugin supported by Register or Vault, for example iConomy, BOSEconomy or Essentials Eco.
    Optional:
    - For additional economy plugin support - Vault
    - For Permissions: bPermissions, PEX, or any other permission plugin
    - For additional protection: LWC, Lockette, Deadbolt
    - For other item names (aliases): OddItem


    Setup:
    Copy the .jar file from the .zip you downloaded into /plugins folder.
    You can also copy the example files if you want to generate statistics page.

    Translations:
    You can change the plugin's language, here's a list of all user-made translations.
    If you want to update or submit a translation, feel free to PM me.
    Translations (open)

    Arabic - Attarhsase2
    Bulgarian - Muff1Ncho
    Czech - LordPgsa
    Chinese (Simplified) - tab415263
    Danish - Cannafix
    Dutch - speedlegs
    French- DragonSlayer875
    German - RasCas
    Hungarian - Anachen
    Indonesian - Yahya98
    Italian - Massimo1993
    Korean - Zwing87
    Norwegian - _AlexN_ and TheUnkownGamer
    Polish - Holls1
    Portugese (Brasil) - FelipeMarques14
    Russian - VADemon from http://minemania.ru/
    Slovak - LordPgsa
    Slovenian - jEErc
    Spanish - thxaaaa
    Swedish - Maxell
    Turkish - Developer
    Traditional Chinese - hellboyincs
    Vietnamese - etrubi1 from http://minevn.com/


    Permissions:
    How to create a ChestShop?
    - Place a chest, if you haven't already.
    - Place a sign 1 block near the chest (for example, above the chest)
    - On the sign, write:

    [​IMG]
    (Item name can actually be item ID or alias)
    First line will be filled in by the plugin automatically.
    Price is a combination of buy and sell price.
    You have to have B near buy price (people buy from you), and S near sell price (people sell to you).
    If you have both B and S, separate them with a colon - :
    For example:
    [​IMG]

    means that AcrobotPL wants to sell 64 diamonds for 10 currency, and buy them back from you for 5 currency.
    Also, if you put "free" instead of price, it is free to buy or sell :)

    - Now, when you finish editing the sign, if LWC is turned on in config, shop will be automatically created.
    Also, if your default protection is turned on in the config, people won't be able to break chest, sign or the block the sign is on.

    What is an Admin Shop?
    Admin shop is the shop that doesn't require a chest, because it has infinite stock.
    If you sell to it, the items will disappear, and if you buy from it, items will magically appear.
    To create one, you have to be Admin/OP. Just put "Admin Shop" (or anything specified in config file) on the first line of the sign.

    Restricting shops to some groups or regions
    You can either use permissions, or you can just put a sign ABOVE shop sign (you need to be in that group to create the sign) to restrict it to players with ChestShop.group.groupName permission
    The syntax is:
    [restricted]
    firstGroupName
    2ndGroupName
    3rdGroupName
    Only those groups will be able to use that shop

    To restrict a shop to some regions:
    - If you're using Towny, turn TOWNY_INTEGRATION on. Residents will be able to create shops in economy plots (either their or, if specified in config, any)
    - If you're using WorldGuard, you can use an experimental "chestshop" flag. Turn WORLDGUARD_INTEGRATION on and flag a region. (f.e. /region flag ChestShopRegion chestshop allow)

    Do you want to limit the maximum prices for items?
    Well, there's an app.... wait, not that : P
    You can use an experimental feature in ChestShop.
    In your config.yml, add lines like:
    max-buy-price-5: 14
    max-sell-price-5: 15

    That means that the maximum price for items BOUGHT by PLAYER is 14, and items SOLD by PLAYER using the shop is 15.

    You can also use a global setting, like this:
    max-sell-price: 200

    That means that the maximum price for items SOLD to PLAYER is 200 (if there is, for example, a max-sell-price-5 found, it will be used instead of the global sell price)

    USING SHOPS
    You could buy and sell by right and left clicking the sign for a long time.
    Now it's the only way to use the shops.
    It's SIMPLE!
    Just LEFT-CLICK to SELL to shop, and
    RIGHT-CLICK to BUY from shop.
    (This can be changed in the config file)

    DESTROYING SHOPS
    If you want to delete your old shop, simply SNEAK and destroy the sign.
    It's that easy =)

    STOCKING THE SHOPS
    You can either open the chest and stock it up, or click on your own sign - it will open chest's inventory (that way you can have chests not openable by other people for sure :D)

    ItemInfo command
    It's a simple command that shows item information.
    If you use it without any arguments, it shows you information about the item you're holding.
    If you specify item id or item name after the command, it will show you information about that item.

    Source code
    ChestShop is Open-Source =)
    You can find its code on https://github.com/Acrobot/ChestShop-3


    Thanks to:
    - kali876, ziomekYOYO and Herocraft server for testing the plugin and finding every little bug =)
    - Everyone who uses this plugin - really big thanks for this, I never thought it will be so popular
    - Everyone who provided translation - many people's lives will be easier now
    - @Nijikokun for Register
    - @LennardF1989 for awesome Persistence Reimplemented
    - @Temaska for fixing the plugin while I was on holidays
    - @VADemon for providing a great support for other users
    - @Euthyphro for his patience and really good bug spotting
    - vagrant326 for making a great price sheet
    - Epics for his great help
    :)
    If something's not working
    You can't change the sign color - that breaks the formatting.
    If that's not the issue, please give me this information, so I can help you faster.
    - CraftBukkit version (type /version in chat)
    - ChestShop version (type /csversion in chat)
    - Your economy plugin (iConomy? BOSEconomy? other one?)
    - Have you got any Permission plugin? Which one?

    [​IMG]
    Changelog (open)

    Changelog can be found on BukkitDev - http://dev.bukkit.org/server-mods/chestshop/files/
     
  2. Offline

    chaseoes

    I'm totally stealing that line for when I give support!
     
    Acrobot likes this.
  3. Offline

    Acrobot

    Makan747
    Unfortunately, cannot reproduce. Mind PMing me your server's IP?
     
  4. Offline

    Makan747


    mc.tankafetast.com
     
  5. Offline

    Mortalsinn

    getting this with test build #0026 and the latest beta bukkit build

    Code:
    2012-11-22 19:21:59 [SEVERE] Could not pass event SignChangeEvent to ChestShop v3.50t0026
    org.bukkit.event.EventException
        at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:341)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
        at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:477)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:462)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:1404)
        at net.minecraft.server.Packet130UpdateSign.handle(SourceFile:46)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:290)
        at net.minecraft.server.NetServerHandler.d(NetServerHandler.java:113)
        at net.minecraft.server.ServerConnection.b(SourceFile:39)
        at net.minecraft.server.DedicatedServerConnection.b(SourceFile:30)
        at net.minecraft.server.MinecraftServer.r(MinecraftServer.java:595)
        at net.minecraft.server.DedicatedServer.r(DedicatedServer.java:222)
        at net.minecraft.server.MinecraftServer.q(MinecraftServer.java:493)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:426)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:856)
    Caused by: java.lang.NullPointerException
        at com.Acrobot.Breeze.Utils.MaterialUtil.equals(MaterialUtil.java:42)
        at com.Acrobot.ChestShop.Listeners.Block.SignChange.formatItemLine(SignChange.java:225)
        at com.Acrobot.ChestShop.Listeners.Block.SignChange.onSignChange(SignChange.java:77)
        at sun.reflect.GeneratedMethodAccessor428.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:339)
        ... 14 more
     
  6. Offline

    Ruan

    Code:
    2012-11-24 14:49:17 [SEVERE] Error occurred while enabling ChestShop v3.50t0030 (Is it up to date?)
    java.lang.RuntimeException: An exception has occured while initializing the database
        at com.lennardf1989.bukkitex.Database.initializeDatabase(Database.java:78)
        at com.Acrobot.ChestShop.ChestShop.setupDB(ChestShop.java:217)
        at com.Acrobot.ChestShop.ChestShop.onEnable(ChestShop.java:80)
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:217)
        at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:374)
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:381)
        at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:298)
        at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:280)
        at net.minecraft.server.MinecraftServer.j(MinecraftServer.java:320)
        at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:299)
        at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:258)
        at net.minecraft.server.DedicatedServer.init(DedicatedServer.java:148)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:398)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:856)
    Caused by: java.lang.NullPointerException
        at com.lennardf1989.bukkitex.Database.replaceDatabaseString(Database.java:235)
        at com.lennardf1989.bukkitex.Database.prepareDatabase(Database.java:89)
        at com.lennardf1989.bukkitex.Database.initializeDatabase(Database.java:70)
        ... 13 more
    
    // Also, database takes FOREVER(an entire minute) to load, even though it's <200kb.
     
  7. Offline

    Acrobot

    Ruan
    Sorry, but I'm not responsible for the database loading - I only use Bukkit's built-in persistence.
    It might be connected to the fail I've committed, though - sorry for that!
     
  8. Offline

    bonebreaker9354



    Still the same bug, the words convert to x128 i use version R: v3.46 for 1.4.2 Jul 07, 2012
     
  9. Offline

    marin1805

    Anyone tested this on 1.4.5 with the bukkit beta release? Any feedback please?
     
  10. Offline

    Acrobot

  11. Offline

    marin1805

    k thanks for feedback. I'll give it a try.
     
  12. Offline

    cleopix

    Nice to hear it works with 1.4.5, it's a good plugin, I need it badly for my server.
     
  13. Offline

    bonebreaker9354

    bonebreaker9354
    And the TEST VERSION?[/quote]
    Same still turns it into x128
     
  14. Offline

    Acrobot

    bonebreaker9354
    Ok, I'll test it, please report it on dev.bukkit.org in "tickets" section :D
     
  15. Offline

    jojoran12

    Does it work for minecraft 1.4.5?
     
  16. Offline

    bonebreaker9354

    yes
     
  17. Offline

    indi689

    Hello, installed Beta Build (1.4.5-R0.1 build # 2483), except ChestShop (3.5 2012/11/30), PermissionsEx (1.19.4) and Modifyworld (1.19.4) does not cost anything.

    permissions.yml

    groups:
    default:
    default: true
    permissions:
    - ChestShop.shop. *
    - Modifyworld. *
    Admin:
    permissions:
    - ChestShop. *
    - '*'
    users:
    indi689:
    group:
    - Admin

    constantly jumps a message "you can't buy here"
    Written on the plate
    Admin Shop
    64
    B 0:0 S
    Stone

    What am I doing wrong?
     
  18. Offline

    Acrobot

    indi689
    Sorry, but unfortunately, due to the standards of the past, 0 means "no selling, buying". If you want to make a free shop, put "free" there, instead of zeros.
     
  19. Offline

    Enter

    For people having problems with tools and whatnot, it works with ID's of the item, not the names of them.
    If I for example want to create an admin shop selling diamonds for... 200 dollar/gold/whatever currency you got, you do this:

    Admin Shop // This is the name of the shop.
    1 // This is the amount you will buy.
    200 // This is the amount it costs.
    264 // This is the ID of the diamond.

    To find out ID's of items, simply check this page out.
     
  20. Offline

    indi689

  21. Offline

    Acrobot

    Enter
    Hm?
    It works with the names just as well.

    indi689
    No problem :)
     
  22. Offline

    Enter

    Enter By just reading through the comments, it didn't seem to work for others to use names. I however only use ID's as I find it a lot simpler. No confusions. :)
     
  23. Offline

    Acrobot

    Enter
    Hah :D
    Only the first pages (from February 2011) say that :)

    Yeah, I had a problem with item names - mainly Gold and Gold Slabs, because it tended to always choose the longer one :D Of course, this has been fixed for a long time :)
     
  24. Offline

    Enter

    Ah I see. :p Sorry for the misunderstanding in that case. Great mod however, works great.
     
  25. Offline

    Togakure321

    guys i have a... slight issue with the admin shops... It seems players with nothing in their inventory can sell anything at any price i put. so say my admin shop buys 64 wheat at 150... they can have no wheat and sell for 150 each time.. this glitch has made my admin shop kind of null and void lol :p anyway you guys can fix that?
     
  26. Offline

    Acrobot

    Togakure321
    Are you using BOSEconomy?

    Use the ChestShop test version then, or just use Vault :)
     
  27. Offline

    Togakure321

    using essentials economy atm
     
  28. Offline

    Togakure321

    Hey guys i've updated to the highest version of chest shop... i tried a previous version as well this glitch still happens where people can sell and obtain money while no items are in their inventory aka (selling 64 wheat for 150 and having no wheat to sell) this is the Spam error i keep getting each transaction any help you can give would be excellent thank you! i got this with and without boseconomy
    15:36:17 [SEVERE] Could not pass event PreTransactionEvent to ChestShop v3.50t00
    35
    org.bukkit.event.EventException
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:341)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.jav
    a:62)
    at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.j
    ava:477)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.j
    ava:462)
    at com.Acrobot.ChestShop.Listeners.Player.PlayerInteract.onPlayerInterac
    t(PlayerInteract.java:90)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:339)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.jav
    a:62)
    at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.j
    ava:477)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.j
    ava:462)
    at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEven
    t(CraftEventFactory.java:177)
    at net.minecraft.server.ItemInWorldManager.dig(ItemInWorldManager.java:1
    14)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:555)
    at net.minecraft.server.Packet14BlockDig.handle(SourceFile:46)
    at net.minecraft.server.NetworkManager.b(NetworkManager.java:290)
    at net.minecraft.server.NetServerHandler.d(NetServerHandler.java:113)
    at net.minecraft.server.ServerConnection.b(SourceFile:39)
    at net.minecraft.server.DedicatedServerConnection.b(SourceFile:30)
    at net.minecraft.server.MinecraftServer.r(MinecraftServer.java:595)
    at net.minecraft.server.DedicatedServer.r(DedicatedServer.java:222)
    at net.minecraft.server.MinecraftServer.q(MinecraftServer.java:493)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:426)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:856)
    Caused by: java.lang.NullPointerException
    at com.Acrobot.ChestShop.Economy.Register.balance(Register.java:32)
    at com.Acrobot.ChestShop.Economy.Economy.getBalance(Economy.java:81)
    at com.Acrobot.ChestShop.Listeners.PreTransaction.PartialTransactionModu
    le.onPreSellTransaction(PartialTransactionModule.java:78)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:339)
    ... 25 more
    15:36:17 [INFO] [ChestShop] Togakure sold 1 Boat for 50.00 to Admin Shop at [wor
    ld] -22, 72, 206
    15:36:18 [SEVERE] Could not pass event PreTransactionEvent to ChestShop v3.50t00
    35
    org.bukkit.event.EventException
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:341)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.jav
    a:62)
    at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.j
    ava:477)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.j
    ava:462)
    at com.Acrobot.ChestShop.Listeners.Player.PlayerInteract.onPlayerInterac
    t(PlayerInteract.java:90)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:339)
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.jav
    a:62)
    at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.j
    ava:477)
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.j
    ava:462)
    at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEven
    t(CraftEventFactory.java:177)
    at net.minecraft.server.ItemInWorldManager.dig(ItemInWorldManager.java:1
    14)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:555)
    at net.minecraft.server.Packet14BlockDig.handle(SourceFile:46)
    at net.minecraft.server.NetworkManager.b(NetworkManager.java:290)
    at net.minecraft.server.NetServerHandler.d(NetServerHandler.java:113)
    at net.minecraft.server.ServerConnection.b(SourceFile:39)
    at net.minecraft.server.DedicatedServerConnection.b(SourceFile:30)
    at net.minecraft.server.MinecraftServer.r(MinecraftServer.java:595)
    at net.minecraft.server.DedicatedServer.r(DedicatedServer.java:222)
    at net.minecraft.server.MinecraftServer.q(MinecraftServer.java:493)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:426)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:856)
    Caused by: java.lang.NullPointerException
    at com.Acrobot.ChestShop.Economy.Register.balance(Register.java:32)
    at com.Acrobot.ChestShop.Economy.Economy.getBalance(Economy.java:81)
    at com.Acrobot.ChestShop.Listeners.PreTransaction.PartialTransactionModu
    le.onPreSellTransaction(PartialTransactionModule.java:78)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.ja
    va:339)
    ... 25 more
    15:36:18 [INFO] [ChestShop] Togakure sold 1 Boat for 50.00 to Admin Shop at [wor
    ld] -22, 72, 206
     
  29. Offline

    Acrobot

    Togakure321
    Hey, if you're using Essentials Eco, you should use Vault :)
     
  30. Offline

    Togakure321

    awesome acrobot! errors are gone still has this weird "you bought %amount 32 redstone from Admin shop for 500$
     
  31. Offline

    Acrobot

    Togakure321
    As the huge red text says at the beginning of the main post, you have to remove the %amount from your local.yml file
     

Share This Page