Gamelib/src/main/java/uulm/teamname/marvelous/gamelibrary/ai/Action.java

59 lines
1.6 KiB
Java

package uulm.teamname.marvelous.gamelibrary.ai;
import uulm.teamname.marvelous.gamelibrary.IntVector2;
import uulm.teamname.marvelous.gamelibrary.entities.EntityID;
import uulm.teamname.marvelous.gamelibrary.entities.StoneType;
class Action {
public final ActionType type;
public final IntVector2 target;
public final EntityID targetEntity;
public final StoneType stone;
public Action(ActionType type) {
this.type = type;
this.target = null;
this.targetEntity = null;
this.stone = null;
}
public Action(ActionType type, IntVector2 target) {
this.type = type;
this.target = target;
this.targetEntity = null;
this.stone = null;
}
public Action(ActionType type, IntVector2 target, EntityID targetEntity) {
this.type = type;
this.target = target;
this.targetEntity = targetEntity;
this.stone = null;
}
public Action(ActionType type, StoneType stone) {
this.type = type;
this.target = null;
this.targetEntity = null;
this.stone = stone;
}
public Action(ActionType type, IntVector2 target, StoneType stone) {
this.type = type;
this.target = target;
this.targetEntity = null;
this.stone = stone;
}
public Action(ActionType type, IntVector2 target, EntityID targetEntity, StoneType stone) {
this.type = type;
this.target = target;
this.targetEntity = targetEntity;
this.stone = stone;
}
public String toString() {
return this.type.toString();
}
}