Inactive [MECH] DropChest v0.8.3 - Chests that absorb dropped items [1.1-R3]

Discussion in 'Inactive/Unsupported Plugins' started by narrowtux, Feb 9, 2011.

  1. Offline

    narrowtux

    DropChest - Chests that absorb dropped items
    Version 0.8.2
    [​IMG]
    Important! When migrating from 0.6 to any above version, you have to move the DropChest.txt from server/plugins/DropChest.txt to server/plugins/DropChest/DropChest.txt
    This is because I have to follow the Bukkit plugin saves guidelines.

    This plugin automatically adds dropped items to near chests. That is very useful for automatic farming and monster traps that gather loot.
    Features
    • automatically suck dropped items that are near a chest to that chest
    • customizable warning if the chest is nearly full
    • list your DropChests and watch how much percent is still free
    • Permissions
    • Filter
    • Storage Minecart support
    • Dispenser and Furnace support
    • Item information
    • Chest protection
    • Automatic Owner tracking
    • Double-Chest support
    Download

    DropChest.jar
    GitHub Project (Source Download)
    Download development version

    Donate, if you want to support me ;)

    Video



    Usage
    Commands
    Show commands (open)

    To add a chest to the "watchlist", type
    Code:
    /dropchest add [radius]
    After that, rightclick the chest that you want to add. Radius is the radius in which the Chest should suck items. Default value is 2.

    To remove a chest from the "watchlist", just type
    Code:
    /dropchest remove chestid
    where chestid is the number of the chest that you get when you call /dropchest list

    You can list the chests that are on the watchlist via
    Code:
    /dropchest list
    You can adjust the radius of a chest via
    Code:
    /dropchest setradius chestid radius
    You can check which id and radius the Chest in front of you has:
    Code:
    /dropchest which
    after that, rightclick on the Chest to get information about it.
    If you are sitting in front of the console, or don't want to rightclick, you can use
    Code:
    /dropchest info chest
    It will generate the same output as /dc which.

    You can teleport to a chest via
    Code:
    /dropchest tp chestid
    where chestid is the ID of the dropchest

    You can set the name of a DropChest via
    Code:
    /dropchest setname {chestid} {newname}
    The name is displayed in chest is full warnings, and in the DropChest list!

    If you migrate from 0.6 to 0.7, you can set the owner of a dropchest by typing:
    Code:
    /dropchest setowner {chest} {newowner}
    You can protect a chest by typing
    Code:
    /dropchest protect {chest} {on|off}
    You can always use /dc instead of /dropchest if you are lazy.

    Another very helpful command is /dcitem:
    Code:
    /dcitem [NAME|id]
    
    This can be used to obtain the name of an item by it's id or get an id of the item-name.
    This doesn't work with all names, though.

    Use the new command /chestinfo {name|id} to get info about what's inside the chest.
    Omit the argument and rightclick on any chest to get info about that.
    Example:
    Code:
    >/dcitem 4
    4 is COBBLESTONE
    >/dcitem cobblestone
    COBBLESTONE is 4
    

    Show Configuration (open)

    You can configure DropChest by pasting the contents of the following block to plugins/DropChest/dropchest.cfg
    Code:
    #Should the dropchest drop items when it gets a redstone signal?
    droponredstone=true
    #How long should the dropchest not suck items after it has dropped them
    waitafterdrop=10
    #Should users be able to protect chests like in LWC?
    usercanprotectchest=true
    #Which is the default radius if you omit the radius argument in /dropchest add?
    defaultradius=2
    #Which should be the maximum radius for players that have not dropchest.setBig and aren't ops?
    fallbackradius=15
    #At which fill-status should the chest warn you?
    warnfillstatus=90
    #Which message should appear as warning?
    #You can use this variables (example):
    # $owner : the owner of the chest (narrowtux)
    # $name  : the name of the chest (my superduper mobtower chest/#42)
    # $fill  : The fill status, in percent (81)
    warnmessage=$owner, your chest $name is nearly full($fill%).
    

    Filter / Storage Minecarts
    Show Filter/Storage Minecarts (open)

    Filters have changed in version 0.6. There are now 3 seperate filters that are for sucking items, pulling items from passing minecarts and pushing them to passing minecarts.
    You can now set the filters by either using commands or using the interactive mode. Let me show you the interactive mode first:
    to begin, type
    Code:
    /dropchest filter {suck|push|pull}
    Note: choose one of suck, push or pull, please (for example /dropchest filter suck)
    Then you will enter the interactive mode. In this mode you can edit the selected filter by hitting the chest with the desired item in your hand.
    To edit another filter, type the above command again.
    To finish your filter, type
    Code:
    /dropchest filter finish
    Commands mode:
    Code:
    /dropchest filter {suck|push|pull} {chestid} {itemid|itemtype|clear}
    Call the filter-command like above, as second argument, use the chest-ID, and as third argument, either type the item-ID, the name of the item (as they appear here: org.bukkit.Material) or type clear to clear this filter.
    Please note! The suck filter acts different from the Pull/Push-Filter when it's empty. When the suck-filter is empty, the chest will suck every item. When a Pull/Push filter is empty, it won't take or give any items to a passing minecart.

    Show Permissions nodes (open)

    You can use these nodes:
    • dropchest - To get the right to use DropChest
    • dropchest.create - To call /dropchest add
    • dropchest.remove - To call /dropchest remove chestid
    • dropchest.radius.set - To set the radius of a Chest to something else than 2
    • dropchest.radius.setBig - To have unlimited radius
    • dropchest.which - To have access to the /dropchest which command
    • dropchest.teleport - To be able to teleport via /dropchest tp chestid
    • dropchest.filter - To set or reset filters
    • dropchest.filter.set - To set filters in interactive mode
    • dropchest.filter.reset - To reset filters in interactive mode (click with nothing in hand)
    • dropchest.list - To have access to /dc list and /dc info
    • dropchest.destroy - To be able to break a dropchest without removing it before.
    • dropchest.protect - To be able to protect a chest
    • dropchest.moderator - To be able to modify a dropchests properties even if you're not the owner. Also, ops and the console can do that.
    You can use these variables:

    • dropchestmaxradius - To adjust the maximum radius for a group or a user
    How to use variables:

    Code:
    users:
      narrowtux:
        info:
          dropchestmaxradius: 1000
    
    This is just an example and this also works with groups!

    Changelog
    Version 0.8.2
    • Fixed the loading issue.
    Version 0.8.1
    • Supports SuperPermissions (when no Permissions plugin was found)
    • Fixed show stopping bugs.
    • Use YAML as persistence storage. You can find the new file at plugins/DropChest/dropchests.yml
    Show Changelog (open)

    Version 0.8
    • Performance improvements
    • Fixed a bug that caused dropchest to eat stacks in storage minecarts (thanks @Tenebria )
    • Implemented per-chest delay (thanks @Gibbers )
    • Made /dc list per player. Use /dc list {pagenum} all to see all showcases (works without all in the console)
    Version 0.7.9
    • Fixed bug where items were lost when a chest/minecart was full on pushing/pulling
    • Little code cleanup
    Version 0.7.8
    • Fixed a bug where, for example, if you had several ItemStacks of 1 block each, only 1 ItemStack would be pulled to the chest or pushed to the MineCart, the others would be deleted.
    • Minecarts can now be over/under DropChests to be handled
    Thanks M-Type!
    Version 0.7.7
    • Double Chest support
    Version 0.7.6

    • Fixed some issues when using a Permissions implementation that is not complete (in this case EssentialsGroupManager as reported by @Kartus )
    Version 0.7.5

    • you can add all items to a filter by using the keyword "all" instead of the material-type
    • you can obtain info about a dropchest without having to rightclick (/dc info {chest}). However, the output is the same as when you would have called /dc which
    Version 0.7.4

    • warnfillstatus=-1 now disables the "chest is full"-warning
    Version 0.7.3

    • Fixed a bug that came with a new Bukkit release
    Version 0.7.2

    • /dc which now says something again, thanks to @Liger_XT5.
    Version 0.7.1

    • Removed debug messages :D
    Version 0.7

    • Configuration added
    • DropChests can drop their contents when a redstone input is present
    • Now, only the owner of a dropchest can adjust it's properties
    • The owner of a dropchest can protect the chest. So other players can't open it.
    • Customizable warning message and fill threshold.
    • Warnings will now be displayed to the owner of a chest, if he is online.
    • And made compatible to Minecraft 1.5_01. Older versions of craftbukkit won't work!
    Version 0.6.9

    • /dc which even more fancy
    • Removed debug message reported by @Reterg
    • Implemented the /item command which tells you what item this id is or vice-versa.
    Version 0.6.8

    • /dc which now looks fancy and shows the filtered items, too.
    Version 0.6.7

    • Added dropchest-id to the /dc which output.
    Version 0.6.6

    • Fixed NullPointerException on startup
    Version 0.6.5

    • Fixed /dc which
    • Refactored some code
    • You can now also use names of dropchests in the commands.
    Version 0.6.4

    • Fixed chunk unload that results in crash
    Version 0.6.3

    • Updated to bukkit-version 602
    • Tried to fix Thread-Exceptions. Breaking DropChests still not fixed, maybe happens later this day ;)
    Version 0.6.2

    • Permissions not required anymore.
    • Thread-Safe. No more ConcurrentModificationCheck Exceptions!
    Version 0.6.1

    • Fixed loading issues. You have to move your old DropChest.txt to the folder DropChest/ in your plugin directory!
    Version 0.6

    • Seperate filters for sucking, pushing to minecarts, pulling from minecarts
    • Multiple users can add dropchests at the same time now!
    • Added a name to the DropChests
    • Fixed Minecraft 1.3-Bug (method net.minecraft.server.Entity.q() was not available any more)
    I'm working on extended furnace handling, that fuels automatically go to the fuel slot and so on. This is still buggy so I didn't released it, it comes in the next version.


    Version 0.5.1
    • Multiworld works now
    • Paginated /dc list
    • Persistent DropChest IDs
    Version 0.5

    • Added support for Storage Minecarts
    • Added support for Dispensers and Furnaces
    Version 0.4.2

    • Fixed bug that Tearlow described.
    Version 0.4.1

    • Fixed loading bug when migration from versions 0.3 or below
    Version 0.4

    • Added filters.
    Version 0.3.1

    • Multiple world support
    • Since the Craftbukkit version from feb, 13 at 12:00 CET, Chests that are destroyed by Players are rebuilt
    • Worked around NullPointerException when Permissions is not loaded properly
    • Files now hosted on github ;) that non-members also can download DropChest
    Version 0.3

    • Permissions support.
    • Configure the maximum radius for each single user or group (via Permissions)
    • Fixes bug with unhandled Exception in the EntityWatcher-Timer.
    • /dropchest can be called via /dc for short
    • /dropchest without arguments just lists the commands that the user can execute, as well as his maximum radius.
    • Oh, and I corrected the Pythagoras formula for radius calculation. Shame on me...
    Version 0.2.3


    This is quite a huge bugfix update. Permissions come next ;)
    • Broken DropChests are now automatically removed from the list
    • changed package name from com.bukkit.narrowtux.DropChest to com.narrowtux.DropChest to prevent not loading issues coming up next monday
    • Added command "which", that allows you to see which id a chest has and if it is already a dropchest.
    • Linked against the most recent versions of Bukkit and Craftbukkit. The Bukkit guys have fixed a lot of bugs that affected this plugin. In my tests, there were no more nullPointerExceptions or similar errors. Also, DropChest now also works on very fresh placed Chests
    • And a currently constant maximum radius of 20 blocks
    Version 0.2.2

    • DropChest are now removed when you call /dropchest remove chestid
    • DropChest now have a minimum radius of 2
    • Fixed some saving issues
    Version 0.2.1

    • Fixed a problem where the radius has not been saved
    Version 0.2

    • Added a radius
    Version 0.1

    • First Release of DropChest
     
  2. Offline

    narrowtux

    I want to do something like this, a redstone active-action, and now that you say it, I can also a redstone-not-active action. This will be a chest-attribute, so you have more freedom to use it.
    Now that I see it, I can actually do 4 different events:
    • Redstone on (will be triggered every 10 ticks)
    • Redstone turns on (just triggered one time when redstone current goes from 0 to 1)
    • Redstone off
    • Redstone turns off
    and these actions:
    • Absorb items
    • Push to minecarts
    • Pull from minecarts
    • Drop Items
    You will be able to connect multiple actions with one event, and also connect one action with multiple events, to provide you the maximal flexibility.
    Can you think of more events/actions?
     
  3. Offline

    Niemand

    Isnt there a way to limit the number of dropchests for users/groups? So "groupOne" can only have 2 dropchests?

    They can - with minecartmania - if i am right.
     
  4. Offline

    Zalastax

    If it only activates every 10 ticks isn't it possible for the minecart to pass by and not get anything?
    Maybe you could have something like you have now that all minecarts that pass by gets pulled from or pushed to with the condition :
    Code:
    if(minecart.nearby=1){        //<-This is the code you use now
    if(Chest.Power=1){           //This is new code
    push                        //<-This is the code you use now
    pull                        //and this
    }                          //This is new code
    else{                      //and this
    do something else         //and this
    }                         //and this
    }
     
  5. Offline

    Niemand

    Doesnt it make more sense if you say "if minecart is nearby and chest gets powered it pushes stuff to minecart. if not it drops everything to the ground." then you make a minecartrail next to the chest with a pressureplate and everytime the minecart comes, it powers the chest and the chest pushes the stuff to the cart.
     
  6. Offline

    Zalastax

    No, at least I want to be able to press a button that makes for example all stone chests push to minecarts when powered. That way I can have chests that are on aline along the tracks and minimize the time needed for the minecart to get my stuff.

    Your idea could work but I would need to make an "and gate" for it and it would be quite much more work,
     
  7. Offline

    Geen117

    THEY FIXED MINECARTS :) Please tell narrowtux!
     
  8. Offline

    Niemand

    just to push it again. I really want to finally finish the configuration of the server. ;)
     
  9. Offline

    HadrienM

    Hello :)

    As i said in the AbsorbPlugin thread :


    Improvement idea :

    With a sign next to the chest/furnace/dispenser/jukebox, a custom line is added on the sign to specify what item must not be absorbed.

    Sign example :

    [AbsorbP]
    4 278 339
    line3
    line4

    So, the chest/furnace/dispenser/jukebox will not absorb cobblestone, diamond pickaxe, and paper which stand next to it (example on a pressure plate).

    Imagine a have a iron door that must be opened with a ticket (paper) that must be bought, i place a pressure plate, and the door opens only if a ticket is on the pressure plate (paper), all other items will be absorbed, but not the ticket (right item to open the door). Iron door and pressure plate are lined together with redstone too... (to precise).

    Sign of the example will be :

    [AbsorbP]
    339
    line3
    line4

    So, item 339 (paper/ticket) will not be absorbed to let the door open for 2 minutes (before it disappear)

    I'm French, sorry if that's not clear enough :)

    PS : not need signs absolutely, a simple line in config file may be ok, well i don't know...
     
  10. Offline

    Semirotta

    does this work with bukkit 860
    and minecraft 1.6.6 ?
    i would love to get this plugin
     
  11. Offline

    narrowtux

    That's already possible, and also without shitty signs, and also with storage-minecart support. Just look at the "Show filter/storage minecarts"-Section in the first post.
    Yep, it works with it.
     
  12. Offline

    HadrienM

    I'm sorry to ask a stupid question, but :

    How can i disable a certain item from being sucked ?

    I tried filter "suck" and i've selected my item which not be sucked, TORCH, id:50 (for example).

    But when a drop a torch, the chest take it, and the chest don't suck any other item.

    I just want the inversed : Torch must not be sucked, but all other items, must be sucked

    Understood ? :( ?

    PS: i don't want to put all items in the game in the filter one by one :/
     
  13. Offline

    Xordaii

    It has been suggested before, adding an exclusion filter. It is a common request. Not going to read back 18 pages to find the author's response, as obviously, you didn't either ;).

    Unfortunately, no, that isn't a feature of this plugin yet. You will need to add every item you do not wish it to suck up.
    Setting a filter for torch only makes it filter INTO the chest that id. So, the filter for torches says only suck up torches, ignore other drops.
     
  14. Offline

    narrowtux

    it's the other way, that's right
    try /dc filter suck chestid all
    then remove torches from the list

    As well, try
    /dc filter suck chestid all

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

    Kartus

    #928 + 0.7.7
    bug: when i have a dc and want to give 3 stacks to the storagecart, only 1 stack will be in storagecart, 2 will be lost.
     
  16. Offline

    saki2fifty

    ===========
    Is there any way to add an "autoempty" command to where it will automatically empty the contents of the chest based on a time that you can specify? So for instance... every 60 seconds, empty the contents.
     
  17. Offline

    Semirotta

    how about 928? :D
     
  18. Offline

    narrowtux

    Version 0.7.8

    • Fixed a bug where, for example, if you had several ItemStacks of 1 block each, only 1 ItemStack would be pulled to the chest or pushed to the MineCart, the others would be deleted.
    • Minecarts can now be over/under DropChests to be handled
    Thanks M-Type!
     
  19. Offline

    bk1138

    You could always invert the redstone signal, if you need off instead of on... and then you could have the signal from the pressure plate trigger the item getting sucked into a chest. :)
     
  20. Offline

    Kartus

    thx for bugfixing in 0.7.8. please update thread title to 0.7.8 ;) it's working with newesst rc #935
     
  21. Offline

    Poeschl

    Does it work with the 953-build of bukkit?
     
  22. Offline

    odielag

    I'm confused and having problems because I can't figure out how to push items to a storage minecart from a chest and suck them into another chest. I've tried following the commands/instructions to no avail. I would think it would be as simple as doing "/dc filter pull (chestidnumber) cobblestone... and when I do "/dc which" it shows cobblestone as being pulled, but no cobblestone goes from the cart to the chest when it passes by. default distance of suck is 6 units and the cart is a level down and within 2 units.

    PS: Using craftbukkit 928
     
  23. Offline

    narrowtux

    The cart has to be directly below the chest or directly aside the chest to make it work ;)
     
  24. Offline

    odielag

    Thank you so much, seems to be working now.

    Attached is a storage facility I made... on a side note, I have 12 catch all chests (to the left) and I'm missing some diamond swords *shrug*.

    I especially like how pigs will die, their pork will be caught in a chest and put on the storage minecart > lava furnace input > cooked > lava furance output > storage minecart > cooked pork chest : )

    Anyhoo, fun plugin.

    I wonder why... I have two double chests on either side of a track, and one double chest on top... and my cobblestone disappeared. Anyone have an idea why that would be
     

    Attached Files:

    Last edited by a moderator: May 8, 2016
  25. Offline

    kekumu

    That's happening to me, too. Actually, it happens with just a one single-width chest. When a chest is set to pull, if a minecart passes it, any items that should be the chest is supposed to pull will be deleted if the chest is full, rather than staying in the minecart. It's a great idea for a plugin, but silently deleting items is one of the worst bugs it could have.
     
  26. Offline

    narrowtux

    Release v0.7.9
    • Fixed bug where items were lost when a chest/minecart was full on pushing/pulling
    • Little code cleanup
     
  27. Offline

    Kartus

    Last edited by a moderator: May 8, 2016
  28. Offline

    narrowtux

    If you really want that ... :D
    Here you go!
    Will add this to the first post as well ;)
     
  29. Offline

    Kartus

  30. Offline

    narrowtux

    I hope so too, but have not so much time on my hand at the moment. I'll add this feature step-by-step.
    The other thing (triggering a lever), will come in combination with the advanced redstone support.
    Aside the actions that should be performed when a chest is triggered by redstone, you'll also be able to select the event that should trigger the lever (for example, absorb an item, pull or push from/to minecarts, rejected opening of a user that doesn't own the chest, etc).
    The events and actions will be freely configureable, and also the filter that only absorbs item that are already in the chest will be available as a per-chest option.
     
  31. Offline

    Kartus

    any expections for release date of this genius feature update? :)
     

Share This Page