mirror of
https://github.com/parnic/ice-hud.git
synced 2025-06-16 14:50:13 -05:00
- only show Lacerates if they were applied to the target by the player (not by other players); had problems with bear tank + feral dps in the same group
- made the same change to SunderCount's version of the debuff function, but didn't set it to restrict to the player
This commit is contained in:
@ -203,15 +203,15 @@ function LacerateCount.prototype:CreateLacerateFrame()
|
||||
end
|
||||
|
||||
|
||||
function LacerateCount.prototype:GetDebuffCount(unit, ability)
|
||||
function LacerateCount.prototype:GetDebuffCount(unit, ability, onlyMine)
|
||||
for i = 1, MAX_DEBUFF_COUNT do
|
||||
local name, _, texture, applications = UnitDebuff(unit, i)
|
||||
local name, _, texture, applications, _, duration = UnitDebuff(unit, i)
|
||||
|
||||
if not texture then
|
||||
break
|
||||
end
|
||||
|
||||
if string.match(texture, ability) then
|
||||
if string.match(texture, ability) and (not onlyMine or duration) then
|
||||
return applications
|
||||
end
|
||||
end
|
||||
@ -221,7 +221,7 @@ end
|
||||
|
||||
|
||||
function LacerateCount.prototype:UpdateLacerateCount()
|
||||
local points = self:GetDebuffCount("target", "Ability_Druid_Lacerate")
|
||||
local points = self:GetDebuffCount("target", "Ability_Druid_Lacerate", true)
|
||||
|
||||
if (points == 0) then
|
||||
points = nil
|
||||
|
Reference in New Issue
Block a user