[10478] Implement item 49623 visual effects.

Original patch provided by Darkruler.
This commit is contained in:
VladimirMangos 2010-09-13 02:08:56 +04:00
parent f8c258608f
commit 6af66f1ae4
3 changed files with 39 additions and 13 deletions

View file

@ -8289,14 +8289,33 @@ void SpellAuraHolder::HandleSpellSpecificBoosts(bool apply)
{
case SPELLFAMILY_GENERIC:
{
// Illusionary Barrier
if(GetId() == 57350 && !apply && m_target->getPowerType() == POWER_MANA)
switch(GetId())
{
cast_at_remove = true;
spellId1 = 60242; // Darkmoon Card: Illusion
case 57350: // Illusionary Barrier
{
if (!apply && m_target->getPowerType() == POWER_MANA)
{
cast_at_remove = true;
spellId1 = 60242; // Darkmoon Card: Illusion
}
else
return;
break;
}
case 71905: // Soul Fragment
{
if (!apply)
{
spellId1 = 72521; // Shadowmourne Visual Low
spellId2 = 72523; // Shadowmourne Visual High
}
else
return;
break;
}
default:
return;
}
else
return;
break;
}
case SPELLFAMILY_MAGE:

View file

@ -959,16 +959,23 @@ SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura
if (!roll_chance_i(triggerAmount))
return SPELL_AURA_PROC_FAILED;
SpellAuraHolder *aurHolder = GetSpellAuraHolder(71905);
if (aurHolder && uint32(aurHolder->GetStackAmount() + 1) >= aurHolder->GetSpellProto()->StackAmount)
triggered_spell_id = 71905; // Soul Fragment
SpellAuraHolder *aurHolder = GetSpellAuraHolder(triggered_spell_id);
// will added first to stack
if (!aurHolder)
CastSpell(this, 72521, true); // Shadowmourne Visual Low
// half stack
else if (aurHolder->GetStackAmount() + 1 == 6)
CastSpell(this, 72523, true); // Shadowmourne Visual High
// full stack
else if (aurHolder->GetStackAmount() + 1 >= aurHolder->GetSpellProto()->StackAmount)
{
RemoveAurasDueToSpell(71905);
RemoveAurasDueToSpell(triggered_spell_id);
CastSpell(this, 71904, true); // Chaos Bane
return SPELL_AURA_PROC_OK;
}
else
triggered_spell_id = 71905;
break;
}
}

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10477"
#define REVISION_NR "10478"
#endif // __REVISION_NR_H__