From 077286fd5f7cd96577abfe790d8f2c4723ff0e7a Mon Sep 17 00:00:00 2001 From: Parnic Date: Sat, 1 Apr 2023 20:17:50 -0500 Subject: [PATCH] Show Runic Power on a 0-100ish scale with DogTags off --- IceUnitBar.lua | 7 +++++-- changelog.md | 4 ++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/IceUnitBar.lua b/IceUnitBar.lua index 7728895..0862f2a 100644 --- a/IceUnitBar.lua +++ b/IceUnitBar.lua @@ -19,10 +19,11 @@ IceUnitBar.prototype.hasPet = nil IceUnitBar.prototype.noFlash = nil -local SPELL_POWER_INSANITY, SPELL_POWER_RAGE = SPELL_POWER_INSANITY, SPELL_POWER_RAGE +local SPELL_POWER_INSANITY, SPELL_POWER_RAGE, SPELL_POWER_RUNIC_POWER = SPELL_POWER_INSANITY, SPELL_POWER_RAGE, SPELL_POWER_RUNIC_POWER if Enum and Enum.PowerType then SPELL_POWER_INSANITY = Enum.PowerType.Insanity SPELL_POWER_RAGE = Enum.PowerType.Rage + SPELL_POWER_RUNIC_POWER = Enum.PowerType.RunicPower end -- Constructor -- @@ -239,7 +240,9 @@ function IceUnitBar.prototype:Update() -- so this technically doesn't get us the answer we want most of the time. too risky to change at this point, though. self.mana = UnitPower(self.unit, UnitPowerType(self.unit)) self.maxMana = UnitPowerMax(self.unit, UnitPowerType(self.unit)) - if UnitPowerType(self.unit) == SPELL_POWER_RAGE and self.maxMana == 1000 then + local powerType = UnitPowerType(self.unit) + if (powerType == SPELL_POWER_RAGE and self.maxMana == 1000) + or (powerType == SPELL_POWER_RUNIC_POWER and self.maxMana >= 1000) then self.mana = IceHUD:MathRound(self.mana / 10) self.maxMana = IceHUD:MathRound(self.maxMana / 10) end diff --git a/changelog.md b/changelog.md index 7a02d67..86db310 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,9 @@ # Changelog +v1.14.18: + +- Fixed Runic Power showing on a scale of 0-1000+ instead of 0-100+ with DogTags off + v1.14.17: - Updated TOCs for 10.0.7