Thread: Stuf + Threat
View Single Post
08-13-11, 05:27 PM   #39
Nibelheim
local roygbi-
 
Nibelheim's Avatar
AddOn Author - Click to view addons
Join Date: Jan 2010
Posts: 1,600
Code:
function(unit)
    local _, _, threatpct, _, threatvalue = UnitDetailedThreatSituation(unit, "target")
    if threatvalue then
        return "|cffff0000%d|r", floor(threatpct)
    else
        return ""
    end
end
If you make this a LuaText on the Player frame, and use Seerah's OnUpdate instructions, it should work.

LuaTexts can be set to run (a slightly throttled, iirc) OnUpdate if you check the "frequent updates" box.
May have to adjust the |cffff0000 (format is |caarrggbb) if the red color is off. Or someone may know Stuf's Health Color variable.
  Reply With Quote