forked from MagicBane/Server
Renamed class to not conflict with the java.lang version.
This commit is contained in:
@@ -10,13 +10,13 @@
|
||||
package engine.objects;
|
||||
|
||||
import ch.claude_martin.enumbitset.EnumBitSet;
|
||||
import engine.Enum;
|
||||
import engine.Enum.GameObjectType;
|
||||
import engine.Enum.ModType;
|
||||
import engine.Enum.SourceType;
|
||||
import engine.InterestManagement.WorldGrid;
|
||||
import engine.gameManager.ZoneManager;
|
||||
import engine.math.Vector3fImmutable;
|
||||
import engine.mbEnums;
|
||||
import engine.mbEnums.GameObjectType;
|
||||
import engine.mbEnums.ModType;
|
||||
import engine.mbEnums.SourceType;
|
||||
import engine.mobileAI.Threads.MobAIThread;
|
||||
import engine.net.Dispatch;
|
||||
import engine.net.DispatchMessage;
|
||||
@@ -31,13 +31,13 @@ import java.util.ArrayList;
|
||||
public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
protected Vector3fImmutable lastBindLoc;
|
||||
public boolean assist = false;
|
||||
public Enum.AIAgentType agentType = Enum.AIAgentType.MOBILE;
|
||||
public mbEnums.AIAgentType agentType = mbEnums.AIAgentType.MOBILE;
|
||||
|
||||
public AbstractCharacter guardCaptain;
|
||||
public EnumBitSet<Enum.MonsterType> notEnemy = EnumBitSet.noneOf(Enum.MonsterType.class);
|
||||
public EnumBitSet<Enum.MonsterType> enemy = EnumBitSet.noneOf(Enum.MonsterType.class);
|
||||
public EnumBitSet<mbEnums.MonsterType> notEnemy = EnumBitSet.noneOf(mbEnums.MonsterType.class);
|
||||
public EnumBitSet<mbEnums.MonsterType> enemy = EnumBitSet.noneOf(mbEnums.MonsterType.class);
|
||||
;
|
||||
public Enum.MobBehaviourType behaviourType;
|
||||
public mbEnums.MobBehaviourType behaviourType;
|
||||
public ArrayList<Vector3fImmutable> patrolPoints;
|
||||
public int lastPatrolPointIndex = 0;
|
||||
public long stopPatrolTime = 0;
|
||||
@@ -96,9 +96,9 @@ public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
public void setPet(PlayerCharacter owner, boolean summoned) {
|
||||
|
||||
if (summoned)
|
||||
this.agentType = Enum.AIAgentType.PET; //summoned
|
||||
this.agentType = mbEnums.AIAgentType.PET; //summoned
|
||||
else
|
||||
this.agentType = Enum.AIAgentType.CHARMED;
|
||||
this.agentType = mbEnums.AIAgentType.CHARMED;
|
||||
|
||||
if (this.getObjectType().equals(GameObjectType.Mob)) {
|
||||
|
||||
@@ -109,8 +109,8 @@ public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
|
||||
public boolean isPet() {
|
||||
|
||||
return (this.agentType.equals(Enum.AIAgentType.PET) ||
|
||||
this.agentType.equals(Enum.AIAgentType.CHARMED));
|
||||
return (this.agentType.equals(mbEnums.AIAgentType.PET) ||
|
||||
this.agentType.equals(mbEnums.AIAgentType.CHARMED));
|
||||
}
|
||||
|
||||
public void toggleAssist() {
|
||||
@@ -150,7 +150,7 @@ public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
|
||||
if (this.isPet()) {
|
||||
|
||||
if ((this.agentType.equals(Enum.AIAgentType.PET))) { //delete summoned pet
|
||||
if ((this.agentType.equals(mbEnums.AIAgentType.PET))) { //delete summoned pet
|
||||
|
||||
WorldGrid.RemoveWorldObject(this);
|
||||
|
||||
@@ -159,7 +159,7 @@ public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
((Mob) this).getParentZone().zoneMobSet.remove(this);
|
||||
|
||||
} else { //revert charmed pet
|
||||
this.agentType = Enum.AIAgentType.MOBILE;
|
||||
this.agentType = mbEnums.AIAgentType.MOBILE;
|
||||
this.setCombatTarget(null);
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
|
||||
PetMsg petMsg = new PetMsg(5, null);
|
||||
Dispatch dispatch = Dispatch.borrow(owner, petMsg);
|
||||
DispatchMessage.dispatchMsgDispatch(dispatch, Enum.DispatchChannel.SECONDARY);
|
||||
DispatchMessage.dispatchMsgDispatch(dispatch, mbEnums.DispatchChannel.SECONDARY);
|
||||
|
||||
if (pet != null && pet.getObjectUUID() == this.getObjectUUID())
|
||||
owner.setPet(null);
|
||||
|
||||
Reference in New Issue
Block a user