Add new code snippets
This commit is contained in:
27
Complete Projects/BFA/Azerite Power Energize.lua
Normal file
27
Complete Projects/BFA/Azerite Power Energize.lua
Normal file
@@ -0,0 +1,27 @@
|
||||
--COMBAT_LOG_EVENT_UNFILTERED PLAYER_REGEN_DISABLED
|
||||
function(e, ...)
|
||||
if e == "COMBAT_LOG_EVENT_UNFILTERED" then
|
||||
local se = select(2, ...)
|
||||
if se == "SPELL_ENERGIZE" then
|
||||
local caster = select(9, ...)
|
||||
if caster == UnitName("player") then
|
||||
local spell = select(13, ...)
|
||||
if spell == "Lucid Dreams" then
|
||||
local amount = select(15, ...)
|
||||
aura_env.amount = aura_env.amount + amount
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
elseif e == "PLAYER_REGEN_DISABLED" then
|
||||
aura_env.amount = 0
|
||||
end
|
||||
end
|
||||
|
||||
--DISPLAY
|
||||
function()
|
||||
return aura_env.amount
|
||||
end
|
||||
|
||||
--INIT
|
||||
aura_env.amount = 0
|
||||
Reference in New Issue
Block a user