[11181] Small optimization for [11179]

This commit is contained in:
zergtmn 2011-02-17 19:13:39 +05:00
parent 06d36feed2
commit 57ebd5371d
2 changed files with 3 additions and 3 deletions

View file

@ -6554,9 +6554,9 @@ void Spell::EffectScriptEffect(SpellEffectIndex eff_idx)
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_UNIT)
return;
if (Aura* pAura = unitTarget->GetAura(m_spellInfo->Id, EFFECT_INDEX_0))
if (SpellAuraHolder* pHolder = unitTarget->GetSpellAuraHolder(m_spellInfo->Id))
{
if (pAura->GetStackAmount() >= m_spellInfo->StackAmount - 1)
if (pHolder->GetStackAmount() + 1 >= m_spellInfo->StackAmount)
{
// Gluttonous Lurkers: Summon Gorged Lurking Basilisk
unitTarget->CastSpell(m_caster, 50928, true);