bdUI

bdUI

111k Downloads

Invocations to bd::filter_aura calls in Unit Frame are not respecting whitelist/class auras

perks opened this issue ยท 0 comments

commented

Due to certain conditionals when setting up unit frames, whenever the bd::filter_aura call is invoked and would return true for a whitelist/class aura, additional conditionals afterwards overwrite whitelist behavior:

if ( not bdUI:filter_aura(name, castByPlayer, isBossDebuff, nameplateShowAll, true)) then return false end
-- but also only show player and with durations
if (caster == "player" and duration ~= 0 and duration < 300) then return true end

Even though the whitelist is explicitly setting the buff to appear on the player frame, only satisfying the "duration" condition will ever actually do a valid return true

something like this is probably better logic?

local showBuff =  (caster == "player" and duration ~= 0 and duration < 300) or bdUI:filter_aura(name, castByPlayer, isBossDebuff, nameplateShowAll, true)
return showBuff

Then in unitframes, important raid debuffs such as Sunder Armor, or other whitelisted auras as well are not being shown because:

if (castByPlayer and (duration ~= 0 and duration < 300)) then
if (bdUI:filter_aura(name, casterIsPlayer, isBossDebuff, nameplateShowAll, true)) then
return true
end
end

bd::filter_aura is not going to get called if the debuff source is not "player" so the whitelist effect never comes into play

Again a fix is something similar to the player frame fix.

Thanks again, and love the unit frames! Honestly the only ones I've even been able to use for more than 1 night :D