[MISC] ClearInventory v0.3 - Remove Items From Self (Main/Bar/All) - /cinv [1597]

Discussion in 'Inactive/Unsupported Plugins' started by ltguide, Mar 30, 2011.

  1. Offline

    ltguide

    ClearInventory - Remove Items From Self (Main/Bar/All)
    Version: v0.3
    CraftBukkit: 556, 617, 677, 733, 818, 860, 935, 953, 1000, 1060, 1185, 1240, 1337

    ClearInventory is an easy way to remove items from your own inventory without dropping them. It can clear either the main inventory window, the quick bar slots, or both.

    I have no plans to add any more features to this plugin. There are other inventory cleaners that target certain blocks and other players.

    Features:
    • Quick inventory clear
    • Prevent dropping dangerous materials on the ground
    • Clear each inventory area separately or together
    • Only acts on the user entering command
    Commands:

    ClearInventory adds the command: /clearinventory (/cinv). There is no functionality from the console.
    • /cinv <main|bar|all>
    The area can be main for the main inventory area, bar for the quick bar slots, or all for both areas.

    Configuration
    None

    Permissions
    'clearinventory.use'
    Without permissions, it defaults to OPs.


    Download ClearInventory Plugin
    Source Code

    Changelog:
    Version 0.3
    • properly use command aliases in plugin.yml
    • remove unnecessary if from onCommand
    Show Spoiler
    Version 0.2
    • Added permissions support
    • Fixed syntax error message
    Version 0.1
    • Initial release
     
    Nathan Bowes likes this.
  2. Offline

    aPunch

    This is a really cool plugin! I especially like that you have the option of clearing the hot-bar instead of all of the inventory. Nice work!!
     
  3. Offline

    spunkiie

    great stuff
     
  4. Offline

    TheArcher

    When you type "/clearinventory" or "/cinv", a message pops up that says "Usage: /clearinv <main|bar|all>". However, using "clearinv" as a substitute for "clearinventory" or "cinv" does not work. Basically, it's misleading.

    Otherwise, great plugin.
     
  5. Offline

    ltguide

    Oh, I'm sorry. That's a mistake.
     
  6. Offline

    Nelien

    This looks very useful if you only add permissions nodes to it! (Or configuration to allow only OP's to use it)
     
  7. Offline

    ltguide

    I don't see why you would need permissions to use this. Could you explain your reasoning?
     
  8. Offline

    Nelien

    I don't want my users to use the command if I run an RP server. Inventory management is part of the game and I find it a bit out of immersion to simply be able to make items disappear by the use of a command. It's a minor concern, I'm aware of that, but if it's not too hard to add it would be appreciated.
     
  9. Offline

    Unscrewed

    Agreed
     
  10. Offline

    ltguide

    Sure, it isn't very hard to add permissions. I'll try to update soon, possibly tomorrow.

    Nevermind, I did it now. Added permissions support and fixed the syntax error message.

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

    VSkwidd

    Hey There. Neat addon. I'd really love to use it to clear other players inventories as well though. I have an RP jail added in and there's no real way to "pat down" another player after they've deposited supposedly "all" of their items and can result in them causing some serious chaos.

    If it listed the items it cleared to the person that ran the command it would be nearly the same as a pat down :D
     
  12. Offline

    Nelien

    Thank you!
     
  13. Offline

    MacVaultDweller

    Great tool thanks for the hard work
    Hope it works with cb 733
     
  14. Offline

    Kalais

    Can you add the following?

    A user entering a certain region/area or passing over a certain block/sign has their inventory cleared.
     
  15. Offline

    ltguide

    I've never used it, but CommandSigns lets you run commands when you click on signs. It looks to be broken in 1.5 but there's an unofficial build of it.
     
  16. Offline

    beatcomet

    can you add the function of armor removal?
     
  17. Offline

    andreblue

    @Kalais
    Get the portal stick plugin, it has the reed thing that allows you to clear it
     
  18. Offline

    drakcore

    Is it possible to set it up in such a way with permissions on entering another world to loose all your items on entering that world (multiworld)?
     
  19. Offline

    DEFCON98

    Hey I get an error saying an internal error occured, im using group manager and all, so i installed the permmissions in the config, and even tested in YML Parser or whatever, and I get 'An internal error occured while attempting to perform this command.' help?
     
  20. Offline

    ltguide

    What Craftbukkit version are you running? I just tested it on #818. I don't think your permissions plugin would cause that error, but with Permissions 3.1.1 it works.

    What is the full error message section from the log?
     
  21. Offline

    akedia

    thanks this plugin i really needed for my server
     
  22. Offline

    toffo

    Would it be possible to get a /ci command? I'm missing that from Essentials I think it was, or General maybe.
    As I'm not using those anymore it would be great if this plugin could give us that commandsyntax as well :)

    Perhaps also without <main|bar|all>, so default would be all :)
     
  23. Offline

    ltguide

    You can add the /ci alias pretty easily.
    (I use 7-zip. winrar should be able to do it too)
    1. Open ClearInventory.jar in zip program
    2. Right-click plugin.yml
    3. Choose Edit (open with notepad)
    4. Change "aliases: cinv" to "aliases: [cinv,ci]" (or drop cinv altogether)
    5. Save & Exit
    6. Zip program will update .jar
    I'm trying to keep this plugin as simple as possible, but I could be persuaded to make it force 'all' if you really want.
     
  24. Offline

    AS1LV3RN1NJA

    Theres a plugin called something like bShortcut that is a lot easier than this sort of thing.
     
  25. Offline

    po5

    Im liking this. :)

    and here is a silly request. can u make it so you can use /cinv main cobble ... then only cobble will be cleared for example
     
  26. Offline

    ltguide

    The latest CraftBukkit added server-wide aliases. See bukkit.yml for an example.
     
  27. Offline

    Perling

    works greate ! i love you :D
     
  28. Offline

    maximee9

    Thanks alot! This was just the plugin i was looking for. Me an my friends always made an lava pool to vanish our items. Haha.
    Sincerly thank you ltguide.
     
  29. Offline

    Tolerance

    For those who don't know, 'Essentials' supports this (clearinventory) also. This being said, the command /clearinventory will most likely be "ruled out" if user has Essentials.
    I'd also add ability to clear others inventory. Essentials has this also and many users I know of use it, and like it. Other than that, nothing I'd comment about. Good plugin.
     
  30. Offline

    Taketheword

    Ahh will install right away, just what I wanted :)

    Can you please post a ZIP file? My computer is being lame right now and whenever I try to download a JAR,
    it keeps saying Java Virtual Launcher Error :(

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

Share This Page