Child scripts now loaded by a uniqueId in the spawn table.

This commit is contained in:
Filip Maj 2016-06-09 22:58:03 -04:00
parent 23b6ede128
commit f0d4429f65
4 changed files with 34 additions and 18 deletions

View file

@ -243,7 +243,8 @@ namespace FFXIVClassic_Map_Server
string query = @"
SELECT
actorClassId,
actorClassId,
uniqueId,
zoneId,
privateAreaName,
privateAreaLevel,
@ -264,10 +265,11 @@ namespace FFXIVClassic_Map_Server
while (reader.Read())
{
string customName = null;
if (!reader.IsDBNull(10))
if (!reader.IsDBNull(11))
customName = reader.GetString("customDisplayName");
uint classId = reader.GetUInt32("actorClassId");
string uniqueId = reader.GetString("uniqueId");
uint zoneId = reader.GetUInt32("zoneId");
string privAreaName = reader.GetString("privateAreaName");
uint privAreaLevel = reader.GetUInt32("privateAreaLevel");
@ -287,7 +289,7 @@ namespace FFXIVClassic_Map_Server
if (zone == null)
continue;
SpawnLocation spawn = new SpawnLocation(classId, zoneId, privAreaName, privAreaLevel, x, y, z, rot, state, animId);
SpawnLocation spawn = new SpawnLocation(classId, uniqueId, zoneId, privAreaName, privAreaLevel, x, y, z, rot, state, animId);
zone.addSpawnLocation(spawn);