public class TargetNearestGoal extends TargetGoal
shouldCheckSight, targetDistance, taskOwner| Constructor and Description |
|---|
TargetNearestGoal(net.minecraft.entity.CreatureEntity entity,
float targetRange,
boolean par5) |
TargetNearestGoal(net.minecraft.entity.CreatureEntity entity,
float targetRange,
boolean par5,
boolean par6) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canContinueToUse()
Returns whether an in-progress EntityAIBase should continue executing.
|
boolean |
canUse()
Returns whether the EntityAIBase should begin execution.
|
void |
setTargetDistance(float targetDistance) |
void |
start()
Execute a one shot task or start executing a continuous task
|
void |
stop()
Resets the task.
|
void |
tick() |
isSuitableTargetpublic TargetNearestGoal(net.minecraft.entity.CreatureEntity entity,
float targetRange,
boolean par5)
public TargetNearestGoal(net.minecraft.entity.CreatureEntity entity,
float targetRange,
boolean par5,
boolean par6)
public void setTargetDistance(float targetDistance)
public boolean canUse()
canUse in class net.minecraft.entity.ai.goal.Goalpublic void start()
start in class TargetGoalpublic void tick()
tick in class TargetGoalpublic void stop()
TargetGoalstop in class TargetGoalpublic boolean canContinueToUse()
TargetGoalcanContinueToUse in class TargetGoal