public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddConditionInfo(tipItem); infoWindow.AddSectionTitle("Protection", 0f); for (int i = 0; i < 6; i++) { if (this.armorValues[i] != 0f) { float contentHeight = infoWindow.GetContentHeight(); GameObject obj2 = infoWindow.AddBasicLabel(TakeDamage.DamageIndexToString((DamageTypeIndex)i), 0f); GameObject obj3 = infoWindow.AddBasicLabel("+" + ((int)this.armorValues[i]).ToString("N0"), 0f); obj3.transform.SetLocalPositionX(145f); obj3.GetComponentInChildren <UILabel>().color = Color.green; obj2.transform.SetLocalPositionY(-(contentHeight + 10f)); obj3.transform.SetLocalPositionY(-(contentHeight + 10f)); } } infoWindow.AddSectionTitle("Equipment Slot", 20f); string text = "Head, Chest, Legs, Feet"; if ((base._itemFlags & Inventory.SlotFlags.Head) == Inventory.SlotFlags.Head) { text = "Head"; } else if ((base._itemFlags & Inventory.SlotFlags.Chest) == Inventory.SlotFlags.Chest) { text = "Chest"; } infoWindow.AddBasicLabel(text, 10f); infoWindow.AddItemDescription(this, 15f); infoWindow.FinishPopulating(); }
public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddSectionTitle("Medical", 15f); infoWindow.AddBasicLabel("Instantly heals " + amountToHeal + " health and stops bleeding.", 15f); infoWindow.FinishPopulating(); }
public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddSectionTitle("Ingredients", 15f); for (int i = 0; i < this.ingredients.Length; i++) { string name = this.ingredients[i].Ingredient.name; if (this.ingredients[i].amount > 1) { name = name + " x" + this.ingredients[i].amount; } infoWindow.AddBasicLabel(name, 15f); } infoWindow.AddSectionTitle("Result Item", 15f); infoWindow.AddBasicLabel(this.resultItem.name, 15f); infoWindow.AddItemDescription(this, 15f); infoWindow.FinishPopulating(); }
public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddSectionTitle("Medical", 15f); string empty = string.Empty; empty = (this.healthAddMin != this.healthAddMax ? string.Concat(new object[] { "Heals ", this.healthAddMin, " to ", this.healthAddMax, " health." }) : string.Concat("Heals ", this.healthAddMin, " health.")); infoWindow.AddBasicLabel(empty, 15f); infoWindow.FinishPopulating(); }
public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddSectionTitle("Consumable", 15f); if (this.calories > 0f) { infoWindow.AddBasicLabel(this.calories + " Calories", 15f); } if (this.litresOfWater > 0f) { infoWindow.AddBasicLabel(this.litresOfWater + "L Water", 15f); } if (this.antiRads > 0f) { infoWindow.AddBasicLabel("-" + this.antiRads + " Rads", 15f); } if (this.healthToHeal != 0f) { infoWindow.AddBasicLabel(((this.healthToHeal <= 0f) ? string.Empty : "+") + this.healthToHeal + " Health", 15f); } infoWindow.AddItemDescription(this, 15f); infoWindow.FinishPopulating(); }
public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddSectionTitle("Medical", 15f); string text = string.Empty; if (this.healthAddMin == this.healthAddMax) { text = "Heals " + this.healthAddMin + " health."; } else { object[] objArray1 = new object[] { "Heals ", this.healthAddMin, " to ", this.healthAddMax, " health." }; text = string.Concat(objArray1); } infoWindow.AddBasicLabel(text, 15f); infoWindow.FinishPopulating(); }
public override void PopulateInfoWindow(ItemToolTip infoWindow, IInventoryItem tipItem) { infoWindow.AddItemTitle(this, tipItem, 0f); infoWindow.AddConditionInfo(tipItem); infoWindow.AddSectionTitle("Weapon Stats", 20f); float single = this.recoilPitchMax + this.recoilYawMax; float single1 = 60f; float single2 = 1f / this.fireRate; if (!this.isSemiAuto) { infoWindow.AddProgressStat("Fire Rate", single2, 12f, 15f); } else { infoWindow.AddBasicLabel("Semi Automatic Weapon", 15f); } infoWindow.AddProgressStat("Damage", this.GetGUIDamage(), 100f, 15f); infoWindow.AddProgressStat("Recoil", single, single1, 15f); infoWindow.AddProgressStat("Range", this.GetBulletRange(null), 200f, 15f); infoWindow.AddItemDescription(this, 15f); infoWindow.FinishPopulating(); }