From 6b3c64faea4a47c1c6208b9084fe89dfba03657b Mon Sep 17 00:00:00 2001 From: MagicBot Date: Tue, 17 Oct 2023 15:09:42 -0400 Subject: [PATCH] Minions loaded for guard captain --- src/engine/objects/Mob.java | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/engine/objects/Mob.java b/src/engine/objects/Mob.java index 222485d5..8f7f2b2d 100644 --- a/src/engine/objects/Mob.java +++ b/src/engine/objects/Mob.java @@ -1677,10 +1677,13 @@ public class Mob extends AbstractIntelligenceAgent { if (this.getMobBase().enemy.size() > 0) this.enemy.addAll(this.getMobBase().enemy); } + + // Load skills, powers and effects + NPCManager.applyMobbaseEffects(this); NPCManager.applyEquipmentResists(this); NPCManager.applyMobbaseSkill(this); - NPCManager.applyRuneSkills(this,this.getMobBaseID()); + NPCManager.applyRuneSkills(this, this.getMobBaseID()); this.recalculateStats(); this.setHealth(this.healthMax); @@ -1695,6 +1698,11 @@ public class Mob extends AbstractIntelligenceAgent { if (this.agentType.equals(AIAgentType.MOBILE)) NPCManager.AssignPatrolPoints(this); + // Load minions for guard captain. + + if (this.agentType.equals(AIAgentType.GUARDCAPTAIN)) + DbManager.MobQueries.LOAD_GUARD_MINIONS(this); + this.deathTime = 0; } @@ -1732,9 +1740,9 @@ public class Mob extends AbstractIntelligenceAgent { if (!ac.getObjectType().equals(GameObjectType.PlayerCharacter)) return; - if (this.getCombatTarget() == null) { + if (this.getCombatTarget() == null) this.setCombatTarget(ac); - } + } public void setRank(int newRank) {