From 8068082768e23765497930d8a12e613eaeaee5d4 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Mon, 8 May 2023 09:29:11 -0400 Subject: [PATCH] Naming logic changed to have a valid guild. --- src/engine/objects/NPC.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/engine/objects/NPC.java b/src/engine/objects/NPC.java index 63f59b92..720b8db4 100644 --- a/src/engine/objects/NPC.java +++ b/src/engine/objects/NPC.java @@ -242,11 +242,11 @@ public class NPC extends AbstractCharacter { this.name = rs.getString("npc_name"); - // Name override for player owned npcs + // Name override for npc + // with an owner. - if (this.building != null && - this.building.getOwner() != null && - this.building.getOwner().guild != null) + if (this.guild != null && + !this.guild.isEmptyGuild()) this.name += " the " + this.contract.getName(); }catch(Exception e){