nameplates: add option to show health in percent

This commit is contained in:
shagu
2020-05-03 13:38:46 +02:00
parent 0f18715fab
commit e2152a0326
3 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -401,7 +401,7 @@ pfUI:RegisterModule("nameplates", "vanilla:tbc", function ()
rhp, rhpmax, estimated = pfUI.libhealth:GetUnitHealthByName(name,level,tonumber(hp),tonumber(hpmax))
end
if estimated or hpmax > 100 then
if C.nameplates.alwaysperc == "0" and ( estimated or hpmax > 100 ) then
plate.health.text:SetText(string.format("%s / %s", Abbreviate(rhp), Abbreviate(rhpmax)))
else
plate.health.text:SetText(string.format("%s%%", hp))