Hello,

I have some questions about the durability feature on ORK.
I have been trying to add it in for the weapons, with a max value of 10 and when the weapon wears off it gets unequipped.
At the moment, when hovering on the information of a weapon which is not equipped on the player, the durability is 0.
When the player equips the weapon it is set at 10. with every hit, we decrease the durability by 1.

The issue I am having is that if I use a weapon of max durability 10, get two hits so it reaches 8 and then unequip it, the durability (as shown on the inventory) goes back to 10.

Is there a way to keep it to the value after the use?

Thank you
  • I'll look into it, unequipping shouldn't reset durability.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Tested it and works fine - unequipping doesn't change the durability.
    The only thing happening is that equipping it again will recalculate the maximum durability and adjust the durability in case it's now higher than the maximum.
    Do you have multiple of the same equipment in your inventory?

    Btw, there's the Auto Init option for durability to automatically initialize durability for newly created equipment, so it's already set before equipping it the first time.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • So the issue was that the durability was set again to the maximum upon equipping it again.
    I was looking for a way in which the durability of an item would be "saved". For example if I have a sword with max durability of 10, I use it and the durability gets to 7, unequip it and use something else, I wanted the durability of the sword to be 5 again once I equip it again.

    To answer your question for the tests I was running I had multiple instances of the same sword/weapon.
  • Hm, durability is only set to maximum when it's equipped for the first time (and not using auto init). Equipping it again will only update the maximum possible durability and reduce durability in case the new maximum is below the current durability.

    As said, I tested it and it worked fine - the unequipped thing has the correct durability and equipping it again also keeps the correct durability.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.