mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 06:40:13 -05:00
- added support for mh/oh weapon enchants to the custom counter module
This commit is contained in:
13
IceHUD.lua
13
IceHUD.lua
@ -777,6 +777,19 @@ function IceHUD:GetDebuffCount(unit, ability, onlyMine, matchByName)
|
||||
end
|
||||
|
||||
function IceHUD:GetAuraCount(auraType, unit, ability, onlyMine, matchByName)
|
||||
if unit == "main hand weapon" or unit == "off hand weapon" then
|
||||
local hasMainHandEnchant, mainHandExpiration, mainHandCharges, hasOffHandEnchant, offHandExpiration, offHandCharges
|
||||
= GetWeaponEnchantInfo()
|
||||
|
||||
if unit == "main hand weapon" and hasMainHandEnchant then
|
||||
return mainHandCharges
|
||||
elseif unit == "off hand weapon" and hasOffHandEnchant then
|
||||
return offHandCharges
|
||||
end
|
||||
|
||||
return 0
|
||||
end
|
||||
|
||||
for i = 1, 40 do
|
||||
local name, _, texture, applications = UnitAura(unit, i, auraType..(onlyMine and "|PLAYER" or ""))
|
||||
|
||||
|
Reference in New Issue
Block a user