Browse Source

Out of combat mode when patrolling.

master
MagicBot 1 year ago
parent
commit
d3692d0fb7
  1. 8
      src/engine/mobileAI/MobAI.java

8
src/engine/mobileAI/MobAI.java

@ -20,6 +20,7 @@ import engine.mobileAI.utilities.MovementUtilities; @@ -20,6 +20,7 @@ import engine.mobileAI.utilities.MovementUtilities;
import engine.net.DispatchMessage;
import engine.net.client.msg.PerformActionMsg;
import engine.net.client.msg.PowerProjectileMsg;
import engine.net.client.msg.UpdateStateMsg;
import engine.objects.*;
import engine.powers.ActionsBase;
import engine.powers.PowersBase;
@ -1305,6 +1306,13 @@ public class MobAI { @@ -1305,6 +1306,13 @@ public class MobAI {
//make sure mob is out of combat stance
if (minion.getKey().isCombat() && minion.getKey().getCombatTarget() == null) {
minion.getKey().setCombat(false);
UpdateStateMsg rwss = new UpdateStateMsg();
rwss.setPlayer(minion.getKey());
DispatchMessage.sendToAllInRange(minion.getKey(), rwss);
}
if (minion.getKey().despawned == false) {
if (MovementUtilities.canMove(minion.getKey())) {
Vector3f minionOffset = Formation.getOffset(2, minion.getValue() + 3);

Loading…
Cancel
Save