*Fix Penance.
*Remove some hacks from channeled spells related code. --HG-- branch : trunk
This commit is contained in:
+3
-2
@@ -2066,8 +2066,9 @@ void Spell::prepare(SpellCastTargets const* targets, Aura* triggeredByAura)
|
|||||||
|
|
||||||
// set timer base at cast time
|
// set timer base at cast time
|
||||||
ReSetTimer();
|
ReSetTimer();
|
||||||
|
//Containers for channeled spells have to be set
|
||||||
if(m_IsTriggeredSpell)
|
//TODO:Apply this to all casted spells if needed
|
||||||
|
if(m_IsTriggeredSpell && !IsChanneledSpell(m_spellInfo))
|
||||||
cast(true);
|
cast(true);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1975,25 +1975,6 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (caster && m_removeMode == AURA_REMOVE_BY_DEATH)
|
|
||||||
{
|
|
||||||
// Stop caster Arcane Missle chanelling on death
|
|
||||||
if (m_spellProto->SpellFamilyName == SPELLFAMILY_MAGE &&
|
|
||||||
m_spellProto->SpellFamilyFlags[0] & 0x800)
|
|
||||||
{
|
|
||||||
caster->InterruptSpell(CURRENT_CHANNELED_SPELL);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
// Stop caster Penance chanelling on death
|
|
||||||
if (m_spellProto->SpellFamilyName == SPELLFAMILY_PRIEST &&
|
|
||||||
m_spellProto->SpellFamilyFlags[2] & 0x00000080)
|
|
||||||
{
|
|
||||||
caster->InterruptSpell(CURRENT_CHANNELED_SPELL);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
// some auras remove at aura remove
|
// some auras remove at aura remove
|
||||||
if(GetEffIndex()==0 && m_target->GetTypeId()==TYPEID_PLAYER)
|
if(GetEffIndex()==0 && m_target->GetTypeId()==TYPEID_PLAYER)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1894,8 +1894,8 @@ void Spell::EffectTriggerRitualOfSummoning(uint32 i)
|
|||||||
targets.setUnitTarget( unitTarget);
|
targets.setUnitTarget( unitTarget);
|
||||||
spell->prepare(&targets);
|
spell->prepare(&targets);
|
||||||
|
|
||||||
m_caster->SetCurrentCastedSpell(spell);
|
//m_caster->SetCurrentCastedSpell(spell);
|
||||||
spell->m_selfContainer = &(m_caster->m_currentSpells[spell->GetCurrentContainer()]);
|
//spell->m_selfContainer = &(m_caster->m_currentSpells[spell->GetCurrentContainer()]);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -4174,7 +4174,7 @@ void Unit::RemoveAura(AuraMap::iterator &i, AuraRemoveMode mode)
|
|||||||
&& AurSpellInfo->EffectApplyAuraName[Aur->GetEffIndex()]!= SPELL_AURA_DUMMY)
|
&& AurSpellInfo->EffectApplyAuraName[Aur->GetEffIndex()]!= SPELL_AURA_DUMMY)
|
||||||
//don't stop channeling of scripted spells (this is actually a hack)
|
//don't stop channeling of scripted spells (this is actually a hack)
|
||||||
{
|
{
|
||||||
caster->m_currentSpells[CURRENT_CHANNELED_SPELL]->cancel();
|
caster->InterruptSpell(CURRENT_CHANNELED_SPELL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user