[9873] Drop outdated code for 18788

Signed-off-by: Laise <fenrisse@gmail.com>
This commit is contained in:
zergtmn 2010-05-11 16:18:18 +03:00 committed by Laise
parent 8bc9aa6a92
commit aa8a36afd4
3 changed files with 1 additions and 53 deletions

View file

@ -96,7 +96,6 @@ INSERT INTO spell_check (spellid,SpellFamilyName,SpellFamilyMaskA,SpellFamilyMas
(17269,-1, -1, -1, -1, -1, -1, -1, -1,-1,'Create Resonating Skull', 'Spell::EffectDummy'), (17269,-1, -1, -1, -1, -1, -1, -1, -1,-1,'Create Resonating Skull', 'Spell::EffectDummy'),
(17270,-1, -1, -1, -1, -1, -1, -1, -1,-1,'Create Bone Dust', 'Spell::EffectDummy'), (17270,-1, -1, -1, -1, -1, -1, -1, -1,-1,'Create Bone Dust', 'Spell::EffectDummy'),
(17271, 0, -1, -1, -1, -1, -1, 3, -1,-1,'Test Fetid Skull', 'Spell::EffectDummy'), (17271, 0, -1, -1, -1, -1, -1, 3, -1,-1,'Test Fetid Skull', 'Spell::EffectDummy'),
(18788,-1, -1, -1, -1, -1, -1, 1, -1,-1,'Demonic Sacrifice', 'Spell::EffectInstaKill'),
(18789,-1, -1, -1, -1, -1, -1, -1, -1,-1,'', 'Spell::EffectInstaKill'), (18789,-1, -1, -1, -1, -1, -1, -1, -1,-1,'', 'Spell::EffectInstaKill'),
(18790,-1, -1, -1, -1, -1, -1, -1, -1,-1,'', 'Spell::EffectInstaKill'), (18790,-1, -1, -1, -1, -1, -1, -1, -1,-1,'', 'Spell::EffectInstaKill'),
(18791,-1, -1, -1, -1, -1, -1, -1, -1,-1,'', 'Spell::EffectInstaKill'), (18791,-1, -1, -1, -1, -1, -1, -1, -1,-1,'', 'Spell::EffectInstaKill'),

View file

@ -269,26 +269,6 @@ void Spell::EffectInstaKill(SpellEffectIndex /*eff_idx*/)
if( !unitTarget || !unitTarget->isAlive() ) if( !unitTarget || !unitTarget->isAlive() )
return; return;
// Demonic Sacrifice
if(m_spellInfo->Id==18788 && unitTarget->GetTypeId()==TYPEID_UNIT)
{
uint32 entry = unitTarget->GetEntry();
uint32 spellID;
switch(entry)
{
case 416: spellID=18789; break; //imp
case 417: spellID=18792; break; //fellhunter
case 1860: spellID=18790; break; //void
case 1863: spellID=18791; break; //succubus
case 17252: spellID=35701; break; //fellguard
default:
sLog.outError("EffectInstaKill: Unhandled creature entry (%u) case.", entry);
return;
}
m_caster->CastSpell(m_caster, spellID, true);
}
if(m_caster == unitTarget) // prevent interrupt message if(m_caster == unitTarget) // prevent interrupt message
finish(); finish();
@ -4752,25 +4732,7 @@ void Spell::EffectSummonPet(SpellEffectIndex eff_idx)
// petentry==0 for hunter "call pet" (current pet summoned if any) // petentry==0 for hunter "call pet" (current pet summoned if any)
if(m_caster->GetTypeId() == TYPEID_PLAYER && NewSummon->LoadPetFromDB((Player*)m_caster, petentry)) if(m_caster->GetTypeId() == TYPEID_PLAYER && NewSummon->LoadPetFromDB((Player*)m_caster, petentry))
{
if(NewSummon->getPetType() == SUMMON_PET)
{
// Remove Demonic Sacrifice auras (known pet)
Unit::AuraList const& auraClassScripts = m_caster->GetAurasByType(SPELL_AURA_OVERRIDE_CLASS_SCRIPTS);
for(Unit::AuraList::const_iterator itr = auraClassScripts.begin(); itr != auraClassScripts.end();)
{
if((*itr)->GetModifier()->m_miscvalue == 2228)
{
m_caster->RemoveAurasDueToSpell((*itr)->GetId());
itr = auraClassScripts.begin();
}
else
++itr;
}
}
return; return;
}
// not error in case fail hunter call pet // not error in case fail hunter call pet
if(!petentry) if(!petentry)
@ -4855,19 +4817,6 @@ void Spell::EffectSummonPet(SpellEffectIndex eff_idx)
if(NewSummon->getPetType() == SUMMON_PET) if(NewSummon->getPetType() == SUMMON_PET)
{ {
// Remove Demonic Sacrifice auras (new pet)
Unit::AuraList const& auraClassScripts = m_caster->GetAurasByType(SPELL_AURA_OVERRIDE_CLASS_SCRIPTS);
for(Unit::AuraList::const_iterator itr = auraClassScripts.begin(); itr != auraClassScripts.end();)
{
if((*itr)->GetModifier()->m_miscvalue == 2228)
{
m_caster->RemoveAurasDueToSpell((*itr)->GetId());
itr = auraClassScripts.begin();
}
else
++itr;
}
// generate new name for summon pet // generate new name for summon pet
std::string new_name = sObjectMgr.GeneratePetName(petentry); std::string new_name = sObjectMgr.GeneratePetName(petentry);
if(!new_name.empty()) if(!new_name.empty())

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__ #ifndef __REVISION_NR_H__
#define __REVISION_NR_H__ #define __REVISION_NR_H__
#define REVISION_NR "9872" #define REVISION_NR "9873"
#endif // __REVISION_NR_H__ #endif // __REVISION_NR_H__