Fix element upgrade bonus values shifted up one level for +1 to +9 - #162
Open
muzsor wants to merge 1 commit into
Open
Fix element upgrade bonus values shifted up one level for +1 to +9#162muzsor wants to merge 1 commit into
muzsor wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Hello!
This pull request fixes the
elementAttack/elementAttackStrong/elementDefensecolumns inUpgradeBonus.jsonbeing shifted one level upward for upgrade levels 1–9.The columns were dropped in c098a6b and restored in f53e238, but off by one — each level received the value of the level above it. Level 10 kept its correct cap values, so +9 and +10 currently give identical element bonuses.
Impact on the auto-attack element factor in
getElementDamageFactorAutoAttack(vs a monster,defenseLevel = 1, attacker element strong against the target):elementDefensemirrorselementAttack, so weak-side penalties are too deep as well. The fix restores all three columns for levels 1–9; level 10 and the padded 11–20 rows are untouched (lookups clamp atMath.min(level, 10)).Verified against the pre-c098a6b data (2fffc01): levels 1–10 now match field-by-field and the computed element factors reproduce the pre-shift behavior exactly.