mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 22:37:02 +00:00
[9530] Fixed check for SPELL_AURA_ALLOW_ONLY_ABILITY
Also remove public access to SpellAura::m_spellmod for avoid another hacks with it use. Spellmods only for Player::ApplySpellMod use.
This commit is contained in:
parent
bbdb7bb09c
commit
3cf9e47110
4 changed files with 2 additions and 14 deletions
|
|
@ -5141,7 +5141,7 @@ SpellCastResult Spell::CheckCasterAuras() const
|
|||
Unit::AuraList const& casingLimit = m_caster->GetAurasByType(SPELL_AURA_ALLOW_ONLY_ABILITY);
|
||||
for(Unit::AuraList::const_iterator itr = casingLimit.begin(); itr != casingLimit.end(); ++itr)
|
||||
{
|
||||
if(!IsAffectedByAura(*itr))
|
||||
if(!(*itr)->isAffectedOnSpell(m_spellInfo))
|
||||
{
|
||||
prevented_reason = SPELL_FAILED_CASTER_AURASTATE;
|
||||
break;
|
||||
|
|
@ -5953,14 +5953,6 @@ void Spell::UpdatePointers()
|
|||
m_targets.Update(m_caster);
|
||||
}
|
||||
|
||||
bool Spell::IsAffectedByAura(Aura *aura) const
|
||||
{
|
||||
if(SpellModifier* mod = aura->getAuraSpellMod())
|
||||
return mod->isAffectedOnSpell(m_spellInfo);
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
bool Spell::CheckTargetCreatureType(Unit* target) const
|
||||
{
|
||||
uint32 spellCreatureTargetMask = m_spellInfo->TargetCreatureType;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue