Package net.minecraft.entity.ai.goal
Class FollowTargetIfTamedGoal<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.FollowTargetIfTamedGoal<T>
public class FollowTargetIfTamedGoal<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 TameableEntitytameableFields inherited from class net.minecraft.entity.ai.goal.FollowTargetGoal
reciprocalChance, targetClass, targetEntity, targetPredicateFields inherited from class net.minecraft.entity.ai.goal.TrackTargetGoal
checkVisibility, maxTimeWithoutVisibility, mob, target -
Constructor Summary
Constructors Constructor Description FollowTargetIfTamedGoal(TameableEntity tameable, Class<T> targetClass, boolean checkVisibility, Predicate<LivingEntity> targetPredicate) -
Method Summary
Modifier and Type Method Description booleancanStart()booleanshouldContinue()Methods inherited from class net.minecraft.entity.ai.goal.FollowTargetGoal
findClosestTarget, getSearchBox, setTargetEntity, startMethods inherited from class net.minecraft.entity.ai.goal.TrackTargetGoal
canTrack, getFollowRange, setMaxTimeWithoutVisibility, stopMethods inherited from class net.minecraft.entity.ai.goal.Goal
canStop, getControls, setControls, tick, toString
-
Field Details
-
tameable
-
-
Constructor Details
-
FollowTargetIfTamedGoal
public FollowTargetIfTamedGoal(TameableEntity tameable, Class<T> targetClass, boolean checkVisibility, @Nullable Predicate<LivingEntity> targetPredicate)
-
-
Method Details
-
canStart
public boolean canStart()- Overrides:
canStartin classFollowTargetGoal<T extends LivingEntity>
-
shouldContinue
public boolean shouldContinue()- Overrides:
shouldContinuein classTrackTargetGoal
-