nameplates: hide stuff as early as possible

This commit is contained in:
shagu
2017-01-02 00:37:31 +01:00
parent 66106aa976
commit 2f22f9e4a2
+5 -4
View File
@@ -41,6 +41,10 @@ pfUI:RegisterModule("nameplates", function ()
local healthbar = nameplate:GetChildren()
local border, glow, name, level, levelicon , raidicon = nameplate:GetRegions()
-- hide default plates
border:Hide()
glow:Hide()
if pfUI_config.nameplates.players == "1" then
if not pfUI_playerDB[name:GetText()] or not pfUI_playerDB[name:GetText()]["class"] then
nameplate:Hide()
@@ -156,10 +160,6 @@ pfUI:RegisterModule("nameplates", function ()
end
end
-- hide default plates
border:Hide()
glow:Hide()
-- adjust font
name:SetFont(STANDARD_TEXT_FONT,12,"OUTLINE")
name:SetPoint("BOTTOM", healthbar, "CENTER", 0, 7)
@@ -219,6 +219,7 @@ pfUI:RegisterModule("nameplates", function ()
-- create frames
if healthbar.castbar == nil then
healthbar.castbar = CreateFrame("StatusBar", nil, healthbar)
healthbar.castbar:Hide()
healthbar.castbar:SetWidth(110)
healthbar.castbar:SetHeight(7)
healthbar.castbar:SetPoint("TOPLEFT", healthbar, "BOTTOMLEFT", 0, -5)