cooldown: only draw cd on known frames

This commit is contained in:
shagu
2018-04-08 19:04:43 +02:00
parent ea17079ad2
commit 41e2400bcb
8 changed files with 41 additions and 8 deletions
+1
View File
@@ -74,6 +74,7 @@ function pfUI:LoadConfig()
pfUI:UpdateConfig("appearance", "cd", "threshold", "2")
pfUI:UpdateConfig("appearance", "cd", "font_size", "12")
pfUI:UpdateConfig("appearance", "cd", "debuffs", "1")
pfUI:UpdateConfig("appearance", "cd", "blizzard", "1")
pfUI:UpdateConfig("appearance", "castbar", "castbarcolor", ".7,.7,.9,.8")
pfUI:UpdateConfig("appearance", "castbar", "channelcolor", ".9,.9,.7,.8")
pfUI:UpdateConfig("appearance", "infight", "screen", "0")
+2
View File
@@ -350,6 +350,7 @@ function pfUI.uf:UpdateConfig()
f.buffs[i].stacks:SetShadowOffset(0.8, -0.8)
f.buffs[i].stacks:SetTextColor(1,1,.5)
f.buffs[i].cd = f.buffs[i].cd or CreateFrame("Model", nil, f.buffs[i], "CooldownFrameTemplate")
f.buffs[i].cd.pfCooldownType = "ALL"
f.buffs[i].cd:SetAlpha(0)
f.buffs[i]:RegisterForClicks("RightButtonUp")
@@ -428,6 +429,7 @@ function pfUI.uf:UpdateConfig()
f.debuffs[i].stacks:SetShadowOffset(0.8, -0.8)
f.debuffs[i].stacks:SetTextColor(1,1,.5)
f.debuffs[i].cd = f.debuffs[i].cd or CreateFrame("Model", nil, f.debuffs[i], "CooldownFrameTemplate")
f.debuffs[i].cd.pfCooldownType = "ALL"
f.debuffs[i].cd:SetAlpha(0)
f.debuffs[i]:RegisterForClicks("RightButtonUp")