Catch Items before Deletion.

Discussion in 'Plugin Requests' started by BlackAsLight, Aug 12, 2020.

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

    BlackAsLight

    Plugin category: Fun?

    Minecraft version: 1.16+

    Suggested name: FiniteMatter

    What I’d like it to do: Before items on the ground despawn or when they fall into lava or a cactus extra. The same item gets teleported into a specific chest or xyz for a hopper to collect set by the Admin for them to resell back to the players.

    I don’t like the idea of admin shops just creating items out of thin air and would prefer if I could collect all the items players let despawn or lose back to the masses who need them.

    Ideas for commands: Admin command to specify which chest or xyz location to transport all despawned or deleted items to.

    Ideas for permissions: Only ops should be able to use the above command.

    When I'd like it by: Soon.
     
  2. Offline

    ryanopily

  3. Offline

    BlackAsLight

    Thanks.

    Firstly, thanks again.

    Secondly, there is a slight bug that I found. Sometimes when I dropped an enchanted golden shovel with efficiency IV on it and half its durability gone onto a cactus, it duplicated the item and placed two in the specified location. I am unsure if it's doing this with other items, as the amount of items that despawns is quite a lot. Especially when someone let loose a bunch of chickens, but the barrels of eggs I now have is my problem to deal with.
    I don't know if this helps in fixing the bug in any way, but the cactus was grown so the item might have been hitting both and duplicating that way.

    Also if there was a message that came back when you set the location, like that it was successful or the cords you set displayed back, that would be nice as the absence of a message is scarier than an error message.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Aug 15, 2020
  4. Offline

    ryanopily

    That's a very good observation! Yes you were correct, the item was hitting both cacti at the same time, and that's why it was duping. I added a cache that checks for it now.

    Also, I added a new config.yml key:
    on_set_location: '&aSuccessfully saved location: &b%location% &aat world: &b%world% &a'

    to the config.yml!

    Hopefully it all pans out.

    Same link as before, but updated plugin jar. https://drive.google.com/drive/folders/1klnnetuKAOGRuNqFXCbmZKQuVN-c-xJE?usp=sharing
     
  5. Offline

    BlackAsLight

    Thanks again.
    I was wondering if you could make a slight change to how the plugin works.
    Since the items can no longer be technically deleted, the chest easily overloads leaving a bunch of items on the ground. I don't know how this acts when the chunk isn't loaded, but if the chunk does get loaded I don't want players experiencing huge lag or the server crashing from like thousands of items being in a single chunk.

    I was wondering if you could make it to check if there is space in the chest for said item, and if there isn't just storing the item in a file in the FiniteMatter folder until there is space made in the chest for it.
     
Thread Status:
Not open for further replies.

Share This Page