Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if not trigger.Loaded then
- local name = trigger.Icon:GetName()
- name = name:sub(16)
- if name:sub(0,1) == " " then name = name:sub(2) end -- handle at lest one whitespace
- trigger.tMyData = {}
- trigger.Loaded = true
- trigger.OnUnitCreated = (function(self, unit)
- -- if you change the name of the aura to track another mob you need to reloadui
- if unit:GetName() == name then
- trigger.tMyData.unit = unit
- end
- end)
- Apollo.RegisterEventHandler("UnitCreated", "OnUnitCreated", trigger)
- end
- local unit = trigger.tMyData.unit
- if unit then
- local nIA = unit:GetInterruptArmorMax()
- if nIA then
- trigger.Stacks = nIA
- return nIA > 0
- end
- end
Advertisement