-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathancientAftershock.lua
36 lines (31 loc) · 1.12 KB
/
ancientAftershock.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
-------------------------------------------------------------------------------
-- trigger (TSU): PLAYER_EQUIPMENT_CHANGED, UNIT_SPELLCAST_SUCCEEDED:player
function(allstates, event, ...)
if event == "PLAYER_EQUIPMENT_CHANGED" then
aura_env.isWearingNaturesFury = WeakAuras.CheckForItemBonusId(7471)
else
local unit, castGuid, spellId = ...
if spellId == 325886 then
local state = allstates[1]
if state == nil then
state = {}
allstates[1] = state
end
state.show = true
state.isWearingNaturesFury = aura_env.isWearingNaturesFury
state.progressType = "timed"
state.duration = 12 + (state.isWearingNaturesFury and 3 or 0)
state.expirationTime = GetTime() + state.duration
state.autoHide = true
state.changed = true
return true
end
end
end
-------------------------------------------------------------------------------
-- custom variables
{
["expirationTime"] = true,
["duration"] = true,
["isWearingNaturesFury"] = "bool",
}