From 75951926e63a80214c8b5c5595a842b90875f313 Mon Sep 17 00:00:00 2001 From: Nefertumm Date: Thu, 27 Jan 2022 08:35:44 -0300 Subject: [PATCH] feat(Core/Logs): Improve logs for linked_respawn (#10202) --- src/server/game/Globals/ObjectMgr.cpp | 32 +++++++++++++-------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index 796d297a3..04e8e24f7 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -1729,7 +1729,7 @@ void ObjectMgr::LoadLinkedRespawn() const CreatureData* slave = GetCreatureData(guidLow); if (!slave) { - LOG_ERROR("sql.sql", "Couldn't get creature data for GUIDLow %u", guidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature (guid) %u not found in creature table", guidLow); error = true; break; } @@ -1737,7 +1737,7 @@ void ObjectMgr::LoadLinkedRespawn() const CreatureData* master = GetCreatureData(linkedGuidLow); if (!master) { - LOG_ERROR("sql.sql", "Couldn't get creature data for GUIDLow %u", linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature (linkedGuid) %u not found in creature table", linkedGuidLow); error = true; break; } @@ -1745,14 +1745,14 @@ void ObjectMgr::LoadLinkedRespawn() const MapEntry* const map = sMapStore.LookupEntry(master->mapid); if (!map || !map->Instanceable() || (master->mapid != slave->mapid)) { - LOG_ERROR("sql.sql", "Creature '%u' linking to '%u' on an unpermitted map.", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to Creature '%u' on an unpermitted map.", guidLow, linkedGuidLow); error = true; break; } if (!(master->spawnMask & slave->spawnMask)) // they must have a possibility to meet (normal/heroic difficulty) { - LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to Creature '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); error = true; break; } @@ -1766,7 +1766,7 @@ void ObjectMgr::LoadLinkedRespawn() const CreatureData* slave = GetCreatureData(guidLow); if (!slave) { - LOG_ERROR("sql.sql", "Couldn't get creature data for GUIDLow %u", guidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature (guid) %u not found in creature table", guidLow); error = true; break; } @@ -1774,7 +1774,7 @@ void ObjectMgr::LoadLinkedRespawn() const GameObjectData* master = GetGOData(linkedGuidLow); if (!master) { - LOG_ERROR("sql.sql", "Couldn't get gameobject data for GUIDLow %u", linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject (linkedGuid) %u not found in gameobject table", linkedGuidLow); error = true; break; } @@ -1782,14 +1782,14 @@ void ObjectMgr::LoadLinkedRespawn() const MapEntry* const map = sMapStore.LookupEntry(master->mapid); if (!map || !map->Instanceable() || (master->mapid != slave->mapid)) { - LOG_ERROR("sql.sql", "Creature '%u' linking to '%u' on an unpermitted map.", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to Gameobject '%u' on an unpermitted map.", guidLow, linkedGuidLow); error = true; break; } if (!(master->spawnMask & slave->spawnMask)) // they must have a possibility to meet (normal/heroic difficulty) { - LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to Gameobject '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); error = true; break; } @@ -1803,7 +1803,7 @@ void ObjectMgr::LoadLinkedRespawn() const GameObjectData* slave = GetGOData(guidLow); if (!slave) { - LOG_ERROR("sql.sql", "Couldn't get gameobject data for GUIDLow %u", guidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject (guid) %u not found in gameobject table", guidLow); error = true; break; } @@ -1811,7 +1811,7 @@ void ObjectMgr::LoadLinkedRespawn() const GameObjectData* master = GetGOData(linkedGuidLow); if (!master) { - LOG_ERROR("sql.sql", "Couldn't get gameobject data for GUIDLow %u", linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject (linkedGuid) %u not found in gameobject table", linkedGuidLow); error = true; break; } @@ -1819,14 +1819,14 @@ void ObjectMgr::LoadLinkedRespawn() const MapEntry* const map = sMapStore.LookupEntry(master->mapid); if (!map || !map->Instanceable() || (master->mapid != slave->mapid)) { - LOG_ERROR("sql.sql", "Creature '%u' linking to '%u' on an unpermitted map.", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject '%u' linking to Gameobject '%u' on an unpermitted map.", guidLow, linkedGuidLow); error = true; break; } if (!(master->spawnMask & slave->spawnMask)) // they must have a possibility to meet (normal/heroic difficulty) { - LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject '%u' linking to Gameobject '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); error = true; break; } @@ -1840,7 +1840,7 @@ void ObjectMgr::LoadLinkedRespawn() const GameObjectData* slave = GetGOData(guidLow); if (!slave) { - LOG_ERROR("sql.sql", "Couldn't get gameobject data for GUIDLow %u", guidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject (guid) %u not found in gameobject table", guidLow); error = true; break; } @@ -1848,7 +1848,7 @@ void ObjectMgr::LoadLinkedRespawn() const CreatureData* master = GetCreatureData(linkedGuidLow); if (!master) { - LOG_ERROR("sql.sql", "Couldn't get creature data for GUIDLow %u", linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Creature (linkedGuid) %u not found in creature table", linkedGuidLow); error = true; break; } @@ -1856,14 +1856,14 @@ void ObjectMgr::LoadLinkedRespawn() const MapEntry* const map = sMapStore.LookupEntry(master->mapid); if (!map || !map->Instanceable() || (master->mapid != slave->mapid)) { - LOG_ERROR("sql.sql", "Creature '%u' linking to '%u' on an unpermitted map.", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject '%u' linking to Creature '%u' on an unpermitted map.", guidLow, linkedGuidLow); error = true; break; } if (!(master->spawnMask & slave->spawnMask)) // they must have a possibility to meet (normal/heroic difficulty) { - LOG_ERROR("sql.sql", "LinkedRespawn: Creature '%u' linking to '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); + LOG_ERROR("sql.sql", "LinkedRespawn: Gameobject '%u' linking to Creature '%u' with not corresponding spawnMask", guidLow, linkedGuidLow); error = true; break; }