mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 06:40:13 -05:00
Fix up uses of UnitBuff and UnitDebuff for 11.0.2
This commit is contained in:
@ -45,6 +45,18 @@ if C_Spell and C_Spell.GetSpellName then
|
|||||||
GetSpellName = C_Spell.GetSpellName
|
GetSpellName = C_Spell.GetSpellName
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local UnitBuff = UnitBuff
|
||||||
|
if not UnitBuff and C_UnitAuras and AuraUtil then
|
||||||
|
UnitBuff = function(unitToken, index, filter)
|
||||||
|
local auraData = C_UnitAuras.GetBuffDataByIndex(unitToken, index, filter)
|
||||||
|
if not auraData then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
return AuraUtil.UnpackAuraData(auraData)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
-- Constructor --
|
-- Constructor --
|
||||||
function RollTheBones.prototype:init()
|
function RollTheBones.prototype:init()
|
||||||
RollTheBones.super.prototype.init(self, "RollTheBones", "player")
|
RollTheBones.super.prototype.init(self, "RollTheBones", "player")
|
||||||
|
@ -53,6 +53,18 @@ if Enum and Enum.PowerType then
|
|||||||
SPELL_POWER_COMBO_POINTS = Enum.PowerType.ComboPoints
|
SPELL_POWER_COMBO_POINTS = Enum.PowerType.ComboPoints
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local UnitBuff = UnitBuff
|
||||||
|
if not UnitBuff and C_UnitAuras and AuraUtil then
|
||||||
|
UnitBuff = function(unitToken, index, filter)
|
||||||
|
local auraData = C_UnitAuras.GetBuffDataByIndex(unitToken, index, filter)
|
||||||
|
if not auraData then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
return AuraUtil.UnpackAuraData(auraData)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
-- Constructor --
|
-- Constructor --
|
||||||
function SliceAndDice.prototype:init()
|
function SliceAndDice.prototype:init()
|
||||||
SliceAndDice.super.prototype.init(self, "SliceAndDice", "player")
|
SliceAndDice.super.prototype.init(self, "SliceAndDice", "player")
|
||||||
|
@ -42,6 +42,18 @@ if C_Spell and C_Spell.GetSpellName then
|
|||||||
GetSpellName = C_Spell.GetSpellName
|
GetSpellName = C_Spell.GetSpellName
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local UnitDebuff = UnitDebuff
|
||||||
|
if not UnitDebuff and C_UnitAuras and AuraUtil then
|
||||||
|
UnitDebuff = function(unitToken, index, filter)
|
||||||
|
local auraData = C_UnitAuras.GetDebuffDataByIndex(unitToken, index, filter)
|
||||||
|
if not auraData then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
return AuraUtil.UnpackAuraData(auraData)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
StaggerBar.prototype.StaggerDuration = 0
|
StaggerBar.prototype.StaggerDuration = 0
|
||||||
StaggerBar.prototype.StaggerEndTime = 0
|
StaggerBar.prototype.StaggerEndTime = 0
|
||||||
|
|
||||||
|
@ -4,6 +4,18 @@ local DogTag = nil
|
|||||||
|
|
||||||
local TargetOfTarget = IceCore_CreateClass(IceElement)
|
local TargetOfTarget = IceCore_CreateClass(IceElement)
|
||||||
|
|
||||||
|
local UnitDebuff = UnitDebuff
|
||||||
|
if not UnitDebuff and C_UnitAuras and AuraUtil then
|
||||||
|
UnitDebuff = function(unitToken, index, filter)
|
||||||
|
local auraData = C_UnitAuras.GetDebuffDataByIndex(unitToken, index, filter)
|
||||||
|
if not auraData then
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
return AuraUtil.UnpackAuraData(auraData)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
TargetOfTarget.prototype.stackedDebuffs = nil
|
TargetOfTarget.prototype.stackedDebuffs = nil
|
||||||
TargetOfTarget.prototype.buffSize = nil
|
TargetOfTarget.prototype.buffSize = nil
|
||||||
TargetOfTarget.prototype.height = nil
|
TargetOfTarget.prototype.height = nil
|
||||||
|
Reference in New Issue
Block a user