-
Notifications
You must be signed in to change notification settings - Fork 132
/
death_coil.go
63 lines (53 loc) · 2.28 KB
/
death_coil.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
package deathknight
import (
"github.com/wowsims/wotlk/sim/core"
"github.com/wowsims/wotlk/sim/core/proto"
)
var DeathCoilActionID = core.ActionID{SpellID: 49895}
func (dk *Deathknight) registerDeathCoilSpell() {
bonusFlatDamage := 443 + dk.sigilOfTheWildBuckBonus() + dk.sigilOfTheVengefulHeartDeathCoil()
dk.DeathCoil = dk.RegisterSpell(core.SpellConfig{
ActionID: DeathCoilActionID,
Flags: core.SpellFlagAPL,
SpellSchool: core.SpellSchoolShadow,
ProcMask: core.ProcMaskSpellDamage,
RuneCost: core.RuneCostOptions{
RunicPowerCost: 40,
},
Cast: core.CastConfig{
DefaultCast: core.Cast{
GCD: core.GCDDefault,
},
},
BonusCritRating: dk.darkrunedBattlegearCritBonus() * core.CritRatingPerCritChance,
DamageMultiplier: (1 + float64(dk.Talents.Morbidity)*0.05) +
core.TernaryFloat64(dk.HasMajorGlyph(proto.DeathknightMajorGlyph_GlyphOfDarkDeath), 0.15, 0.0),
CritMultiplier: dk.DefaultMeleeCritMultiplier(),
ThreatMultiplier: 1.0,
ApplyEffects: func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
baseDamage := (bonusFlatDamage + 0.15*dk.getImpurityBonus(spell)) * dk.RoRTSBonus(target)
result := spell.CalcDamage(sim, target, baseDamage, spell.OutcomeMagicHitAndCrit)
if result.Landed() && dk.Talents.UnholyBlight {
dk.procUnholyBlight(sim, target, result.Damage)
}
spell.DealDamage(sim, result)
},
})
}
func (dk *Deathknight) registerDrwDeathCoilSpell() {
bonusFlatDamage := 443 + dk.sigilOfTheWildBuckBonus() + dk.sigilOfTheVengefulHeartDeathCoil()
dk.RuneWeapon.DeathCoil = dk.RuneWeapon.RegisterSpell(core.SpellConfig{
ActionID: DeathCoilActionID,
SpellSchool: core.SpellSchoolShadow,
ProcMask: core.ProcMaskSpellDamage,
BonusCritRating: dk.darkrunedBattlegearCritBonus() * core.CritRatingPerCritChance,
DamageMultiplier: (1.0 + float64(dk.Talents.Morbidity)*0.05) *
core.TernaryFloat64(dk.HasMajorGlyph(proto.DeathknightMajorGlyph_GlyphOfDarkDeath), 1.15, 1.0),
CritMultiplier: dk.RuneWeapon.DefaultMeleeCritMultiplier(),
ThreatMultiplier: 1.0,
ApplyEffects: func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
baseDamage := bonusFlatDamage + 0.15*dk.RuneWeapon.getImpurityBonus(spell)
spell.CalcAndDealDamage(sim, target, baseDamage, spell.OutcomeMagicHitAndCrit)
},
})
}