Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
[dk] "doubled" RuneCost sizes so runes don't overflow in tests (e.g. a UUFFBB spell could be optimized to more than 3 death runes instead)
[dk] death runes are now spent preferring their original rune type, before falling back to the "generic" unholy -> frost -> blood order
The original rune types are determined by subtracting the optimized rune cost from the spell's default rune cost. For DKs, the latter is never changed, so this is fine. Alternatively, the optimized rune cost could additionally store those "blood-death", "frost-death", and "unholy-death" rune counts.
The used scheme has been tested to yield the same results as looking for "blood-death" runes within blood slots only, then "frost-death" runes within frost slots only, then "unholy-death" runes within unholy slots only, and finally looking for any remaining death runes in the "generic" order. The used scheme is very slightly faster, and requires less code changes.