Core/VMaps: Implement loading phased tiles

This commit is contained in:
Ovahlord authored and Aokromes committed 2018-03-09 18:05:47 +01:00
1 parent 2281947ee9
commit 4bbdce57e2
21 files changed
+433 -142

No files matched your search

+7 -1
View File
@@ -1503,11 +1503,17 @@ void World::SetInitialWorldSettings()
LoadM2Cameras(m_dataPath);
std::vector<uint32> mapIds;
std::unordered_map<uint32, std::vector<uint32>> mapData;
for (MapEntry const* mapEntry : sMapStore)
{
mapIds.push_back(mapEntry->MapID);
mapData.emplace(std::piecewise_construct, std::forward_as_tuple(mapEntry->MapID), std::forward_as_tuple());
if (mapEntry->rootPhaseMap != -1)
mapData[mapEntry->rootPhaseMap].push_back(mapEntry->MapID);
}
if (VMAP::VMapManager2* vmmgr2 = dynamic_cast<VMAP::VMapManager2*>(VMAP::VMapFactory::createOrGetVMapManager()))
vmmgr2->InitializeThreadUnsafe(mapIds);
vmmgr2->InitializeThreadUnsafe(mapData);
MMAP::MMapManager* mmmgr = MMAP::MMapFactory::createOrGetMMapManager();
mmmgr->InitializeThreadUnsafe(mapIds);