Core/Auras: Fix hunter periodic damage critical bonus calculation#463
Open
gonzo1247 wants to merge 2 commits intoThe-Cataclysm-Preservation-Project:masterfrom
Open
Core/Auras: Fix hunter periodic damage critical bonus calculation#463gonzo1247 wants to merge 2 commits intoThe-Cataclysm-Preservation-Project:masterfrom
gonzo1247 wants to merge 2 commits intoThe-Cataclysm-Preservation-Project:masterfrom
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.
Changes proposed:
Certain Hunter periodic spells (e.g. Serpent Sting, Black Arrow) were using the melee/ranged critical damage baseline (200%) due to being classified with SPELL_DAMAGE_CLASS_RANGED.
However, these spells are periodic in nature and should follow the magical critical damage baseline (150%), as intended by game mechanics.
Because of this, talents like Toxicology (82832 / 82833), which increase critical damage of these effects by 50% / 100%, had little to no effect, since the spells were already dealing 200% critical damage by default.
This change ensures that:
Example:
Before:
After:
IsReducedPeriodicCritDamageSpell is used to explicitly identify Hunter periodic spells that should use the reduced periodic critical damage baseline (150%).
These spells are flagged as SPELL_DAMAGE_CLASS_RANGED and would normally follow the 200% melee/ranged critical damage path. However, they are intended exceptions and should instead use the reduced 150% baseline.
A generic solution is not feasible here, as there are no reliable shared attributes that distinguish these spells without introducing unintended side effects. Therefore, an explicit spell-based check is used to ensure correct behavior.
Tests performed: (Does it build, tested in-game, etc)
Build has been tested in-game using the Toxicology talent (82832 / 82833), both with and without it.
Results:
This confirms that Toxicology now correctly affects Serpent Sting and Black Arrow as intended.