From 7df7f2610ec86da20637ff58dc7eb013291547bf Mon Sep 17 00:00:00 2001 From: Tereneckla Date: Sat, 10 May 2025 19:52:06 +0200 Subject: [PATCH] fix(Core/Spells) reimplement SPELL_ATTR3_CAN_PROC_FROM_PROCS (#22072) --- src/server/game/Entities/Unit/Unit.cpp | 14 +++++--------- src/server/game/Spells/SpellInfoCorrections.cpp | 6 ------ 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index c0bb9e8db..7085f0b5b 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -16232,10 +16232,6 @@ void Unit::ProcDamageAndSpellFor(bool isVictim, Unit* target, uint32 procFlag, u continue; } - // Triggered spells not triggering additional spells - //bool triggered = !spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_FROM_PROCS) ? - // (procExtra & PROC_EX_INTERNAL_TRIGGERED && !(procFlag & PROC_FLAG_DONE_TRAP_ACTIVATION)) : false; - bool hasTriggeredProc = false; for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i) { @@ -17480,11 +17476,11 @@ bool Unit::IsTriggeredAtSpellProcEvent(Unit* victim, Aura* aura, WeaponAttackTyp return false; // Additional checks for triggered spells (ignore trap casts) - //if (procExtra & PROC_EX_INTERNAL_TRIGGERED && !(procFlag & PROC_FLAG_DONE_TRAP_ACTIVATION)) - //{ - // if (!spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_TRIGGERED)) - // return false; - //} + if (eventInfo.GetHitMask() & PROC_EX_INTERNAL_TRIGGERED && !(EventProcFlag & PROC_FLAG_DONE_TRAP_ACTIVATION)) + { + if (!spellProto->HasAttribute(SPELL_ATTR3_CAN_PROC_FROM_PROCS)) + return false; + } // Xinef: additional check for player auras - only player spells can trigger player proc auras // Xinef: skip victim auras diff --git a/src/server/game/Spells/SpellInfoCorrections.cpp b/src/server/game/Spells/SpellInfoCorrections.cpp index b59d4e942..3c3c89609 100644 --- a/src/server/game/Spells/SpellInfoCorrections.cpp +++ b/src/server/game/Spells/SpellInfoCorrections.cpp @@ -4903,12 +4903,6 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->AttributesEx7 |= SPELL_ATTR7_TREAT_AS_NPC_AOE; }); - // Heal (Crystal Spire of Karabor) - ApplySpellFix({ 40972 }, [](SpellInfo* spellInfo) - { - spellInfo->AttributesEx3 |= SPELL_ATTR3_SUPPRESS_CASTER_PROCS; - }); - // Torch (Death Knights near the Chapel) ApplySpellFix({ 52953 }, [](SpellInfo* spellInfo) {