diff --git a/api/config.lua b/api/config.lua index 3c729a38..bd6e2d6e 100644 --- a/api/config.lua +++ b/api/config.lua @@ -692,6 +692,7 @@ function pfUI:LoadConfig() pfUI:UpdateConfig("nameplates", nil, "use_unitfonts", "0") pfUI:UpdateConfig("nameplates", nil, "legacy", "0") pfUI:UpdateConfig("nameplates", nil, "overlap", "0") + pfUI:UpdateConfig("nameplates", nil, "verticalhealth", "0") pfUI:UpdateConfig("nameplates", nil, "vertical_offset", "0") pfUI:UpdateConfig("nameplates", nil, "showcastbar", "1") pfUI:UpdateConfig("nameplates", nil, "targetcastbar", "0") diff --git a/modules/gui.lua b/modules/gui.lua index 4616d551..06570009 100644 --- a/modules/gui.lua +++ b/modules/gui.lua @@ -2281,6 +2281,7 @@ pfUI:RegisterModule("gui", "vanilla:tbc", function () CreateConfig(U["nameplates"], T["Hide Healthbar On Totems"], C.nameplates, "totems", "checkbox") CreateConfig(U["nameplates"], T["Always Show On Units With Missing HP"], C.nameplates, "fullhealth", "checkbox") CreateConfig(U["nameplates"], T["Always Show On Target Units"], C.nameplates, "target", "checkbox") + CreateConfig(U["nameplates"], T["Vertical Healthbar"], C.nameplates, "verticalhealth", "checkbox") end) CreateGUIEntry(T["Thirdparty"], T["Integrations"], function() diff --git a/modules/nameplates.lua b/modules/nameplates.lua index 70452ce6..f38a7f4d 100644 --- a/modules/nameplates.lua +++ b/modules/nameplates.lua @@ -453,6 +453,7 @@ pfUI:RegisterModule("nameplates", "vanilla:tbc", function () local width = tonumber(C.nameplates.width) local debuffsize = tonumber(C.nameplates.debuffsize) local healthoffset = tonumber(C.nameplates.health.offset) + local orientation = C.nameplates.verticalhealth == "1" and "VERTICAL" or "HORIZONTAL" nameplate:SetWidth(plate_width) nameplate:SetHeight(plate_height) @@ -460,11 +461,13 @@ pfUI:RegisterModule("nameplates", "vanilla:tbc", function () nameplate.name:SetFont(font, font_size, font_style) + nameplate.health:SetOrientation(orientation) nameplate.health:SetPoint("TOP", nameplate.name, "BOTTOM", 0, healthoffset) nameplate.health:SetStatusBarTexture(hptexture) nameplate.health:SetWidth(C.nameplates.width) nameplate.health:SetHeight(C.nameplates.heighthealth) nameplate.health.hlr, nameplate.health.hlg, nameplate.health.hlb, nameplate.health.hla = hlr, hlg, hlb, hla + CreateBackdrop(nameplate.health, default_border) nameplate.health.text:SetFont(font, font_size - 2, "OUTLINE")