aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Spells/SpellMgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/game/Spells/SpellMgr.cpp')
-rw-r--r--src/server/game/Spells/SpellMgr.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp
index 0b9856d6fb8..be6ab369a46 100644
--- a/src/server/game/Spells/SpellMgr.cpp
+++ b/src/server/game/Spells/SpellMgr.cpp
@@ -18,6 +18,7 @@
#include "SpellMgr.h"
#include "BattlefieldMgr.h"
#include "BattlegroundMgr.h"
+#include "BattlePetMgr.h"
#include "Chat.h"
#include "Containers.h"
#include "DB2Stores.h"
@@ -2439,7 +2440,6 @@ void SpellMgr::LoadSpellInfoStore()
std::unordered_map<std::pair<uint32, Difficulty>, SpellInfoLoadHelper> loadData;
std::unordered_map<int32, BattlePetSpeciesEntry const*> battlePetSpeciesByCreature;
- std::unordered_map<uint32, BattlePetSpeciesEntry const*> battlePetSpeciesBySpellId;
for (BattlePetSpeciesEntry const* battlePetSpecies : sBattlePetSpeciesStore)
if (battlePetSpecies->CreatureID)
battlePetSpeciesByCreature[battlePetSpecies->CreatureID] = battlePetSpecies;
@@ -2458,7 +2458,7 @@ void SpellMgr::LoadSpellInfoStore()
if (SummonPropertiesEntry const* summonProperties = sSummonPropertiesStore.LookupEntry(effect->EffectMiscValue[1]))
if (summonProperties->Slot == SUMMON_SLOT_MINIPET && summonProperties->GetFlags().HasFlag(SummonPropertiesFlags::SummonFromBattlePetJournal))
if (BattlePetSpeciesEntry const* battlePetSpecies = Trinity::Containers::MapGetValuePtr(battlePetSpeciesByCreature, effect->EffectMiscValue[0]))
- mBattlePets[effect->SpellID] = battlePetSpecies;
+ BattlePets::BattlePetMgr::AddBattlePetSpeciesBySpell(effect->SpellID, battlePetSpecies);
if (effect->Effect == SPELL_EFFECT_LANGUAGE)
sLanguageMgr->LoadSpellEffectLanguage(effect);
@@ -4845,8 +4845,3 @@ uint32 SpellMgr::GetModelForTotem(uint32 spellId, uint8 race) const
return 0;
}
-
-BattlePetSpeciesEntry const* SpellMgr::GetBattlePetSpecies(uint32 spellId) const
-{
- return Trinity::Containers::MapGetValuePtr(mBattlePets, spellId);
-}