Core/Maps: Made instance_template no longer required to create and enter instance maps

This commit is contained in:
Shauren authored and Ovahlord committed 2023-01-09 11:42:15 +01:00
1 parent 0baf2d1e1e
commit 68cf700178
7 files changed
+17 -41

No files matched your search

+2 -9
View File
@@ -391,16 +391,9 @@ bool MapManager::DestroyMap(Map* map)
return true;
}
bool MapManager::IsValidMAP(uint32 mapid, bool startUp)
bool MapManager::IsValidMAP(uint32 mapId)
{
MapEntry const* mEntry = sMapStore.LookupEntry(mapid);
if (startUp)
return mEntry ? true : false;
else
return mEntry && (!mEntry->IsDungeon() || sObjectMgr->GetInstanceTemplate(mapid));
/// @todo add check for battleground template
return sMapStore.LookupEntry(mapId) != nullptr;
}
void MapManager::UnloadAll()