From 114ccfee9d964c2c9ca7badbc872fcddc179fb0b Mon Sep 17 00:00:00 2001 From: FatBoy-DOTC Date: Sun, 10 Mar 2024 16:37:21 -0500 Subject: [PATCH] mob aggro --- src/engine/mobileAI/MobAI.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/engine/mobileAI/MobAI.java b/src/engine/mobileAI/MobAI.java index 7a2ee6fb..c4ccb590 100644 --- a/src/engine/mobileAI/MobAI.java +++ b/src/engine/mobileAI/MobAI.java @@ -243,7 +243,12 @@ public class MobAI { target.setCombatTarget(mob); } } - target.setCombatTarget(mob); + if(target.isAlive()) + target.setCombatTarget(mob); + + if(target.isPet() && target.isAlive() == false && target.guardCaptain.isAlive() == true){ + mob.setCombatTarget(target.guardCaptain); + } } catch (Exception e) { Logger.info(mob.getObjectUUID() + " " + mob.getName() + " Failed At: AttackMob" + " " + e.getMessage()); }