fix(Core/Spells) reimplement SPELL_ATTR3_CAN_PROC_FROM_PROCS (#22072)

This commit is contained in:
Tereneckla
2025-05-10 19:52:06 +02:00
committed by GitHub
parent 83adff44e4
commit 7df7f2610e
2 changed files with 5 additions and 15 deletions

View File

@@ -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