From 3aec6ee57840a31202a372236daf70c38434f3ba Mon Sep 17 00:00:00 2001 From: MagicBot Date: Fri, 25 Aug 2023 14:45:47 -0400 Subject: [PATCH] More minion setup work. --- src/engine/objects/Mob.java | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/engine/objects/Mob.java b/src/engine/objects/Mob.java index 5d558974..8b641a68 100644 --- a/src/engine/objects/Mob.java +++ b/src/engine/objects/Mob.java @@ -664,12 +664,7 @@ public class Mob extends AbstractIntelligenceAgent { minionMobile.parentZoneUUID = guardCaptain.parentZoneUUID; minionMobile.bindLoc = guardCaptain.bindLoc; - minionMobile.runAfterLoad(); - minionMobile.despawned = true; - minionMobile.setLoc(minionMobile.bindLoc); - minionMobile.despawn(); - - //grab equipment and name from minionbase. + //grab name from minionbase. Enum.MinionType minionType = Enum.MinionType.ContractToMinionMap.get(guardCaptain.contract.getContractID()); @@ -686,8 +681,16 @@ public class Mob extends AbstractIntelligenceAgent { rank = MBServerStatics.ELITE; minionMobile.lastName = rank + " " + minionType.getRace() + " " + minionType.getName(); + } + // Configure and spawn minion + + minionMobile.runAfterLoad(); + minionMobile.despawned = true; + minionMobile.setLoc(minionMobile.bindLoc); + minionMobile.despawn(); + DbManager.addToCache(minionMobile); int slot = guardCaptain.siegeMinionMap.size() + 1;