refactor(Core/DB): normalize creature table by extracting multi-ID spawns (#25197)

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: Ludwig <sudlud@users.noreply.github.com>
This commit is contained in:
Andrew
2026-06-16 01:17:38 -03:00
committed by GitHub
parent eb3cdd1d1f
commit cf0d86a9ff
22 changed files with 281 additions and 200 deletions

View File

@@ -2492,7 +2492,7 @@ public:
if (isAlive)
{
handler->PSendSysMessage(LANG_RESPAWN_GUID_CREATURE_ALIVE, spawnId, creData->id1);
handler->PSendSysMessage(LANG_RESPAWN_GUID_CREATURE_ALIVE, spawnId, creData->id);
return true;
}
@@ -2508,7 +2508,7 @@ public:
time_t now = GameTime::GetGameTime().count();
map->SaveCreatureRespawnTime(spawnId, now);
}
handler->PSendSysMessage(LANG_RESPAWN_GUID_CREATURE_QUEUED, spawnId, creData->id1);
handler->PSendSysMessage(LANG_RESPAWN_GUID_CREATURE_QUEUED, spawnId, creData->id);
return true;
}
@@ -2608,7 +2608,7 @@ public:
for (auto const& [spawnId, creature] : map->GetCreatureBySpawnIdStore())
{
CreatureData const* data = sObjectMgr->GetCreatureData(spawnId);
if (!data || data->id1 != entry)
if (!data || data->id != entry)
continue;
if (creature->isDead())
deadCreatures.push_back(creature);
@@ -2624,7 +2624,7 @@ public:
for (auto const& [spawnId, respawnTime] : map->GetCreatureRespawnTimes())
{
CreatureData const* data = sObjectMgr->GetCreatureData(spawnId);
if (!data || data->id1 != entry)
if (!data || data->id != entry)
continue;
if (sPoolMgr->IsPartOfAPool<Creature>(spawnId))
continue;