mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-15 22:30:13 -05:00
- Added support for WoD variable 3/5 shadow orbs.
This commit is contained in:
@ -6,24 +6,54 @@ function ShadowOrbs.prototype:init()
|
|||||||
|
|
||||||
self:SetDefaultColor("ShadowOrbsNumeric", 218, 231, 31)
|
self:SetDefaultColor("ShadowOrbsNumeric", 218, 231, 31)
|
||||||
|
|
||||||
-- pulled from PriestBar.xml in Blizzard's UI source
|
|
||||||
self.runeCoords =
|
|
||||||
{
|
|
||||||
{0.45703125, 0.60546875, 0.44531250, 0.73437500},
|
|
||||||
{0.45703125, 0.60546875, 0.44531250, 0.73437500},
|
|
||||||
{0.45703125, 0.60546875, 0.44531250, 0.73437500},
|
|
||||||
}
|
|
||||||
self.numericColor = "ShadowOrbsNumeric"
|
self.numericColor = "ShadowOrbsNumeric"
|
||||||
self.unitPower = SPELL_POWER_SHADOW_ORBS
|
self.unitPower = SPELL_POWER_SHADOW_ORBS
|
||||||
self.minLevel = SHADOW_ORBS_SHOW_LEVEL
|
self.minLevel = SHADOW_ORBS_SHOW_LEVEL
|
||||||
self.bTreatEmptyAsFull = true
|
self.bTreatEmptyAsFull = true
|
||||||
self.unit = "player"
|
self.unit = "player"
|
||||||
self.numConsideredFull = PRIEST_BAR_NUM_ORBS
|
if IceHUD.WowVer >= 60000 then
|
||||||
|
self.numConsideredFull = PRIEST_BAR_NUM_LARGE_ORBS
|
||||||
|
-- pulled from PriestBar.xml in Blizzard's UI source
|
||||||
|
self.runeCoords = { }
|
||||||
|
for i=1, PRIEST_BAR_NUM_SMALL_ORBS do
|
||||||
|
self.runeCoords[i] = {0.45703125, 0.60546875, 0.44531250, 0.73437500}
|
||||||
|
end
|
||||||
|
if IsSpellKnown(SHADOW_ORB_MINOR_TALENT_ID) then
|
||||||
|
self.numRunes = PRIEST_BAR_NUM_SMALL_ORBS
|
||||||
|
else
|
||||||
|
self.numRunes = PRIEST_BAR_NUM_LARGE_ORBS
|
||||||
|
end
|
||||||
|
else
|
||||||
|
self.numConsideredFull = PRIEST_BAR_NUM_ORBS
|
||||||
|
|
||||||
|
-- pulled from PriestBar.xml in Blizzard's UI source
|
||||||
|
self.runeCoords = { }
|
||||||
|
for i=1, PRIEST_BAR_NUM_ORBS do
|
||||||
|
self.runeCoords[i] = {0.45703125, 0.60546875, 0.44531250, 0.73437500}
|
||||||
|
end
|
||||||
|
end
|
||||||
self.runeHeight = 36
|
self.runeHeight = 36
|
||||||
self.runeWidth = 36
|
self.runeWidth = 36
|
||||||
self.requiredSpec = SPEC_PRIEST_SHADOW
|
self.requiredSpec = SPEC_PRIEST_SHADOW
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function ShadowOrbs.prototype:Enable(core)
|
||||||
|
ShadowOrbs.super.prototype.Enable(self, core)
|
||||||
|
|
||||||
|
if IceHUD.WowVer >= 60000 then
|
||||||
|
if not IsSpellKnown(SHADOW_ORB_MINOR_TALENT_ID) then
|
||||||
|
self:RegisterEvent("SPELLS_CHANGED", "CheckHasMoreOrbs")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function ShadowOrbs.prototype:CheckHasMoreOrbs(event)
|
||||||
|
if IsSpellKnown(SHADOW_ORB_MINOR_TALENT_ID) then
|
||||||
|
self:UnregisterEvent("SPELLS_CHANGED")
|
||||||
|
self:UpdateRunePower()
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
function ShadowOrbs.prototype:GetOptions()
|
function ShadowOrbs.prototype:GetOptions()
|
||||||
local opts = ShadowOrbs.super.prototype.GetOptions(self)
|
local opts = ShadowOrbs.super.prototype.GetOptions(self)
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user