Hey guys! I am making a backpack plugin, and I was wondering how I could make a chest inventory that opens on right click, and saves the contents put in by a player. How could I do this?
MY CODE:
MY CODE:
Code:
on load:
set {_BACKPACK} to skull of player with custom nbt "{SkullOwner:{Id:"8db4195d-2f3b-4d65-a65a-2edd3124da8c",Properties:{textures:[{Value:"eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNDBjYjFlNjdiNTEyYWIyZDRiZjNkN2FjZTBlYWFmNjFjMzJjZDQ2ODFkZGMzOTg3Y2ViMzI2NzA2YTMzZmEifX19"}]}}}"
command /backpack give <player> <text>:
permission: backpacks.give
permission message: &cYou do not have permission to execute this command!
trigger:
if arg-2 is "XS":
give {_BACKPACK} named "&aExtra Small Backpack" with lore "Right click me to open your backpack!"
if arg-2 is "Small":
give {_BACKPACK} named "&aSmall Backpack"
if arg-2 is "Medium":
give {_BACKPACK} named "&aMedium Backpack"
if arg-2 is "Large":
give {_BACKPACK} named "&aLarge Backpack"
if arg-2 is "XL":
give {_BACKPACK} named "&aExtra Large Backpack"