Support "+X% to Fire Spell Critical Hit Chance" affix#2246
Open
luther-rotmg wants to merge 2 commits into
Open
Support "+X% to Fire Spell Critical Hit Chance" affix#2246luther-rotmg wants to merge 2 commits into
luther-rotmg wants to merge 2 commits into
Conversation
The "of Xoph" suffix ("+X% to Fire Spell Critical Hit Chance", mod group
FireSpellBaseCriticalChance) had no modNameList entry, so the "fire spell"
qualifier was left unparsed and the affix did nothing.
Add a modNameList mapping to CritChance (BASE) restricted to fire spells via
ModFlag.Spell + KeywordFlag.Fire, matching the codebase's existing "fire spells"
convention in preFlagList. Add a parse regression test.
Closes PathOfBuildingCommunity#2226
Contributor
|
This should be done differently. It should be under |
Contributor
Author
Gotcha, give me a chance to rework it. |
… entry Per review feedback: rather than a single modNameList entry for "fire spell critical hit chance", add fire/cold/lightning/chaos spell to modFlagList's Skill types section. These compose with any stat (critical hit chance, critical damage bonus, ...) through the normal modName parse, and future-proof the other elements. Update the regression test to assert the tag composes with both CritChance and CritMultiplier and works per element.
Contributor
Author
|
Thanks for the review — agreed, that's a cleaner approach. Pushed an update:
Tests + ModCache check are green. |
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.
Closes #2226.
Problem
The "of Xoph" suffix —
+X% to Fire Spell Critical Hit Chance(mod groupFireSpellBaseCriticalChance) — had nomodNameListentry, so thefire spellqualifier was left unparsed and the affix granted nothing.Fix
Adds a
modNameListmapping toCritChance(BASE) restricted to fire spells viaModFlag.Spell+KeywordFlag.Fire, matching the existingfire spellsconvention already used inpreFlagList.Testing
Adds a parse regression test in
spec/System/TestItemParse_spec.lua:+5% to Fire Spell Critical Hit Chancegrants +5 base crit to fire spells, and 0 to attacks / 0 to cold spells. The full test suite and the ModCache check pass.