mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 18:36:31 +01:00
Core/Auras: Removed triggering aura effect from SPELL_AURA_OVERRIDE_AUTOATTACK_WITH_MELEE_SPELL handling (paladin Crusading Strikes combines this with a proc aura on another effect on the same spell)
This commit is contained in:
@@ -2123,15 +2123,11 @@ void Unit::AttackerStateUpdate(Unit* victim, WeaponAttackType attType, bool extr
|
||||
victim = GetMeleeHitRedirectTarget(victim);
|
||||
|
||||
AuraEffectList const& meleeAttackOverrides = GetAuraEffectsByType(SPELL_AURA_OVERRIDE_AUTOATTACK_WITH_MELEE_SPELL);
|
||||
AuraEffect const* meleeAttackAuraEffect = nullptr;
|
||||
uint32 meleeAttackSpellId = 0;
|
||||
if (attType == BASE_ATTACK)
|
||||
{
|
||||
if (!meleeAttackOverrides.empty())
|
||||
{
|
||||
meleeAttackAuraEffect = meleeAttackOverrides.front();
|
||||
meleeAttackSpellId = meleeAttackAuraEffect->GetSpellEffectInfo().TriggerSpell;
|
||||
}
|
||||
meleeAttackSpellId = meleeAttackOverrides.front()->GetSpellEffectInfo().TriggerSpell;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -2140,13 +2136,10 @@ void Unit::AttackerStateUpdate(Unit* victim, WeaponAttackType attType, bool extr
|
||||
return aurEff->GetSpellEffectInfo().MiscValue != 0;
|
||||
});
|
||||
if (itr != meleeAttackOverrides.end())
|
||||
{
|
||||
meleeAttackAuraEffect = *itr;
|
||||
meleeAttackSpellId = meleeAttackAuraEffect->GetSpellEffectInfo().MiscValue;
|
||||
}
|
||||
meleeAttackSpellId = (*itr)->GetSpellEffectInfo().MiscValue;
|
||||
}
|
||||
|
||||
if (!meleeAttackAuraEffect)
|
||||
if (!meleeAttackSpellId)
|
||||
{
|
||||
CalcDamageInfo damageInfo;
|
||||
CalculateMeleeDamage(victim, &damageInfo, attType);
|
||||
@@ -2174,7 +2167,7 @@ void Unit::AttackerStateUpdate(Unit* victim, WeaponAttackType attType, bool extr
|
||||
}
|
||||
else
|
||||
{
|
||||
CastSpell(victim, meleeAttackSpellId, meleeAttackAuraEffect);
|
||||
CastSpell(victim, meleeAttackSpellId, true);
|
||||
|
||||
uint32 hitInfo = HITINFO_AFFECTS_VICTIM | HITINFO_NO_ANIMATION;
|
||||
if (attType == OFF_ATTACK)
|
||||
|
||||
Reference in New Issue
Block a user