Skip to content

Instantly share code, notes, and snippets.

View martinjlowm's full-sized avatar
🌮
HACKERMAN

Martin Jesper Low Madsen martinjlowm

🌮
HACKERMAN
View GitHub Profile
function Timer:UpdateText(forceStyleUpdate)
--if there's time left on the clock, then update the timer text
--otherwise stop the timer
local remain = self.duration - (GetTime() - self.start)
if remain > 0 then
--hide text if it's too small to display
--check again in one second
if (self:GetEffectiveScale() * self.fontSize / UIParent:GetScale()) < OmniCC:GetMinFontSize() then
self.text:Hide()
self.nextUpdate = 1
if (select(2, UnitClass("player")) ~= "PRIEST") then
return
end
local _, bindings = ...
local priestBase = {
[1] = "s|Holy Fire",
[2] = "s|Smite",
[3] = "s|Mind Blast",