private static void UpdateItemInfoText(InventorySlotAmmo item, int clipLeft, RadialItem radialItem) { if (item == null) { return; } if (item.Slot == InventorySlot.GearStandard || item.Slot == InventorySlot.GearSpecial) { string ammoStatus = clipLeft + "\n----\n" + ((int)(item.BulletsMaxCap * item.RelInPack)).ToString(); radialItem.SetInfoText(ammoStatus); } if (item.Slot == InventorySlot.GearClass) { if (!radialItem.Active) { return; } radialItem.SetInfoText($"{(int)(item.RelInPack * 100f)}%"); } if (item.Slot == InventorySlot.Consumable || item.Slot == InventorySlot.ResourcePack) { int CurrentValue = (int)(item.BulletsMaxCap * item.RelInPack) + clipLeft; radialItem.SetInfoText(CurrentValue.ToString()); radialItem.Active = CurrentValue > 0; if (!radialItem.Active) { radialItem.SetInfoText(""); } } }