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:
1 parent
29c228a801
commit
b0fe236265
195 files changed
+4630
-6929
No files matched your search
@@ -40,11 +40,11 @@ class spell_dru_glyph_of_starfire : public SpellScriptLoader
|
||||
{
|
||||
PrepareSpellScript(spell_dru_glyph_of_starfire_SpellScript);
|
||||
|
||||
bool Validate(SpellEntry const* /*spellEntry*/)
|
||||
bool Validate(SpellInfo const* /*spellEntry*/)
|
||||
{
|
||||
if (!sSpellStore.LookupEntry(DRUID_INCREASED_MOONFIRE_DURATION))
|
||||
if (!sSpellMgr->GetSpellInfo(DRUID_INCREASED_MOONFIRE_DURATION))
|
||||
return false;
|
||||
if (!sSpellStore.LookupEntry(DRUID_NATURES_SPLENDOR))
|
||||
if (!sSpellMgr->GetSpellInfo(DRUID_NATURES_SPLENDOR))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
@@ -58,7 +58,7 @@ class spell_dru_glyph_of_starfire : public SpellScriptLoader
|
||||
Aura* aura = aurEff->GetBase();
|
||||
|
||||
uint32 countMin = aura->GetMaxDuration();
|
||||
uint32 countMax = GetSpellMaxDuration(aura->GetSpellProto()) + 9000;
|
||||
uint32 countMax = aura->GetSpellInfo()->GetMaxDuration() + 9000;
|
||||
if (caster->HasAura(DRUID_INCREASED_MOONFIRE_DURATION))
|
||||
countMax += 3000;
|
||||
if (caster->HasAura(DRUID_NATURES_SPLENDOR))
|
||||
@@ -98,7 +98,7 @@ class spell_dru_moonkin_form_passive : public SpellScriptLoader
|
||||
|
||||
bool Load()
|
||||
{
|
||||
absorbPct = SpellMgr::CalculateSpellEffectAmount(GetSpellProto(), EFFECT_0, GetCaster());
|
||||
absorbPct = GetSpellInfo()->Effects[EFFECT_0].CalcValue(GetCaster());
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -142,7 +142,7 @@ class spell_dru_primal_tenacity : public SpellScriptLoader
|
||||
|
||||
bool Load()
|
||||
{
|
||||
absorbPct = SpellMgr::CalculateSpellEffectAmount(GetSpellProto(), EFFECT_1, GetCaster());
|
||||
absorbPct = GetSpellInfo()->Effects[EFFECT_1].CalcValue(GetCaster());
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -186,7 +186,7 @@ class spell_dru_savage_defense : public SpellScriptLoader
|
||||
|
||||
bool Load()
|
||||
{
|
||||
absorbPct = SpellMgr::CalculateSpellEffectAmount(GetSpellProto(), EFFECT_0, GetCaster());
|
||||
absorbPct = GetSpellInfo()->Effects[EFFECT_0].CalcValue(GetCaster());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user