-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsunKingsBlessing.lua
55 lines (45 loc) · 1.19 KB
/
sunKingsBlessing.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
-- TSU: TRIGGER:1
function(allstates, event, _, updatedTriggerStates)
if event == "OPTIONS" then
return false
end
local state = allstates[""]
if state == nil then
state = {
["show"] = true,
["changed"] = true,
["progressType"] = "static",
["stacks"] = 0,
["value"] = 0,
["total"] = 8
}
allstates[""] = state
end
if event == "STATUS" then
return true
end
local triggerState = updatedTriggerStates[""]
if triggerState == nil then
state["stacks"] = 0
state["value"] = state["stacks"]
state["changed"] = true
return true
end
if triggerState["spellId"] == 383883 then -- Fury of the Sun King
state["stacks"] = 8
state["value"] = state["stacks"]
state["changed"] = true
return true
else -- Sun King's Blessing
state["stacks"] = triggerState["stacks"]
state["value"] = state["stacks"]
state["changed"] = true
return true
end
end
-- custom variables
{
["value"] = true,
["total"] = true,
["stacks"] = true
}