Core: Use new SpellInfo class in core. Sadly, this commit is not compatibile with some of the custom code. To make your code work again you may need to change:

*SpellEntry is now SpellInfo
*GetSpellProto is now GetSpellInfo
*SpellEntry::Effect*[effIndex] is now avalible under SpellInfo.Effects[effIndex].*
*sSpellStore.LookupEntry is no longer valid, use sSpellMgr->GetSpellInfo()
*SpellFunctions from SpellMgr.h like DoSpellStuff(spellId) are now: spellInfo->DoStuff()
*SpellMgr::CalculateEffectValue and similar functions are now avalible in SpellEffectInfo class.
*GET_SPELL macro is removed, code which used it is moved to SpellMgr::LoadDbcDataCorrections
*code which affected dbc data in SpellMgr::LoadSpellCustomAttr is now moved to LoadDbcDataCorrections
This commit is contained in:
QAston
2011-07-26 23:09:28 +02:00
parent 29c228a801
commit b0fe236265
195 changed files with 4630 additions and 6929 deletions
@@ -515,7 +515,7 @@ public:
if (tempTarget && tempTarget->GetTypeId() == TYPEID_PLAYER && tempTarget->GetGUID() != me->getVictim()->GetGUID() && TargetList.size()<5)
TargetList.push_back(tempTarget);
}
//SpellEntry *spell = GET_SPELL(SPELL_INSIDIOUS_WHISPER);
//SpellInfo *spell = GET_SPELL(SPELL_INSIDIOUS_WHISPER);
for (std::vector<Unit* >::const_iterator itr = TargetList.begin(); itr != TargetList.end(); ++itr)
{
if ((*itr) && (*itr)->isAlive())
@@ -81,13 +81,6 @@ public:
boss_the_lurker_belowAI(Creature* c) : Scripted_NoMovementAI(c), Summons(me)
{
pInstance = c->GetInstanceScript();
SpellEntry *TempSpell = GET_SPELL(SPELL_SPOUT_ANIM);
if (TempSpell)
{
TempSpell->Effect[0] = 0;//remove all spell effect, only anim is needed
TempSpell->Effect[1] = 0;
TempSpell->Effect[2] = 0;
}
}
InstanceScript* pInstance;
@@ -410,9 +403,6 @@ public:
{
mob_coilfang_ambusherAI(Creature* c) : Scripted_NoMovementAI(c)
{
SpellEntry *TempSpell = GET_SPELL(SPELL_SHOOT);
if (TempSpell)
TempSpell->Effect[0] = 2;//change spell effect from weapon % dmg to simple phisical dmg
}
uint32 MultiShotTimer;
@@ -148,7 +148,7 @@ public:
DoScriptText(RAND(SAY_SLAY1, SAY_SLAY2), me);
}
void SpellHit(Unit* /*caster*/, const SpellEntry *spell)
void SpellHit(Unit* /*caster*/, const SpellInfo *spell)
{
//hack :(
if (spell->Id == SPELL_WARLORDS_RAGE_PROC)