Skip to content

Commit

Permalink
Merge pull request #3849 from wowsims/apl
Browse files Browse the repository at this point in the history
Fix prepull warnings attribution bug
  • Loading branch information
jimmyt857 authored Oct 8, 2023
2 parents fec4d75 + 200b8c7 commit 8a1ccb1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sim/core/apl.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@ func (unit *Unit) newAPLRotation(config *proto.APLRotation) *APLRotation {
}

// Parse prepull actions
for prepullIdx, prepullItem := range config.PrepullActions {
for i, prepullItem := range config.PrepullActions {
prepullIdx := i // Save to local variable for correct lambda capture behavior
rotation.doAndRecordWarnings(&rotation.prepullWarnings[prepullIdx], true, func() {
if !prepullItem.Hide {
doAtVal := rotation.newAPLValue(prepullItem.DoAtValue)
Expand Down

0 comments on commit 8a1ccb1

Please sign in to comment.