Use typed durability for presentation
This commit is contained in:
parent
dc8c3353cf
commit
b33bccea45
7 changed files with 27 additions and 11 deletions
|
|
@ -874,7 +874,7 @@ public class InventoryPanel : MonoBehaviour, IPointerClickHandler
|
|||
if (typedItem != null && typedItem.Durability > 0)
|
||||
return (float)typedItem.Durability;
|
||||
|
||||
return _displayedEntity.ItemManager.GetData(item).Durability;
|
||||
return Math.Max(item.Durability, 1f);
|
||||
}
|
||||
|
||||
private Shape GetItemShape(ItemInstance item)
|
||||
|
|
|
|||
Loading…
Reference in a new issue