diff --git a/src/engine/mobileAI/MobAI.java b/src/engine/mobileAI/MobAI.java index 1fa9a1cf..66823709 100644 --- a/src/engine/mobileAI/MobAI.java +++ b/src/engine/mobileAI/MobAI.java @@ -322,14 +322,12 @@ public class MobAI { if(mob.isPlayerGuard == true){ int contractID; - if(mob.BehaviourType.ordinal() == Enum.MobBehaviourType.GuardMinion.ordinal()){ + if(mob.BehaviourType.equals(Enum.MobBehaviourType.GuardMinion)) contractID = mob.npcOwner.contract.getContractID(); - } else{ + else contractID = mob.contract.getContractID(); - } - if(Enum.MinionType.ContractToMinionMap.get(contractID).isMage() == false){ + if(Enum.MinionType.ContractToMinionMap.get(contractID).isMage() == false) return false; - } } if (mob.mobPowers.isEmpty())