mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 06:40:13 -05:00
Initial dump of BfA compatibility
Updated for: - SPELL_POWER_* constants becoming Enum.PowerType.* - Rank no longer existing in return values for UnitAura, UnitBuff, UnitDebuff, UnitCastingInfo, UnitChannelInfo - UNIT_POWER event becoming UNIT_POWER_UPDATE - UnitPopupFrames no longer existing - Removed events: PLAYER_PET_CHANGED, UNIT_MAXPOWER, PET_BAR_CHANGED, UNIT_DYNAMIC_FLAGS - Texture return value from UnitAura type changing (name -> id) - All Warlock specializations using soul shards - Death Knight rune changes Haven't tested all classes/specializations yet, so I'm sure I missed some stuff. Probably need to add support for the new circular cooldown wipe flourish added in the base client. Saw a problem with cooldown flashes being delayed on DK runes becoming available that probably need to be fixed.
This commit is contained in:
@ -12,6 +12,11 @@ IceCastBar.prototype.actionMessage = nil
|
||||
IceCastBar.prototype.unit = nil
|
||||
IceCastBar.prototype.current = nil
|
||||
|
||||
local SPELL_POWER_MANA = SPELL_POWER_MANA
|
||||
if IceHUD.WowVer >= 80000 then
|
||||
SPELL_POWER_MANA = Enum.PowerType.Mana
|
||||
end
|
||||
|
||||
local AuraIconWidth = 20
|
||||
local AuraIconHeight = 20
|
||||
|
||||
@ -346,9 +351,18 @@ end
|
||||
|
||||
|
||||
function IceCastBar.prototype:StartBar(action, message)
|
||||
local spell, rank, displayName, icon, startTime, endTime, isTradeSkill = UnitCastingInfo(self.unit)
|
||||
local spell, rank, displayName, icon, startTime, endTime, isTradeSkill
|
||||
if IceHUD.WowVer < 80000 then
|
||||
spell, rank, displayName, icon, startTime, endTime, isTradeSkill = UnitCastingInfo(self.unit)
|
||||
else
|
||||
spell, displayName, icon, startTime, endTime, isTradeSkill = UnitCastingInfo(self.unit)
|
||||
end
|
||||
if not (spell) then
|
||||
spell, rank, displayName, icon, startTime, endTime = UnitChannelInfo(self.unit)
|
||||
if IceHUD.WowVer < 80000 then
|
||||
spell, rank, displayName, icon, startTime, endTime = UnitChannelInfo(self.unit)
|
||||
else
|
||||
spell, displayName, icon, startTime, endTime = UnitChannelInfo(self.unit)
|
||||
end
|
||||
end
|
||||
|
||||
if not spell then
|
||||
@ -496,7 +510,7 @@ function IceCastBar.prototype:SpellCastDelayed(event, unit, delay)
|
||||
if (unit ~= self.unit) then return end
|
||||
--IceHUD:Debug("SpellCastDelayed", unit, UnitCastingInfo(unit))
|
||||
|
||||
local spell, rank, displayName, icon, startTime, endTime, isTradeSkill = UnitCastingInfo(self.unit)
|
||||
local endTime = select(IceHUD.WowVer < 80000 and 6 or 5, UnitCastingInfo(self.unit))
|
||||
|
||||
if (endTime and self.actionStartTime) then
|
||||
-- apparently this check is needed, got nils during a horrible lag spike
|
||||
@ -554,7 +568,12 @@ function IceCastBar.prototype:SpellCastChannelUpdate(event, unit)
|
||||
if (unit ~= self.unit or not self.actionStartTime) then return end
|
||||
--IceHUD:Debug("SpellCastChannelUpdate", unit, UnitChannelInfo(unit))
|
||||
|
||||
local spell, rank, displayName, icon, startTime, endTime = UnitChannelInfo(unit)
|
||||
local spell, rank, displayName, icon, startTime, endTime
|
||||
if IceHUD.WowVer < 80000 then
|
||||
spell, rank, displayName, icon, startTime, endTime = UnitChannelInfo(unit)
|
||||
else
|
||||
spell, displayName, icon, startTime, endTime = UnitChannelInfo(unit)
|
||||
end
|
||||
if not spell then
|
||||
self.actionDuration = 0
|
||||
else
|
||||
|
Reference in New Issue
Block a user