mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 10:26:28 +01:00
Core/Maps: Prevent creating maps without a valid Map.dbc entry
Closes #9181
This commit is contained in:
@@ -105,16 +105,17 @@ Map* MapManager::CreateBaseMap(uint32 id)
|
||||
{
|
||||
TRINITY_GUARD(ACE_Thread_Mutex, Lock);
|
||||
|
||||
const MapEntry* entry = sMapStore.LookupEntry(id);
|
||||
if (entry && entry->Instanceable())
|
||||
{
|
||||
MapEntry const* entry = sMapStore.LookupEntry(id);
|
||||
ASSERT(entry);
|
||||
|
||||
if (entry->Instanceable())
|
||||
map = new MapInstanced(id, i_gridCleanUpDelay);
|
||||
}
|
||||
else
|
||||
{
|
||||
map = new Map(id, i_gridCleanUpDelay, 0, REGULAR_DIFFICULTY);
|
||||
map->LoadRespawnTimes();
|
||||
}
|
||||
|
||||
i_maps[id] = map;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user