Commit f16c70a8 authored by Azilroka's avatar Azilroka
Browse files

Merge branch 'development' into 'development'

Issue 2288

See merge request elvui/elvui!293
parents b2248944 a2815ae5
......@@ -66,11 +66,11 @@ local function GetAuraType(unit, filter, filterTable)
i = 1
while true do
local _, texture, _, debufftype, _, _, _, _, _, spellID = UnitAura(unit, i)
local _, texture, _, debufftype, _, _, caster, _, _, spellID = UnitAura(unit, i)
if not texture then break end
local filterSpell = filterTable[spellID]
if filterTable and filterSpell and filterSpell.enable then
if filterTable and filterSpell and filterSpell.enable and (not filterSpell.ownOnly or caster == 'player') then
return debufftype, texture, true, filterSpell.style, filterSpell.color
end
......
......@@ -361,7 +361,7 @@ E.Options.args.filters = {
if selectedFilter == 'Aura Highlight' then
if not E.global.unitframe.AuraHighlightColors[value] then
E.global.unitframe.AuraHighlightColors[value] = { enable = true, style = 'GLOW', color = {r = 0.8, g = 0, b = 0, a = 0.85} }
E.global.unitframe.AuraHighlightColors[value] = { enable = true, style = 'GLOW', color = {r = 0.8, g = 0, b = 0, a = 0.85}, ownOnly = false }
end
elseif selectedFilter == 'AuraBar Colors' then
if not E.global.unitframe.AuraBarColors[value] then
......@@ -694,6 +694,31 @@ E.Options.args.filters = {
},
},
},
ownOnly = {
name = "Only highlight own", --Needs localization
desc = "Only highlight auras that originated from the player",
order = 5,
type = 'toggle',
hidden = function() return selectedFilter ~= 'Aura Highlight' end,
get = function(info)
local spell = GetSelectedSpell()
if not spell then return end
if selectedFilter == 'Aura Highlight' then
return E.global.unitframe.AuraHighlightColors[spell].ownOnly or false
end
end,
set = function(info, value)
local spell = GetSelectedSpell()
if not spell then return end
if selectedFilter == 'Aura Highlight' then
E.global.unitframe.AuraHighlightColors[spell].ownOnly = value
end
UF:Update_AllFrames();
end,
},
},
}
},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment