Core/Conditions: Implemented conditions for spawn groups

This commit is contained in:
Shauren authored and Ovahlord committed 2022-12-26 11:15:13 +01:00
1 parent 740fa9e65a
commit cbd46b7664
7 files changed
+181 -68

No files matched your search

+3
View File
@@ -2670,7 +2670,10 @@ void ObjectMgr::LoadSpawnGroups()
{
SpawnGroupTemplateData& groupTemplate = it->second;
if (groupTemplate.mapId == SPAWNGROUP_MAP_UNSET)
{
groupTemplate.mapId = data->mapId;
_spawnGroupsByMap[data->mapId].push_back(groupId);
}
else if (groupTemplate.mapId != data->mapId && !(groupTemplate.flags & SPAWNGROUP_FLAG_SYSTEM))
{
TC_LOG_ERROR("sql.sql", "Spawn group %u has map ID %u, but spawn (%u,%u) has map id %u - spawn NOT added to group!", groupId, groupTemplate.mapId, uint32(spawnType), spawnId, data->mapId);