mirror of
https://github.com/brues-code/pfUI.git
synced 2026-09-28 02:16:02 +00:00
unitframes: add option for text offsets for hp & power bars
This commit is contained in:
+12
-12
@@ -601,48 +601,48 @@ function pfUI.uf:UpdateConfig()
|
||||
f.hpLeftText:SetJustifyH("LEFT")
|
||||
f.hpLeftText:SetParent(f.hp.bar)
|
||||
f.hpLeftText:ClearAllPoints()
|
||||
f.hpLeftText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*default_border, 1)
|
||||
f.hpLeftText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*default_border, 0)
|
||||
f.hpLeftText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*(default_border + f.config.txthpleftoffx), 1 + tonumber(f.config.txthpleftoffy))
|
||||
f.hpLeftText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*(default_border + f.config.txthpleftoffx), f.config.txthpleftoffy)
|
||||
|
||||
f.hpRightText:SetFontObject(GameFontWhite)
|
||||
f.hpRightText:SetFont(fontname, fontsize, fontstyle)
|
||||
f.hpRightText:SetJustifyH("RIGHT")
|
||||
f.hpRightText:SetParent(f.hp.bar)
|
||||
f.hpRightText:ClearAllPoints()
|
||||
f.hpRightText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*default_border, 1)
|
||||
f.hpRightText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*default_border, 0)
|
||||
f.hpRightText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*(default_border + f.config.txthprightoffx), 1 + tonumber(f.config.txthprightoffy))
|
||||
f.hpRightText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*(default_border + f.config.txthprightoffx), f.config.txthprightoffy)
|
||||
|
||||
f.hpCenterText:SetFontObject(GameFontWhite)
|
||||
f.hpCenterText:SetFont(fontname, fontsize, fontstyle)
|
||||
f.hpCenterText:SetJustifyH("CENTER")
|
||||
f.hpCenterText:SetParent(f.hp.bar)
|
||||
f.hpCenterText:ClearAllPoints()
|
||||
f.hpCenterText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*default_border, 1)
|
||||
f.hpCenterText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*default_border, 0)
|
||||
f.hpCenterText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*(default_border + f.config.txthpcenteroffx), 1 + tonumber(f.config.txthpcenteroffy))
|
||||
f.hpCenterText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*(default_border + f.config.txthpcenteroffx), f.config.txthpcenteroffy)
|
||||
|
||||
f.powerLeftText:SetFontObject(GameFontWhite)
|
||||
f.powerLeftText:SetFont(fontname, fontsize, fontstyle)
|
||||
f.powerLeftText:SetJustifyH("LEFT")
|
||||
f.powerLeftText:SetParent(f.power.bar)
|
||||
f.powerLeftText:ClearAllPoints()
|
||||
f.powerLeftText:SetPoint("TOPLEFT",f.power.bar, "TOPLEFT", 2*default_border, 1)
|
||||
f.powerLeftText:SetPoint("BOTTOMRIGHT",f.power.bar, "BOTTOMRIGHT", -2*default_border, 0)
|
||||
f.powerLeftText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*(default_border + f.config.txtpowerleftoffx), 1 + tonumber(f.config.txtpowerleftoffy))
|
||||
f.powerLeftText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*(default_border + f.config.txtpowerleftoffx), f.config.txtpowerleftoffy)
|
||||
|
||||
f.powerRightText:SetFontObject(GameFontWhite)
|
||||
f.powerRightText:SetFont(fontname, fontsize, fontstyle)
|
||||
f.powerRightText:SetJustifyH("RIGHT")
|
||||
f.powerRightText:SetParent(f.power.bar)
|
||||
f.powerRightText:ClearAllPoints()
|
||||
f.powerRightText:SetPoint("TOPLEFT",f.power.bar, "TOPLEFT", 2*default_border, 1)
|
||||
f.powerRightText:SetPoint("BOTTOMRIGHT",f.power.bar, "BOTTOMRIGHT", -2*default_border, 0)
|
||||
f.powerRightText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*(default_border + f.config.txtpowerrightoffx), 1 + tonumber(f.config.txtpowerrightoffy))
|
||||
f.powerRightText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*(default_border + f.config.txtpowerrightoffx), f.config.txtpowerrightoffy)
|
||||
|
||||
f.powerCenterText:SetFontObject(GameFontWhite)
|
||||
f.powerCenterText:SetFont(fontname, fontsize, fontstyle)
|
||||
f.powerCenterText:SetJustifyH("CENTER")
|
||||
f.powerCenterText:SetParent(f.power.bar)
|
||||
f.powerCenterText:ClearAllPoints()
|
||||
f.powerCenterText:SetPoint("TOPLEFT",f.power.bar, "TOPLEFT", 2*default_border, 1)
|
||||
f.powerCenterText:SetPoint("BOTTOMRIGHT",f.power.bar, "BOTTOMRIGHT", -2*default_border, 0)
|
||||
f.powerCenterText:SetPoint("TOPLEFT",f.hp.bar, "TOPLEFT", 2*(default_border + f.config.txtpowercenteroffx) + f.config.poffx, 1 + tonumber(f.config.txtpowercenteroffy))
|
||||
f.powerCenterText:SetPoint("BOTTOMRIGHT",f.hp.bar, "BOTTOMRIGHT", -2*(default_border + f.config.txtpowercenteroffx) + f.config.poffx, f.config.txtpowercenteroffy)
|
||||
|
||||
f.incHeal:SetHeight(f.config.height)
|
||||
f.incHeal:SetWidth(f.config.width)
|
||||
|
||||
Reference in New Issue
Block a user