Add new code snippets
This commit is contained in:
28
Complete Projects/BFA/Ignite.lua
Normal file
28
Complete Projects/BFA/Ignite.lua
Normal file
@@ -0,0 +1,28 @@
|
||||
--CLEU PLAYER_TARGET_CHANGED
|
||||
function(e, ...)
|
||||
if e == "COMBAT_LOG_EVENT_UNFILTERED" then
|
||||
if (select(2, ...) == "SPELL_AURA_APPLIED" or select(2, ...) == "SPELL_AURA_REFRESH" or select(2, ...) == "SPELL_PERIODIC_DAMAGE") and select(5, ...) == UnitName("player") and select(13, ...) == "Ignite" then
|
||||
return true
|
||||
end
|
||||
elseif e == "PLAYER_TARGET_CHANGED" then
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
||||
--DISPLAY
|
||||
function()
|
||||
local function UnitDebuffC(unit, spell)
|
||||
for i = 1, 40 do
|
||||
local name = UnitDebuff(unit, i, PLAYER)
|
||||
if name then
|
||||
if name == spell then
|
||||
return UnitDebuff(unit, i, PLAYER)
|
||||
end
|
||||
else
|
||||
return nil
|
||||
end
|
||||
end
|
||||
end
|
||||
local thing = select(16, UnitDebuffC("target", "Ignite"))
|
||||
if thing then return thing else return 0 end
|
||||
end
|
||||
Reference in New Issue
Block a user