hello i was wondering if you could switch durability on a item like my plugin is making leather armor but i want it to have the durability of diamond armor i can make it so the leather armor registers having diamond durability and maybe armor points to?
try something like: public void durability(ItemStack i, short durability) { i.setDurability(durability); } Havent tested it so dont know if itl work.
Well I think durability starts at 0 (full durability, no bar) and ends at X depending on the item. The only way I could see you giving it the durability of diamond is to log changes made to it. For me, on my server, it would take way too long to do that so I just gave wooden swords durability X (10) I think, or something like that