public void Use(EquipableItem item) { if (currentInventoryObject.tag == "EquipmentSlot") { equipmentSlotManager.UnloadEquipmentOnSlot(item, item.slotType); equipmentSlotManager.UnloadEquipementOnEquipMenu(item, item.slotType); item.equipped = false; modHandler.RemoveAllModifiers(item); inventoryHandler.AddItem(item); characterStats.SetMaxAPFromStamina(); characterStats.SetMaxHealthFromVitality(); } else { equipmentSlotManager.LoadEquipmentOnSlot(item, item.slotType); equipmentSlotManager.LoadEquipementOnEquipMenu(item, item.slotType); item.equipped = true; modHandler.ApplyEquipmentModifiers(item); characterStats.SetMaxAPFromStamina(); characterStats.SetMaxHealthFromVitality(); } statpreview.updateStatTexts(); }
public override void Use() { Initialize(); equipmentSlotManager.LoadEquipmentOnSlot(this, slotType); equipmentSlotManager.LoadEquipementOnEquipMenu(this, slotType); }