InventoryCard

Discussion in 'Plugin Requests' started by Ratchet1151, Jun 9, 2018.

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

    Ratchet1151

    InventoryCard: A plugin to collect/remember everything in a certain players inventory and save it to a 'card' (a piece of paper, when right clicked brings up a UI/chest with all the inventory items of the target player).
    When an admin punishes or decides to troll a player, they can safely store all items the player had to prevent the player losing everything and easily have all items returned.

    Commands:
    /InvCard SnookerDog true
    (Save SnookerDog's inventory to a card. True will delete/empty SnookerDog's inventory after saving.)

    /InvCard SnookerDog false
    (Save SnookerDog's inventory to a card. False will not empty SnookerDog's inventory after saving.)

    /InvCardItem minecraft:nether_star
    (Change the item of the held card. If holding the piece of paper, that an inventory is saved on, changes the item to a Nether star instead but keeps the items stored on it. This to help differentiate the cards.)

    Right clicking the card, once it has a saved inventory, will give you the option to 'view' the inventory, delete the inventory or give the inventory back to the player it was taken from and destroy the card in the process or simply wipe it ready to be used again.


    EDIT by Moderator: split requests
     
    Last edited by a moderator: Jun 9, 2018
  2. Offline

    Gosintary

    @Ratchet1151 this would be cool. I'm currently trying to fill another one of my requests, (a developer friend of mine said the best way to learn is by doing. Anyway in my request I have to save and restore the users inventory, so if I get it to work, and no one else has done this, Ill try and get it to work. No promises though.
     
  3. @Ratchet1151 Consider it done.

    @Ratchet1151 So far saving inventories works, and I'm right in the middle of building the GUI that opens up when you right click an InventoryCard. I'm also writing a dynamic converter to change an InventoryCard's item type using Minecraft IDs (like minecraft:nether_star), which isn't that easy in Bukkit, if you want the plugin to work in every Minecraft version.

    I will upload the code to my GitHub, and provide a link to a compiled version of the plugin here once it's done.

    Are you using Java 7 or Java 8 for your server?
    If you don't know, that's not a problem. Trial and error is always a way to find out. :p

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 11, 2018
  4. Offline

    MightyOne

  5. @MightyOne Thanks a bunch! In my reflection class I seriously got the NMS version from scanning the jar file. xD

    Good to know how more experienced people do this.
     
Thread Status:
Not open for further replies.

Share This Page