-
Notifications
You must be signed in to change notification settings - Fork 135
/
ghoul_frenzy.go
81 lines (71 loc) · 2.09 KB
/
ghoul_frenzy.go
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
package deathknight
import (
"time"
"github.com/wowsims/wotlk/sim/core"
)
func (dk *Deathknight) registerGhoulFrenzySpell() {
if !dk.Talents.GhoulFrenzy {
return
}
dk.GhoulFrenzy = dk.RegisterSpell(core.SpellConfig{
ActionID: core.ActionID{SpellID: 63560},
SpellSchool: core.SpellSchoolShadow,
ProcMask: core.ProcMaskSpellHealing,
Flags: core.SpellFlagAPL,
RuneCost: core.RuneCostOptions{
UnholyRuneCost: 1,
RunicPowerGain: 10,
},
Cast: core.CastConfig{
DefaultCast: core.Cast{
GCD: core.GCDDefault,
},
CD: core.Cooldown{
Timer: dk.NewTimer(),
Duration: time.Second * 10,
},
},
ExtraCastCondition: func(sim *core.Simulation, target *core.Unit) bool {
return dk.Ghoul.IsEnabled()
},
DamageMultiplier: 1,
ThreatMultiplier: 1,
Hot: core.DotConfig{
SelfOnly: true,
Aura: core.Aura{
Label: "Ghoul Frenzy Hot",
},
NumberOfTicks: 5,
TickLength: time.Second * 6,
OnSnapshot: func(sim *core.Simulation, target *core.Unit, dot *core.Dot, _ bool) {
dot.SnapshotBaseDamage = 0.06 * dk.Ghoul.MaxHealth()
dot.SnapshotAttackerMultiplier = dot.Spell.CasterHealingMultiplier()
},
OnTick: func(sim *core.Simulation, target *core.Unit, dot *core.Dot) {
dot.CalcAndDealPeriodicSnapshotHealing(sim, &dk.Ghoul.Unit, dot.OutcomeTick)
},
},
ApplyEffects: func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
dk.GhoulFrenzyAura.Activate(sim)
dk.Ghoul.GhoulFrenzyAura.Activate(sim)
spell.SpellMetrics[target.UnitIndex].Hits++
spell.SelfHot().Apply(sim)
},
})
dk.GhoulFrenzyAura = dk.RegisterAura(core.Aura{
ActionID: core.ActionID{SpellID: 63560},
Label: "Ghoul Frenzy",
Duration: time.Second * 30.0,
})
dk.Ghoul.GhoulFrenzyAura = dk.Ghoul.RegisterAura(core.Aura{
ActionID: core.ActionID{SpellID: 63560},
Label: "Ghoul Frenzy",
Duration: time.Second * 30.0,
OnGain: func(aura *core.Aura, sim *core.Simulation) {
dk.Ghoul.MultiplyMeleeSpeed(sim, 1.25)
},
OnExpire: func(aura *core.Aura, sim *core.Simulation) {
dk.Ghoul.MultiplyMeleeSpeed(sim, 1/1.25)
},
})
}