public class WeightedGoal extends Goal
Goal.Control| Modifier and Type | Field and Description |
|---|---|
private Goal |
goal |
private boolean |
running |
private int |
weight |
| Constructor and Description |
|---|
WeightedGoal(int weight,
Goal goal) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canBeReplacedBy(WeightedGoal goal) |
boolean |
canStart() |
boolean |
canStop() |
boolean |
equals(Object object) |
EnumSet<Goal.Control> |
getControls() |
Goal |
getGoal() |
int |
getWeight() |
int |
hashCode() |
boolean |
isRunning() |
void |
setControls(EnumSet<Goal.Control> controls) |
boolean |
shouldContinue() |
void |
start() |
void |
stop() |
void |
tick() |
private final Goal goal
private final int weight
private boolean running
public WeightedGoal(int weight,
Goal goal)
public boolean canBeReplacedBy(WeightedGoal goal)
public boolean shouldContinue()
shouldContinue in class Goalpublic void setControls(EnumSet<Goal.Control> controls)
setControls in class Goalpublic EnumSet<Goal.Control> getControls()
getControls in class Goalpublic boolean isRunning()
public int getWeight()
public Goal getGoal()