unitframes: add new unitstring for raidframes

This commit is contained in:
shagu
2021-12-13 03:15:13 +01:00
parent 88af6b7e52
commit c38a55a89e
2 changed files with 10 additions and 0 deletions
+9
View File
@@ -2362,6 +2362,15 @@ function pfUI.uf:GetStatusValue(unit, pos)
else
return unit:GetColor("health") .. pfUI.api.Abbreviate(health)
end
elseif config == "namehealthbreak" then
local health = ceil(rhp - rhpmax)
if UnitIsDead(unitstr) then
return unit:GetColor("health") .. DEAD
elseif health == 0 then
return unit:GetColor("unit") .. UnitName(unitstr)
else
return unit:GetColor("unit") .. UnitName(unitstr) .. "\n" .. unit:GetColor("health") .. pfUI.api.Abbreviate(-health)
end
elseif config == "shortnamehealth" then
local health = ceil(rhp - rhpmax)
if UnitIsDead(unitstr) then
+1
View File
@@ -1030,6 +1030,7 @@ pfUI:RegisterModule("gui", "vanilla:tbc", function ()
"level:" .. T["Level"],
"class:" .. T["Class"],
"namehealth:" .. T["Name | Health Missing"],
"namehealthbreak:" .. T["Name (Linebreak) -Health Missing"],
"shortnamehealth:" .. T["Name (Short) | Health Missing"],
"healthdyn:" .. T["Health - Auto"],
"health:" .. T["Health - Current"],