Skip to content

Commit

Permalink
Merge pull request #970 from InDebt/priest-firelands
Browse files Browse the repository at this point in the history
[Priest] Fixes for Mastery and Sear refactor
  • Loading branch information
InDebt authored Aug 24, 2024
2 parents e70fadf + f71a735 commit 522a768
Show file tree
Hide file tree
Showing 4 changed files with 473 additions and 468 deletions.
10 changes: 5 additions & 5 deletions sim/death_knight/frost/TestFrost.results
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ dps_results: {
value: {
dps: 21998.53427
tps: 19961.6477
hps: 245.25882
hps: 245.25883
}
}
dps_results: {
Expand All @@ -336,15 +336,15 @@ dps_results: {
value: {
dps: 21944.09428
tps: 20055.84482
hps: 245.25882
hps: 245.25883
}
}
dps_results: {
key: "TestFrost-AllItems-DarkmoonCard:Hurricane-62051"
value: {
dps: 21351.64308
tps: 19499.4618
hps: 245.25882
hps: 245.25883
}
}
dps_results: {
Expand All @@ -368,7 +368,7 @@ dps_results: {
value: {
dps: 21150.92099
tps: 19199.08409
hps: 245.25882
hps: 245.25883
}
}
dps_results: {
Expand Down Expand Up @@ -1024,7 +1024,7 @@ dps_results: {
value: {
dps: 20899.85176
tps: 19038.60319
hps: 245.25882
hps: 245.25883
}
}
dps_results: {
Expand Down
24 changes: 12 additions & 12 deletions sim/priest/mind_sear.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,21 @@ func (priest *Priest) getMindSearTickSpell() *core.Spell {
config.ActionID = core.ActionID{SpellID: 48045}
config.ApplyEffects = func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
damage := priest.ClassSpellScaling * 0.23
for _, aoeTarget := range sim.Encounter.TargetUnits {

// Calc spell damage but deal as periodic for metric purposes
result := spell.CalcDamage(sim, target, damage, spell.OutcomeMagicHitAndCritNoHitCounter)
spell.DealPeriodicDamage(sim, result)
// Calc spell damage but deal as periodic for metric purposes
result := spell.CalcDamage(sim, aoeTarget, damage, spell.OutcomeMagicHitAndCritNoHitCounter)
spell.DealPeriodicDamage(sim, result)

// Adjust metrics just for Mind Sear as it is a edgecase and needs to be handled manually
if result.DidCrit() {
spell.SpellMetrics[result.Target.UnitIndex].CritTicks++
} else {
spell.SpellMetrics[result.Target.UnitIndex].Ticks++
// Adjust metrics just for Mind Sear as it is a edgecase and needs to be handled manually
if result.DidCrit() {
spell.SpellMetrics[result.Target.UnitIndex].CritTicks++
} else {
spell.SpellMetrics[result.Target.UnitIndex].Ticks++
}
}

spell.SpellMetrics[result.Target.UnitIndex].Casts--
spell.SpellMetrics[target.UnitIndex].Casts--
}
return priest.RegisterSpell(config)
}
Expand Down Expand Up @@ -65,9 +67,7 @@ func (priest *Priest) newMindSearSpell() *core.Spell {
TickLength: time.Second,
AffectedByCastSpeed: true,
OnTick: func(sim *core.Simulation, target *core.Unit, dot *core.Dot) {
for _, aoeTarget := range sim.Encounter.TargetUnits {
mindSearTickSpell.Cast(sim, aoeTarget)
}
mindSearTickSpell.Cast(sim, target)
},
}
config.ApplyEffects = func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
Expand Down
Loading

0 comments on commit 522a768

Please sign in to comment.