Filled Undroppable Item plugin

Discussion in 'Plugin Requests' started by 2PRO4DAUNIVERSE, Aug 4, 2018.

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


    Plugin category: Utility?

    Minecraft version: Minecraft 1.12.2

    Suggested name: Undroppable Item

    What I want:

    I need a plugin that creates a special enchantment called "Undroppable". Said enchantment makes so the item is not droppable, and cannot be stored in any item container, except ender chests.

    Basically, a player with an item that contains the "Undroppable" enchantment cannot drop the item, either by pressing "Q", dragging it out of the inventory or closing the inventory while dragging the item. The player also doesn't drop the item on death.

    However, the player also can't store the item in chests, droppers, dispensers, hoppers, etc. The item can't be stored in any container BUT can be stored in an ender chest. I can explain as to why I want the item to be able to be stored in an ender chest, but it would be a huge wall of text.

    For OPs, there's a command that allows the addition/removal of the "Undroppable" enchantment. There is also a toggle command that allows the user to bypass the enchantment, being able to drop items, even if they have the "Undroppable" enchantment.

    Ideas for commands:

    - /undroppable enchant- Enchants the held item with the "Undroppable" enchantment.
    - /undroppable remove - Removes the "Undroppable" emchantment from the held item.
    - /undroppable toggle - Turns on/off the undroppable bypass.

    Ideas for permissions:

    - undroppable.enchant - Permission for "/undroppable enchant" command. (default for OP only)
    - undroppable.remove - Permission for "/undroppable remove" command. (default for OP only)
    - undroppable.toggle - Permission for "/undroppable toggle" command. (default for OP only)

    When I'd like it by:

    I know this is a big request. I don't need this plugin urgently, as I have other stuff to take care of on my server. I'd like it as soon as possible, but if someone ends up accepting this request - Take your time.

    P.S.: My English is not perfect. If there's something that you didn't understand, please tell me. I'll be happy to help.
    Last edited: Aug 12, 2018
  2. Offline


  3. Offline


    I have the plugin 90% finished, let me a little more time C:
  4. Offline


    Sure, no problem!
  5. Offline


    I support this. Best of luck making it :)
  6. Offline


    Curse of Binding
  7. Offline


    Not the same. Did you even read the whole post?
  8. I assume the plugin request hasn't been filled yet, so I've quickly made the plugin, here it is: <EDIT by Moderator: Redacted mediafire URL>

    The commands are as you requested, as well as the permissions.

    I didn't give the plugin configurable settings, I just got the essential functions to work. If you'd like any adjustments, feel free to ask.

    Hope this is what you were looking for!
    Last edited by a moderator: Aug 16, 2018
  9. Offline


    @Kevinzuman22 The link has been removed, try uploading the plugin another place and send that link.
  10. Last edited: Aug 16, 2018
  11. Offline


    @Kevinzuman22 Doesn't really work. :/
    EDIT: It's pretty obvious what i mean if you test the plugin yourself while reading the OP.
    Last edited by a moderator: Aug 16, 2018
  12. @KarimAKL I noticed I made an error in the code for handling bypass mode. I fixed that. I also noticed I failed to notice the request to have the items being kept upon death. I added that feature now. In the meantime I also found a bug that occured upon closing a chest or anything like that, which has also been fixed now.

    You can download the new version through the same link as for the old version, I replaced it with the new version:

    Other than all these things, the plugin seems to be working properly in my eyes. If I'm missing anything, please specify so I can investigate the problem.

    But be aware, you can still drag the enchanted item over to a chest. But it is when the item is in the chest, and you close the chest, that it is removed from that chest and re-added to your inventory. This way was easier to code.

    Also, the plugin is now also on BukkitDev, although the new version I still have to upload yet.

    EDIT: The new version is now also available on the BukkitDev page.
    Last edited: Aug 16, 2018
  13. Offline


    I see, i'll test it now and see if i find anything. (I did already notice that it was upon InventoryCloseEvent that you removed the item(s))
    EDIT: Things i find changed.
    1. Made "/undroppable help" & "/undroppable ?" work.
    2. New message if you try to enchant an already enchanted item. (with /undroppable enchant)
    3. Added checks for null in InventoryCloseEvent.
    4. Removes item(s) on ground in PlayerDeathEvent and adds it/them on PlayerRespawnEvent.
    5. ??? Please let me know if anything else is changed.
    This seems to be working as requested in the OP, i would recommend this to @2PRO4DAUNIVERSE. :)
    EDIT2: One thing i wanted to say is that the messages you've put in the plugin looks great. :)
    Last edited by a moderator: Aug 16, 2018
    Kevinzuman22 likes this.
  14. Offline


    Thanks for testing the plugin! I didn't have my computer, so I couldn't test it myself. I'll be sure to check it out now.

    @Kevinzuman22, as for any configuration settings, the only suggestion I have is toggling the ability to "move" the item in specific ways. What I mean by that is: Enabling/desabling the storage of the item in a chest, in a dropper... That way, it's possible to customize the plugin some more. I really don't know how hard it is to make something like that, but it's only a suggestion.

    EDIT: So, I tested the plugin. I have not mentioned it in the original post, and I am really sorry, but I requested this plugin as a way to make private items, in the sense that you can't give it to other players. However, due to how the chest works, if a player stores the item in a chest and doesn't close the GUI, then another player can take it out. This applies to chests, hoppers, furnaces, dispensers, droppers, trapped chests and shulker boxes. Another big problem is that the item can be placed in an item frame. I apologize for not saying it earlier.

    As for the rest, it works like a charm. Flawless.
    Last edited: Aug 17, 2018
  15. Offline


    This request is a perfect example on how to do correct. You provide not more then thé necessary details and more important, you realize thé work load attached to it. and respect thé developers

    You are a big plus for every plugin fulfiller out there

    Verstuurd vanaf mijn ONEPLUS A3003 met Tapatalk
  16. Offline


    Thank you good sir. I appreciate it.
  17. Offline


    Kind words :) Thanks
  18. Sorry for my long absence. I'll be looking into all the adjustments you would like to be made ASAP, and apply them accordingly. Would I run into any trouble in doing so, I'll notify you here.

    Happy the plugin is (at least somewhat) to your liking!

    EDIT: I see you would like to have the way the plugin prevents items from being added to chests and such changed to a way that it completely disables even moving them into the chest in the first place, completely preventing other players from obtaining that item. This would require a decent change in the plugin, so please bear with me while I tinker around to getting that feature working properly. I've attempted doing a feature like this before, but failed to do so (for the most part, it required some minor attention to finish it, but nevertheless, it was not functional), therefore it will require some practice from my part to get this working.

    I'll be working on the adjustments in the upcoming week. I'll do my best to complete it within that week.
    Last edited: Sep 1, 2018
  19. Offline


    Don't worry about it. As I said, I want you to take as much time as you need.

    Also, if you have any question, please, do ask me. I'll be happy to help. And thank you for your hard work!
  20. This request has been filled. For anyone looking for this plugin, it's available at DevBukkit.
  21. Offline


    Yea, I forgot to mark it as filled. My bad.
Thread Status:
Not open for further replies.

Share This Page