Skip to content

Commit

Permalink
small multi shot code tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
kayla-glick committed Dec 24, 2024
1 parent 3c5b13a commit 12a4143
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions sim/hunter/multi_shot.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,16 +61,14 @@ func (hunter *Hunter) getMultiShotConfig(rank int, timer *core.Timer) core.Spell
BonusCoefficient: 1,

ApplyEffects: func(sim *core.Simulation, target *core.Unit, spell *core.Spell) {
curTarget := target

for hitIndex := int32(0); hitIndex < numHits; hitIndex++ {
baseDamage := baseDamage +
hunter.AutoAttacks.Ranged().CalculateNormalizedWeaponDamage(sim, spell.RangedAttackPower(target, false)) +
hunter.AmmoDamageBonus

results[hitIndex] = spell.CalcDamage(sim, curTarget, baseDamage, spell.OutcomeRangedHitAndCrit)
results[hitIndex] = spell.CalcDamage(sim, target, baseDamage, spell.OutcomeRangedHitAndCrit)

curTarget = sim.Environment.NextTargetUnit(curTarget)
target = sim.Environment.NextTargetUnit(target)
}

spell.WaitTravelTime(sim, func(s *core.Simulation) {
Expand Down

0 comments on commit 12a4143

Please sign in to comment.