Solved problem with items, they autorepair!

Discussion in 'Plugin Development' started by Helldragger, Jul 11, 2014.

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

    Helldragger

    Hiya everyone, I have a big problem with itemstacks, I don't have any idea of what is making this bug because I never create new instances of ItemStacks (but I create instances of ItemStacks custom subclass) but at every right click, if the item in hand is levelled, it autorepair! I tried with some tools, and it seems that only swords doesn't glitch (surely because of the blocking action)

    Any ideas about this durability? When I try to see the durability of my items it's always 0..
     
  2. Offline

    EnderTroll68

    I would use the following constructor:
    ItemStack(Material type, int amount, short damage)
     
  3. Offline

    Helldragger

    Ah, it works! thanks! :D
     
Thread Status:
Not open for further replies.

Share This Page