fix(Core/Spells): Fix Rapid Recuperation, Rapid Killing, and auto-generate PROC_ATTR_REQ_SPELLMOD (#24830)
Co-authored-by: blinkysc <blinkysc@users.noreply.github.com>
This commit is contained in:
@@ -6563,12 +6563,6 @@ void AuraEffect::HandlePeriodicTriggerSpellAuraTick(Unit* target, Unit* caster)
|
||||
caster->CastSpell(target, triggerSpellId, false);
|
||||
return;
|
||||
}
|
||||
// Hunter - Rapid Recuperation
|
||||
case 56654:
|
||||
case 58882:
|
||||
int32 amount = int32(target->GetMaxPower(POWER_MANA) * GetAmount() / 100.0f);
|
||||
target->CastCustomSpell(target, triggerSpellId, &amount, nullptr, nullptr, true, nullptr, this);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -2073,6 +2073,20 @@ void SpellMgr::LoadSpellProcs()
|
||||
if (addTriggerFlag)
|
||||
procEntry.AttributesMask |= PROC_ATTR_TRIGGERED_CAN_PROC;
|
||||
|
||||
// Modifier auras with charges should require spellmod validation
|
||||
if (spellInfo->ProcCharges)
|
||||
{
|
||||
for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i)
|
||||
{
|
||||
if (spellInfo->Effects[i].IsAura(SPELL_AURA_ADD_FLAT_MODIFIER) ||
|
||||
spellInfo->Effects[i].IsAura(SPELL_AURA_ADD_PCT_MODIFIER))
|
||||
{
|
||||
procEntry.AttributesMask |= PROC_ATTR_REQ_SPELLMOD;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Calculate DisableEffectsMask for effects that shouldn't trigger procs
|
||||
uint32 nonProcMask = 0;
|
||||
for (uint8 i = 0; i < MAX_SPELL_EFFECTS; ++i)
|
||||
|
||||
Reference in New Issue
Block a user