Package net.minecraft.entity.ai.goal
Class RaidGoal<T extends LivingEntity>
java.lang.Object
net.minecraft.entity.ai.goal.Goal
net.minecraft.entity.ai.goal.TrackTargetGoal
net.minecraft.entity.ai.goal.FollowTargetGoal<T>
net.minecraft.entity.ai.goal.RaidGoal<T>
public class RaidGoal<T extends LivingEntity> extends FollowTargetGoal<T>
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.entity.ai.goal.Goal
Goal.Control
-
Field Summary
Fields Modifier and Type Field Description private int
cooldown
Fields inherited from class net.minecraft.entity.ai.goal.FollowTargetGoal
reciprocalChance, targetClass, targetEntity, targetPredicate
Fields inherited from class net.minecraft.entity.ai.goal.TrackTargetGoal
checkVisibility, maxTimeWithoutVisibility, mob, target
-
Constructor Summary
Constructors Constructor Description RaidGoal(RaiderEntity raider, Class<T> targetEntityClass, boolean checkVisibility, Predicate<LivingEntity> targetPredicate)
-
Method Summary
Modifier and Type Method Description boolean
canStart()
void
decreaseCooldown()
int
getCooldown()
void
start()
Methods inherited from class net.minecraft.entity.ai.goal.FollowTargetGoal
findClosestTarget, getSearchBox, setTargetEntity
Methods inherited from class net.minecraft.entity.ai.goal.TrackTargetGoal
canTrack, getFollowRange, setMaxTimeWithoutVisibility, shouldContinue, stop
Methods inherited from class net.minecraft.entity.ai.goal.Goal
canStop, getControls, setControls, tick, toString
-
Field Details
-
cooldown
private int cooldown
-
-
Constructor Details
-
RaidGoal
public RaidGoal(RaiderEntity raider, Class<T> targetEntityClass, boolean checkVisibility, @Nullable Predicate<LivingEntity> targetPredicate)
-
-
Method Details
-
getCooldown
public int getCooldown() -
decreaseCooldown
public void decreaseCooldown() -
canStart
public boolean canStart()- Overrides:
canStart
in classFollowTargetGoal<T extends LivingEntity>
-
start
public void start()- Overrides:
start
in classFollowTargetGoal<T extends LivingEntity>
-