mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-28 14:35:57 +00:00
refactor(Core/Creature): port TC handling of Trainers (#23040)
Co-authored-by: Shauren <shauren.trinity@gmail.com> Co-authored-by: Ghaster <defscam@gmail.com>
This commit is contained in:
@@ -602,9 +602,9 @@ uint32 SpellMgr::GetSpellWithRank(uint32 spell_id, uint32 rank, bool strict) con
|
||||
return spell_id;
|
||||
}
|
||||
|
||||
SpellRequiredMapBounds SpellMgr::GetSpellsRequiredForSpellBounds(uint32 spell_id) const
|
||||
Acore::IteratorPair<SpellRequiredMap::const_iterator> SpellMgr::GetSpellsRequiredForSpellBounds(uint32 spell_id) const
|
||||
{
|
||||
return mSpellReq.equal_range(spell_id);
|
||||
return Acore::Containers::MapEqualRange(mSpellReq, spell_id);
|
||||
}
|
||||
|
||||
SpellsRequiringSpellMapBounds SpellMgr::GetSpellsRequiringSpellBounds(uint32 spell_id) const
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
// For static or at-server-startup loaded spell data
|
||||
|
||||
#include "Log.h"
|
||||
#include "IteratorPair.h"
|
||||
#include "SharedDefines.h"
|
||||
#include "Unit.h"
|
||||
|
||||
@@ -661,7 +662,7 @@ public:
|
||||
[[nodiscard]] uint32 GetSpellWithRank(uint32 spell_id, uint32 rank, bool strict = false) const;
|
||||
|
||||
// Spell Required table
|
||||
[[nodiscard]] SpellRequiredMapBounds GetSpellsRequiredForSpellBounds(uint32 spell_id) const;
|
||||
[[nodiscard]] Acore::IteratorPair<SpellRequiredMap::const_iterator>GetSpellsRequiredForSpellBounds(uint32 spell_id) const;
|
||||
[[nodiscard]] SpellsRequiringSpellMapBounds GetSpellsRequiringSpellBounds(uint32 spell_id) const;
|
||||
[[nodiscard]] bool IsSpellRequiringSpell(uint32 spellid, uint32 req_spellid) const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user