View Single Post
10-15-17, 01:33 PM   #6
p3lim
A Pyroguard Emberseer
 
p3lim's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2007
Posts: 1,710
Originally Posted by Tim View Post
Also, if you're only going to be monitoring your own auras you can get rid of your 1st player check line and change your UNIT_AURA registering to frame:RegisterEvent("UNIT_AURA", "player")
You forgot to replace RegisterEvent with RegisterUnitEvent, RegisterEvent doesn't take additional arguments.

Code:
local f = CreateFrame("Frame")
f:RegisterUnitEvent("UNIT_AURA", "player")
f:SetScript("OnEvent", function(self, event, ...)
   if UnitBuff("player", "Nightfall") then
      SpellActivationOverlay_ShowOverlay(SpellActivationOverlayFrame, 248814, "TEXTURES\\SPELLACTIVATIONOVERLAYS\\GENERICTOP_01.BLP", "TOP", 1.2, 139, 65, 239, false, false)
   else
      SpellActivationOverlay_HideOverlays(SpellActivationOverlayFrame, 248814)
   end
end)
  Reply With Quote