*Fix the bug that devastate requires double rage.
*Fix the bug that cloak of shadows removes postive buffs. --HG-- branch : trunk
This commit is contained in:
@@ -2496,8 +2496,11 @@ void Spell::cast(bool skipCheck)
|
|||||||
// CAST SPELL
|
// CAST SPELL
|
||||||
SendSpellCooldown();
|
SendSpellCooldown();
|
||||||
|
|
||||||
|
if(!m_IsTriggeredSpell)
|
||||||
|
{
|
||||||
TakePower();
|
TakePower();
|
||||||
TakeReagents(); // we must remove reagents before HandleEffects to allow place crafted item in same slot
|
TakeReagents(); // we must remove reagents before HandleEffects to allow place crafted item in same slot
|
||||||
|
}
|
||||||
|
|
||||||
if(m_spellState == SPELL_STATE_FINISHED) // stop cast if spell marked as finish somewhere in Take*/FillTargetMap
|
if(m_spellState == SPELL_STATE_FINISHED) // stop cast if spell marked as finish somewhere in Take*/FillTargetMap
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1817,17 +1817,18 @@ void Spell::EffectTriggerSpell(uint32 i)
|
|||||||
// Cloak of Shadows
|
// Cloak of Shadows
|
||||||
case 35729 :
|
case 35729 :
|
||||||
{
|
{
|
||||||
m_caster->RemoveAurasWithDispelType(DISPEL_ALL);
|
uint32 dispelMask = GetDispellMask(DISPEL_ALL);
|
||||||
Unit::AuraMap& Auras = m_caster->GetAuras();
|
Unit::AuraMap& Auras = m_caster->GetAuras();
|
||||||
for(Unit::AuraMap::iterator iter = Auras.begin(); iter != Auras.end(); ++iter)
|
for(Unit::AuraMap::iterator iter = Auras.begin(); iter != Auras.end(); ++iter)
|
||||||
{
|
{
|
||||||
// remove all harmful spells on you...
|
// remove all harmful spells on you...
|
||||||
if(// only affect magic spells
|
SpellEntry const* spell = iter->second->GetSpellProto();
|
||||||
iter->second->GetSpellProto()->DmgClass == SPELL_DAMAGE_CLASS_MAGIC
|
if((spell->DmgClass == SPELL_DAMAGE_CLASS_MAGIC // only affect magic spells
|
||||||
|
|| ((1<<spell->Dispel) & dispelMask))
|
||||||
// ignore positive and passive auras
|
// ignore positive and passive auras
|
||||||
&& !iter->second->IsPositive() && !iter->second->IsPassive())
|
&& !iter->second->IsPositive() && !iter->second->IsPassive())
|
||||||
{
|
{
|
||||||
m_caster->RemoveAurasDueToSpell(iter->second->GetSpellProto()->Id);
|
m_caster->RemoveAurasDueToSpell(spell->Id);
|
||||||
iter = Auras.begin();
|
iter = Auras.begin();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user