fix(Core/Spells): Include absorbed damage in PROC_SPELL_TYPE_DAMAGE classification#25314
Open
blinkysc wants to merge 1 commit intoazerothcore:masterfrom
Open
fix(Core/Spells): Include absorbed damage in PROC_SPELL_TYPE_DAMAGE classification#25314blinkysc wants to merge 1 commit intoazerothcore:masterfrom
blinkysc wants to merge 1 commit intoazerothcore:masterfrom
Conversation
…lassification Fully absorbed spell damage was classified as PROC_SPELL_TYPE_NO_DMG_HEAL instead of PROC_SPELL_TYPE_DAMAGE because GetDamage() returns 0 after absorb. This prevented proc trigger spells from firing on absorbed hits. In TrinityCore, procSpellType is determined before absorbs are applied (Spell.cpp checks m_damage > 0), so absorbed damage is correctly classified as DAMAGE. AC determines spellTypeMask after absorbs in Unit.cpp, so we also need to check GetAbsorb(). Fixes ICC Kinetic Bomb (spell 72059 Unstable) not proccing knockback (spell 72087) when hit by spells — melee worked because melee auto attacks bypass SpellTypeMask checks entirely. Closes azerothcore#25116
Contributor
|
Tested both melee and ranged attacks, work now! tyvm |
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:
This PR proposes changes to:
AI-assisted Pull Requests
Important
While the use of AI tools when preparing pull requests is not prohibited, contributors must clearly disclose when such tools have been used and specify the model involved.
Contributors are also expected to fully understand the changes they are submitting and must be able to explain and justify those changes when requested by maintainers.
Issues Addressed:
Prince Valanarbug #25116SOURCE:
The changes have been validated through:
Spell.cppwhereprocSpellTypeis determined before absorbs are applied (spell->m_damage > 0at line 2577), ensuring absorbed damage is classified asPROC_SPELL_TYPE_DAMAGE.Description
Problem
In
Unit::ProcDamageAndSpellFor,spellTypeMaskis determined after absorbs:When damage is fully absorbed,
GetDamage()returns 0, so the type becomesPROC_SPELL_TYPE_NO_DMG_HEAL. This causesspell_procentries withSpellTypeMask = PROC_SPELL_TYPE_DAMAGEto fail matching.In TrinityCore,
procSpellTypeis set inSpell.cppbased onspell->m_damage > 0before absorbs are applied, so absorbed hits are correctly classified asDAMAGE.Specific bug
ICC Kinetic Bomb has spell 72059 (Unstable) with
SPELL_AURA_PROC_TRIGGER_SPELL→ triggers 72087 (Kinetic Bomb Knockback). Thespell_procentry (identical in both AC and TC) hasSpellTypeMask = 1 (PROC_SPELL_TYPE_DAMAGE). Since the bomb's absorb aura (72054) absorbs 100% of damage, spell attacks result inGetDamage() == 0, the type becomesNO_DMG_HEAL, and the proc never fires. Melee auto-attacks bypass theSpellTypeMaskcheck entirely (not inSPELL_PROC_FLAG_MASK), which is why melee still works.Fix
Also check
GetAbsorb()when determiningspellTypeMask:Tests Performed:
This PR has been:
How to Test the Changes:
.go xyz 4660.49 2769.20 364.83 631(Blood Prince Council in ICC)Regression testing
Since this changes generic proc type classification, also verify:
Known Issues and TODO List: