mirror of
https://github.com/brues-code/pfUI.git
synced 2026-10-11 08:00:01 +00:00
unitframes: add custom frame configurations
This commit is contained in:
@@ -271,6 +271,25 @@ function pfUI:LoadConfig()
|
||||
pfUI:UpdateConfig("unitframes", "pet", "txtcenter", "name")
|
||||
pfUI:UpdateConfig("unitframes", "pet", "txtright", "none")
|
||||
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "visible", "1")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "portrait", "bar")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "width", "200")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "height", "50")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "pheight", "10")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "pspace", "-3")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "buffs", "top")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "buffsize", "20")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "debuffs", "top")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "debuffsize", "20")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "invert_healthbar", "0")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "buff_indicator", "0")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "debuff_indicator", "0")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "clickcast", "0")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "faderange", "0")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "txtleft", "unit")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "txtcenter", "none")
|
||||
pfUI:UpdateConfig("unitframes", "fallback", "txtright", "healthdyn")
|
||||
|
||||
pfUI:UpdateConfig("bars", nil, "icon_size", "20")
|
||||
pfUI:UpdateConfig("bars", nil, "background", "1")
|
||||
pfUI:UpdateConfig("bars", nil, "glowrange", "1")
|
||||
|
||||
+1
-19
@@ -1,23 +1,5 @@
|
||||
pfUI.uf = CreateFrame("Frame",nil,UIParent)
|
||||
|
||||
local uf_defaults = {
|
||||
visible = "1",
|
||||
portrait = "bar",
|
||||
width = "200",
|
||||
height = "50",
|
||||
pheight = "10",
|
||||
pspace = "-3",
|
||||
buffs = "top",
|
||||
buffsize = "20",
|
||||
debuffs = "top",
|
||||
debuffsize = "20",
|
||||
invert_healthbar = "0",
|
||||
buff_indicator = "0",
|
||||
debuff_indicator = "0",
|
||||
clickcast = "0",
|
||||
faderange = "0",
|
||||
}
|
||||
|
||||
local pfValidUnits = {}
|
||||
pfValidUnits["player"] = true
|
||||
pfValidUnits["target"] = true
|
||||
@@ -68,7 +50,7 @@ function pfUI.uf:CreateUnitFrame(unit, id, config, tick)
|
||||
|
||||
f.label = unit
|
||||
f.id = id
|
||||
f.config = config or uf_defaults
|
||||
f.config = config or pfUI_config.unitframes.fallback
|
||||
f.tick = tick
|
||||
|
||||
if f.config.visible ~= "1" then
|
||||
|
||||
Reference in New Issue
Block a user