mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[8026] Obtain object's map directly by calling appropriate WorldObject::GetMap()/GetBaseMap() functions instead of accessing MapManager. Code cleanups. Big thanks Infinity for tests.
Signed-off-by: AlexDereka <dereka.alex@gmail.com>
This commit is contained in:
parent
1187c8698c
commit
b76c4c2f3c
29 changed files with 99 additions and 99 deletions
|
|
@ -182,8 +182,8 @@ bool Creature::InitEntry(uint32 Entry, uint32 team, const CreatureData *data )
|
|||
CreatureInfo const *cinfo = normalInfo;
|
||||
if(normalInfo->HeroicEntry)
|
||||
{
|
||||
Map *map = MapManager::Instance().FindMap(GetMapId(), GetInstanceId());
|
||||
if(map && map->IsHeroic())
|
||||
//we already have valid Map pointer for current creature!
|
||||
if(GetMap()->IsHeroic())
|
||||
{
|
||||
cinfo = objmgr.GetCreatureTemplate(normalInfo->HeroicEntry);
|
||||
if(!cinfo)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue