Inactive [MECH/ECON] Showcase v0.8.1 - Create visual shops by spawning drops on slabs [1.1-R5]

Discussion in 'Inactive/Unsupported Plugins' started by narrowtux, May 17, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    narrowtux

    [​IMG]
    Version 0.8.1​
    As supposed in this thread, I created a plugin that lets you put items into glass blocks (now steps, it's notchs fault) to showcase them. This is useable for shops, to show what's for sale there, or to make clear what type of farm you built.
    Features
    • Showcase all items in a half-step Block
    • Block protection (you can't break the step block and the block below it to prevent that the item falls down)
    • Multiworld
    • Items in a showcase can't be picked up
    • Only the player who created a showcase can remove it
    • Prevents despawning of items (Normally, drops disappear after 5 minutes)
    • You can setup finite and infinite shops
    • DropChest support (disables DropChest for absorbing the showcased items)
    • WorldGuard support (works out of the box)
    • Localisation
    • Can show custom item names through BukkitContrib
    • Economy support:
      • iConomy 4 & 5
      • BOSEconomy
      • Essentials Economy
    Download & Source-Code
    Download Showcase.jar
    Browse Source-Code on Github
    You will need an economy system if you want shops.
    This will install NarrowtuxLib automatically!
    Please donate, if you really like this ;)
    Videos
    Show Videos (open)





    When you have got issues, please read this:
    Issue Report (open)

    1. Please, first check if you have got the most recent version of Showcase and the most recent recommended build of Bukkit.
    2. Then, check if the bug is already listed in the "Known Bugs" section.
    3. After doing step 1+2, report the bug with at least this information:
      • Version of Showcase
      • Version of Bukkit
      • If possible, a step-by-step explanation of the bug
      • If possible, console errors
      • When you think that this has got to do with another plugin, please list all your plugins like this:
        • PluginA, PluginB, PluginC ...
    This will be incredible helpful for me to fix it faster.


    You don't actually have to retype everything I typed here, but if you'd take it as a guideline which content you should include in your issue report, it's more helpful ;)

    Please, don't come here just to say "This doesn't work.". This says nothing.


    Usage
    Adding a showcase
    1. Start sneaking!
    2. Right-click a half-step block with the item in your hand you want to showcase
    3. An assistant will ask you which type of Showcase you want to add. Type the text before the colon :))
    4. Depending on the type you chose, the assistant will ask some extra questions, follow the assistant to finish showcase creation.
    Removing a showcase

    1. Sneak
    2. Right-click on a showcase. If this was a finite showcase or an exchange showcase, you will get your items back.
    Permissions


    ActionPermission-NodeWithout Permissions
    Create a basic Showcase.showcase.basicPlayer
    Create a infinite shop Showcase.showcase.infiniteOperator
    Create a finite shop Showcase.showcase.finitePlayer
    Create an exchange Showcase.showcase.exchangePlayer
    Buy from a finite shop showcase.showcase.buy.finitePlayer
    Buy from an infinite shop showcase.showcase.buy.infinitePlayer
    Removing a showcase of other players.showcase.adminOperator

    The column "Without Permissions" explains which user-type can use this permission when no Permissions system is installed.
    What are shop showcases?
    A shop showcase can be used to sell items to your players. There are 2 types of shops now:
    1. Infinite shop. This one has an infinite amount of items. The money that the players give to buy an item will go to nirvana
    2. Finite shop. This one has that number of items which the owner has set up. The owner will get the money from which the items were bought.
    How can a Player buy items from a shop showcase?

    1. Click on the Showcase. The price per item and the available amount will be displayed.
    2. Type in the number of items you want and hit enter. A message will show you the success of the checkout.
      • Type 0 to abort checkout
    How can you refill a finite shop showcase?

    1. Click on it
    2. Type in the amount of items to refill. Negative values will remove that amount from the showcase.
    3. Walk away or type 0.
    Commands

    The showcase command handles manual saving and loading
    /showcase save
    Saves the items to showcases.csv
    /showcase load
    Loads the configuration, translation and items without saving (Use with caution)
    /showcase reload
    Saves and loads everything after that. Useful when some items aren't in place and you want to quick-fix that.

    Configuration
    The configuration file is auto-generated and is called showcase.cfg
    Here are the configuration possibilities:
    • basicmode : this decides if the plugin should operate like in version 0.2 or before (Just the basics)
    • priceforbasic : this adds a price to the basic showcases
    • priceforfinite : this adds a price to the finite showcases
    • priceforexchange: this adds a price to the exchange showcases
    • removewhenempty: when set to true, a finite showcase will be removed when it's amount hits 0
    • showcaseprotection : turn this to false to be able to remove showcases from other players (griefers) (you should now use WorldGuard instead of this one ;) )
    • locale: standard is en-US. The german translation which is included in the jar-file is de-DE. If you type that in, it will copy the german file from the jar to your plugins folder
      • You can change the translation very easily by editing the existing locale.
      • Colors are supported, just add something like [GREEN] or [DARK_RED] to the text.
      • You can add newlines with \n
    • autosaveinterval: the time between two auto-saves in seconds. Standard is 60 secs. Use -1 to disable autosave.
    Translations

    Currently available translations:
    Changelog

    Version 0.8.1
    See the whole changelog

    Todo
    • Spawn multiple items in the same glass block (up to 4, would be aligned nicely)
    • Verify that there is no free space below the glass block before adding a showcase
    • Maybe let the showcase glow when you placed torches, glowstone or lava in it
    • Custom messages (aka localisation)
    • Sell-Showcases
    • DropChest support (so the items inside the glass won't be absorbed by a Dropchest)
    • Limit the amount of Showcases per player
    • Add a price that the creator of a showcase has to pay (there would be an independent price for each basic, infinite and finite showcases)
    • Linking infinite shops to banks (money spent for items goes there)
    • Rent a showcase for money/day
    • Autosave with configureable interval
    • Commands for save, load and reload
    Crossed items are already done!

    Known bugs
    • This plugin conflicts with some chat-altering plugins (i.e. bColoredChat) this is because the authors don't know how to correctly set up the priority of events.
    • Normal players (the ones that aren't operators) can't use showcases that are in the spawn-protection area. Either disable the spawn protection or place the showcases to an other location (Disable spawnprotection by setting "spawn-protection-size=0" in the server.properties file)
    • With the latest dev preview (not the recommended build), you're able to make slabs to double steps. I've got to investigate until they propose it as RB.
    • ATM, Showcases won't save enchantments. So please just don't try to sell yours because that wouldn't work either.
     
  2. Offline

    narrowtux

    Seems you don't have any Economy system installed.
     
  3. Offline

    agw97

    I have the Essentials Package?
     
  4. Offline

    narrowtux

    And does your player have an account?
    Some economy systems don't create accounts for new players automatically.
     
  5. Offline

    agw97

    Yes, I think so.
     
  6. Offline

    Enraged

    is the update in work?
    want to update my server to 953 but showcase is not working on my local 953 server :(
    would be nice
     
  7. Offline

    Ratchet

    Code:
    2011-07-03 14:56:58 [INFO] Wrong location! net.minecraft.server.EntityItem@a5
    2011-07-03 14:56:58 [INFO] 890.5,-384.5(55,-25) vs 55,-24
    2011-07-03 14:56:58 [INFO] Wrong location! net.minecraft.server.EntityItem@a6
    2011-07-03 14:56:58 [INFO] 890.5,-384.5(55,-25) vs 55,-24
    2011-07-03 14:56:58 [INFO] Wrong location! net.minecraft.server.EntityItem@a7
    2011-07-03 14:56:58 [INFO] 885.5,-384.5(55,-25) vs 55,-24
    these are due to showcase right? can you suppress them from appearing in the log please?

    thanks
     
  8. Offline

    Trenix

    I like the new exchange part of showcase, however I'm not sure how to exchange one item for multiple items. For example, I want to exchange my iron helmet for 5 redstone, instead of just one.

    Edit: Just realized it has to do with exchange rate. However it doesn't show how to use it, all it says is "Can't find key assistant.exchange.create.rate.text for translation!".
     
  9. Offline

    Enraged

    nice feature would be to let the users sell their items like in iConomyChestShop
     
  10. Offline

    Renagade

    Error when I try buy an Item.

    Code:
    08:07:50 [SEVERE] Could not pass event PLAYER_CHAT to Showcase
    java.lang.NoSuchMethodError: com.nijikokun.register.payment.methods.iCo5$iCoAcc
    unt.<init>(Lcom/iConomy/system/Account;)V
            at com.nijikokun.register.payment.methods.iCo5.getAccount(iCo5.java:47)
            at de.moritzschmale.Showcase.ShowcasePlayer.getAccount(ShowcasePlayer.j
    va:126)
            at de.moritzschmale.Showcase.ShowcasePlayer.canAfford(ShowcasePlayer.ja
    a:89)
            at de.moritzschmale.Showcase.Types.BuyAssistant.onAssistantFinish(BuyAs
    istant.java:66)
            at com.narrowtux.Assistant.Assistant.stop(Assistant.java:169)
            at com.narrowtux.Assistant.Assistant.onPlayerChat(Assistant.java:56)
            at de.moritzschmale.Showcase.ShowcasePlayerListener.onPlayerChat(Showca
    ePlayerListener.java:91)
            at org.bukkit.plugin.java.JavaPluginLoader$6.execute(JavaPluginLoader.j
    va:279)
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.ja
    a:58)
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.
    ava:321)
            at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:681
    
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:669)
            at net.minecraft.server.Packet3Chat.a(Packet3Chat.java:33)
            at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:84)
            at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:451)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    08:08:01 [INFO] [Showcase] Autosaved
    08:08:09 [INFO] <d00money> hiii
    08:08:17 [WARNING] Can't keep up! Did the system time change, or is the server
    verloaded?
    08:08:36 [INFO] /96.126.97.111:33303 lost connection
    08:08:41 [INFO] ?[PLAYER_COMMAND] craftingboy777: /home
    08:09:03 [INFO] d00money lost connection: disconnect.quitting
    08:09:03 [INFO] Connection reset
    08:09:07 [INFO] [Showcase] Autosaved
    
     
  11. Offline

    agw97

    Still have this problem, have the essentials package setup, and its economy package works fine on its own, I seem to have an account etc.
     
  12. Offline

    narrowtux

    Try redownloading iConomy, if that doesn't help, also report this stack-trace to the iConomy thread.
     
  13. Offline

    agw97

    How does this work with Essentials Economy? It doesn't work and you mentioned that I might not have a package installed, however it will work with iConomy, but this messes up my system? Is there a way to get it to work with essentials? :(
     
  14. Offline

    STHedgeHog

    This is a fantastic plugin. Added to my server and shops started poping up everywhere :)
    Ive got two questions, one of which may be a bug or just me missing something.
    Firstly, selling. I see its on the ToDo list and cant wait for it, any news when it might be comming?
    Secondly, I've changed the config to autosave every 600 seconds, but its saving every 60 instead. Is it limited to 2 digits or have I done something wrong?
     
  15. Offline

    vinni96

    when i want to create a new showcase, and i type 'infinite' it says 'enter a price per item' and directly 'showcase creation canceled'
    ??
     
  16. Offline

    narrowtux

    do you have another plugin installed which uses an Assistant?
    Or simply drop a list of your plugins here.
     
  17. Offline

    Kalais

    @narrowtux
    Found a serious issue regarding Showcases with tools/weapons/armor. A person is allowed to sell almost completely broken items with no repercussions.

    Can you add an item "health" bar or have the option to disable the selling of used items?
     
  18. Offline

    CAria

    I've got an issue thats been nagging me.
    Whenever I go to create a showcase, I sneak, click the block and it gives me the selling options as normal. Once I select infinite (the one I use) it says showcase creation cancelled. Showcase is a wonderful plugin that I've used in the past but just of recent it started doing this.

    Help?
     
  19. Hello narrowtux, I have a question. Two days ago a pal told me that he had a look at the showcase code and noticed that the plugin is listing for all events that a player creates instead of the ones that are effectivly needed for showcase. If that should be the case it is a very problematic way to let the plugin run, cos technically a broken showcase plugin could stop the whole server. Also it would waste server ressources without a real need. I havent had a look at the codebase myself yet, but my pal is very familiar with Java so I guess that his info must be based on valid facts.
    Maybe you can verify or falsify that statement?
     
  20. Offline

    narrowtux

    I don't listen to all Player events, just the events that are needed for the Showcase plugin. Theese include Player Interact, Chat, Pickup and Move events. The interact and pickup events are needed for the core, the chat and move events are needed for the chat assistants (which cancel automatically when one walks away).
    There are also 2 events for chunk loading/unloading which are needed to make sure no items are duplicated.
    So you see, every registered event has it's sense, without them, Showcase wouldn't be like what it is now ;)
     
  21. Offline

    Cellybeans

    Showcase Version 0.6.13
    Bukkit RB 953

    Items disappear sometimes if you remove several showcases in rapid succession. Namely diamonds, but it doesn't seem restricted to those. To test after my initial issue, I set up seven slabs side-by-side with multiple layers, like shelves, against the wall. I had to go from top to bottom to prevent the half-blocks from combining into a double step, if that makes it clearer. I set all of them to FINITE shops. I then snuck/rightclicked each one after the other starting from the top left corner across and down. I had two rows of 7, and for every item I got back there was a several second delay from removing the showcase and I received most, but some diamonds and cocoa beans disappeared along with another item or two, can't recall which but that's probably irrelevant.

    also, is there a check for inventory space of the remover? I had a pile of cakes for sale, and after about a four second delay they appeared in my inventory completely filling it, but I didn't get all of them back even after dropping a few.

    I got no error messages whatsoever, and I didn't look through the whole thread but this seems like a pretty significant issue.
     
  22. Offline

    narrowtux

    I plan to drop items that succeed free inventory space in the future.
     
  23. Offline

    vinni96

    when Iwant to create a Infinite or Finite Showcase, the concole says " showcase creation canceled"
    what is wrong??
     
  24. Offline

    narrowtux

    Can you post a list of plugins here?

    And, also when a plugin crashes, others that listen to the same events wont crash. This would be just nonsense.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jul 16, 2016
  25. Well, narrow, as Ive said - I was just asking for clarification! Was not intended as pointing fingers. In case that was misunderstood I apologize. I really like your plugin and love to use it.
     
  26. Offline

    narrowtux

    Ah :D
    I sometimes feel offended when someone says bad things about my code, I should be more open for such critics :D
     
  27. Seriously, Im not wondering that most devs are thronged into a defensive mode when looking at all the crap lots of users leave on this forum.... ;)
     
    narrowtux likes this.
  28. Offline

    STHedgeHog

    In regards to my previous post, I've now set the timer to 3600 and its saving every hours as it should. No idea what the issue was with 600secs (changing it back now works for ten minuets) so it must have just been an odd conflict :)
    There are shops all over the place on my server now selling thousends of items and the only lag i ever get it client side displaying so many things at once. Excelent plugin :D
     
  29. Offline

    narrowtux

    I hope you make backups with so many shops :D
    Maybe you reloaded showcase by /showcase reload, this doesn't change the interval because the timer is still running.

    Sadly, I can't suppress that. Bukkit already hides the full stack trace, because it is irrelevant.

    I'll test it against essentials economy soon, see if I have any issues. If so, I think I could fix it by updating the Register API I'm using.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jul 16, 2016
  30. Offline

    STHedgeHog

    That could well have been it. The server restarts at 4am every morning so that would restart the timer i guess.
    As for backups, i download the whole server once(ish) a week, but i may look into eeing if theres a way to backup the plugins folder more often. jsut need to do it without dynmap, theres alot of files that plugin makes :)

    Im using Essentials Eco and its working fine for me. Do a /balance in game to check you have it all working. If it dosent work or throws an error id say essentials is screwie. Essentials 2.4, anything lower has issues with CB#953

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jul 16, 2016
  31. Offline

    narrowtux

    maybe his essentials is just too old :D
     
Thread Status:
Not open for further replies.

Share This Page