|
|
@ -918,10 +918,10 @@ public class NPC extends AbstractCharacter { |
|
|
|
if (this.parentZone != null) { |
|
|
|
if (this.parentZone != null) { |
|
|
|
if (zone.getObjectUUID() != this.parentZone.getObjectUUID()) { |
|
|
|
if (zone.getObjectUUID() != this.parentZone.getObjectUUID()) { |
|
|
|
this.parentZone.zoneNPCSet.remove(this); |
|
|
|
this.parentZone.zoneNPCSet.remove(this); |
|
|
|
zone.zoneNPCSet.add(this); |
|
|
|
//zone.zoneNPCSet.add(this);
|
|
|
|
} |
|
|
|
} |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
zone.zoneNPCSet.add(this); |
|
|
|
//zone.zoneNPCSet.add(this);
|
|
|
|
} |
|
|
|
} |
|
|
|
} else if (this.parentZone != null) { |
|
|
|
} else if (this.parentZone != null) { |
|
|
|
this.parentZone.zoneNPCSet.remove(this); |
|
|
|
this.parentZone.zoneNPCSet.remove(this); |
|
|
@ -988,6 +988,9 @@ public class NPC extends AbstractCharacter { |
|
|
|
if (npcWithoutID.mobBase == null) { |
|
|
|
if (npcWithoutID.mobBase == null) { |
|
|
|
return null; |
|
|
|
return null; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (parent != null) { |
|
|
|
|
|
|
|
npcWithoutID.setRelPos(parent, spawn.x - parent.absX, spawn.y - parent.absY, spawn.z - parent.absZ); |
|
|
|
|
|
|
|
} |
|
|
|
NPC npc; |
|
|
|
NPC npc; |
|
|
|
try { |
|
|
|
try { |
|
|
|
npc = DbManager.NPCQueries.ADD_NPC(npcWithoutID, isMob); |
|
|
|
npc = DbManager.NPCQueries.ADD_NPC(npcWithoutID, isMob); |
|
|
|