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ILhuXgBO3MOuBqf6SNy5bvSXg6z7UcQqN9elpOIn2yJn0TGk0YvY(yOuTL)vHMn1wZ82D1dB3FLup60sioEUTVzDuUs2hdLQT8Vk2qZqCMjJjygBe
I made you a base to work off of.
Basically here is what I did. I made a basic text aura that triggered when I put a Rejuv on myself (you can change this for debuffs if needed). After that, I went to the 'Display tab' and made a custom function.
Code:
function()
local expirationTime, unitCaster, _, _, spellID = select(7, UnitBuff("player", "Rejuvenation"))
--Manually put in base duration of spell here
local spellDuration = 12
if spellID == 774 and unitCaster == "player" then
local spellTime = expirationTime - GetTime()
if spellTime > spellDuration * .3 then
return ("%.01f"):format(spellTime)
else
return ("%.01f"):format(spellTime) .. "!"
end
end
end
I hardcoded the duration of the spell so you always have the correct 30% remaining. Then I just returned the time left on the buff and concatenated a '!' if it was below 30%.
For you, you're going to have to use UnitDebuff instead and make sure that you have it set to 'target' as well as the spell you want to track. Find the spellID of your debuffs and set the base duration and you should be good to go. Let me know if you have any trouble.