*Remove unneeded code for hanner of wrath and execute.

--HG--
branch : trunk
This commit is contained in:
QAston
2009-04-13 13:39:17 +02:00
parent 392317aba3
commit 249405abea

View File

@@ -4007,22 +4007,7 @@ SpellCastResult Spell::CheckCast(bool strict)
{
case SPELL_EFFECT_DUMMY:
{
if(m_spellInfo->SpellIconID == 1648) // Execute
{
if(!m_targets.getUnitTarget())
return SPELL_FAILED_BAD_TARGETS;
if (m_targets.getUnitTarget()->GetHealth() > m_targets.getUnitTarget()->GetMaxHealth()*0.2)
{
bool found = false;
Unit::AuraEffectList const& stateAuras = m_caster->GetAurasByType(SPELL_AURA_ABILITY_IGNORE_AURASTATE);
for(Unit::AuraEffectList::const_iterator j = stateAuras.begin();j != stateAuras.end(); ++j)
if((*j)->isAffectedOnSpell(m_spellInfo))
found=true;
if (!found)
return SPELL_FAILED_BAD_TARGETS;
}
}
else if (m_spellInfo->Id == 51582) // Rocket Boots Engaged
if (m_spellInfo->Id == 51582) // Rocket Boots Engaged
{
if(m_caster->IsInWater())
return SPELL_FAILED_ONLY_ABOVEWATER;
@@ -4042,19 +4027,6 @@ SpellCastResult Spell::CheckCast(bool strict)
}
break;
}
case SPELL_EFFECT_SCHOOL_DAMAGE:
{
// Hammer of Wrath
if(m_spellInfo->SpellVisual[0] == 7250)
{
if (!m_targets.getUnitTarget())
return SPELL_FAILED_BAD_IMPLICIT_TARGETS;
if(m_targets.getUnitTarget()->GetHealth() > m_targets.getUnitTarget()->GetMaxHealth()*0.2)
return SPELL_FAILED_BAD_TARGETS;
}
break;
}
case SPELL_EFFECT_LEARN_SPELL:
{
if (m_caster->GetTypeId() != TYPEID_PLAYER)