Core/Instances: Fixed initializing instance id sequence generator

Port From (https://github.com/TrinityCore/TrinityCore/commit/4eb6b0156d7e46fe92e2550ce21ba553c705e0a0)
This commit is contained in:
hondacrx
2024-02-03 11:17:33 -05:00
parent 226e12890e
commit 0226b9ff49
@@ -45,8 +45,9 @@ namespace Game.Maps
} while (result.NextRow());
}
// ORDER BY required by MapManager::RegisterInstanceId
// 0 1 2 3 4 5 6 7 8
SQLResult lockResult = DB.Characters.Query("SELECT guid, mapId, lockId, instanceId, difficulty, data, completedEncountersMask, expiryTime, extended FROM character_instance_lock");
SQLResult lockResult = DB.Characters.Query("SELECT guid, mapId, lockId, instanceId, difficulty, data, completedEncountersMask, expiryTime, extended FROM character_instance_lock ORDER BY instanceId");
if (!result.IsEmpty())
{
do