diff --git a/src/engine/objects/NPC.java b/src/engine/objects/NPC.java index 7fb509e9..da0ea3ae 100644 --- a/src/engine/objects/NPC.java +++ b/src/engine/objects/NPC.java @@ -461,6 +461,8 @@ public class NPC extends AbstractCharacter { NPC newNPC = new NPC(); + newNPC.parentZoneUUID = parent.getObjectUUID(); + newNPC.name = name; newNPC.contractUUID = contractID; @@ -469,8 +471,10 @@ public class NPC extends AbstractCharacter { else newNPC.bindLoc = Vector3fImmutable.ZERO; - newNPC.parentZoneUUID = parent.getObjectUUID(); - newNPC.guildUUID = guild.getObjectUUID(); + if (guild == null) + newNPC.guildUUID = 0; + else + newNPC.guildUUID = guild.getObjectUUID(); if (building == null) newNPC.buildingUUID = 0;