Browse Source

guard minion logic work

master
FatBoy-DOTC 2 years ago
parent
commit
56a6b9d204
  1. 9
      src/engine/ai/MobileFSM.java

9
src/engine/ai/MobileFSM.java

@ -384,12 +384,15 @@ public class MobileFSM {
return; return;
mob.updateLocation(); mob.updateLocation();
if (mob.BehaviourType != Enum.MobBehaviourType.Pet1) { if (mob.BehaviourType != Enum.MobBehaviourType.Pet1) {
if(mob.BehaviourType.ordinal() == Enum.MobBehaviourType.GuardMinion.ordinal() && ((Mob)mob.npcOwner).despawned == true) if (mob.getCombatTarget() == null) {
if (mob.BehaviourType.ordinal() == Enum.MobBehaviourType.GuardMinion.ordinal() && (mob.npcOwner).isAlive()) {
return; return;
if (mob.getCombatTarget() == null) }
Patrol(mob); Patrol(mob);
else }
else {
chaseTarget(mob); chaseTarget(mob);
}
} else { } else {
//pet logic //pet logic
if (!mob.playerAgroMap.containsKey(mob.getOwner().getObjectUUID())) { if (!mob.playerAgroMap.containsKey(mob.getOwner().getObjectUUID())) {

Loading…
Cancel
Save