*Update to Mangos 7183.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-01-25 16:35:14 -06:00
parent 30f6b38941
commit ef88b04451
37 changed files with 914 additions and 646 deletions

View File

@@ -1377,6 +1377,12 @@ void Spell::EffectDummy(uint32 i)
m_caster->CastCustomSpell(m_caster, 12976, &healthModSpellBasePoints0, NULL, NULL, true, NULL);
return;
}
// Bloodthirst
case 23881:
{
m_caster->CastCustomSpell(unitTarget, 23885, &damage, NULL, NULL, true, NULL);
return;
}
}
break;
case SPELLFAMILY_WARLOCK:
@@ -1487,16 +1493,6 @@ void Spell::EffectDummy(uint32 i)
}
break;
case SPELLFAMILY_DRUID:
switch(m_spellInfo->Id )
{
case 5420: // Tree of Life passive
{
// Tree of Life area effect
int32 health_mod = int32(m_caster->GetStat(STAT_SPIRIT)/4);
m_caster->CastCustomSpell(m_caster,34123,&health_mod,NULL,NULL,true,NULL);
return;
}
}
break;
case SPELLFAMILY_ROGUE:
switch(m_spellInfo->Id )
@@ -2228,7 +2224,7 @@ void Spell::EffectApplyAura(uint32 i)
(unitTarget->GetTypeId()!=TYPEID_PLAYER || !((Player*)unitTarget)->GetSession()->PlayerLoading()) )
return;
Unit* caster = m_originalCasterGUID ? m_originalCaster : m_caster;
Unit* caster = m_originalCaster ? m_originalCaster : m_caster;
if(!caster)
return;
@@ -3380,7 +3376,7 @@ void Spell::EffectLearnSpell(uint32 i)
Player *player = (Player*)unitTarget;
uint32 spellToLearn = ((m_spellInfo->Id==SPELL_ID_GENERIC_LEARN) || (m_spellInfo->Id==SPELL_ID_GENERIC_LEARN_PET)) ? damage : m_spellInfo->EffectTriggerSpell[i];
player->learnSpell(spellToLearn);
player->learnSpell(spellToLearn,false);
sLog.outDebug( "Spell: Player %u have learned spell %u from NpcGUID=%u", player->GetGUIDLow(), spellToLearn, m_caster->GetGUIDLow() );
}
@@ -5045,7 +5041,7 @@ void Spell::EffectScriptEffect(uint32 effIndex)
// learn random explicit discovery recipe (if any)
if(uint32 discoveredSpell = GetExplicitDiscoverySpell(m_spellInfo->Id, player))
player->learnSpell(discoveredSpell);
player->learnSpell(discoveredSpell,false);
return;
}
}
@@ -5120,6 +5116,34 @@ void Spell::EffectScriptEffect(uint32 effIndex)
}
break;
}
case SPELLFAMILY_PRIEST:
{
switch(m_spellInfo->Id)
{
// Pain and Suffering
case 47948:
{
if (!unitTarget)
return;
// Refresh Shadow Word: Pain on target
Unit::AuraList const &mPeriodic = unitTarget->GetAurasByType(SPELL_AURA_PERIODIC_DAMAGE);
for(Unit::AuraList::const_iterator i = mPeriodic.begin(); i != mPeriodic.end(); ++i)
{
if( (*i)->GetSpellProto()->SpellFamilyName == SPELLFAMILY_PRIEST &&
(*i)->GetSpellProto()->SpellFamilyFlags & 0x0000000000008000LL &&
(*i)->GetCasterGUID()==m_caster->GetGUID() )
{
(*i)->RefreshAura();
return;
}
}
return;
}
default:
break;
}
break;
}
case SPELLFAMILY_HUNTER:
{
switch(m_spellInfo->Id)