public class PlayWithVillagerBabiesTask extends Task<PathAwareEntity>
Task.Status
requiredMemoryStates
Constructor and Description |
---|
PlayWithVillagerBabiesTask() |
finishRunning, getStatus, isTimeLimitExceeded, keepRunning, shouldKeepRunning, stop, tick, toString, tryStarting
protected boolean shouldRun(ServerWorld serverWorld, PathAwareEntity pathAwareEntity)
shouldRun
in class Task<PathAwareEntity>
protected void run(ServerWorld serverWorld, PathAwareEntity pathAwareEntity, long long2)
run
in class Task<PathAwareEntity>
private void setGroundTarget(ServerWorld world, PathAwareEntity entity, LivingEntity unusedBaby)
private static void setPlayTarget(PathAwareEntity entity, LivingEntity target)
private Optional<LivingEntity> getVisibleMob(PathAwareEntity entity)
private Optional<LivingEntity> getLeastPopularBabyInteractionTarget(PathAwareEntity entity)
private Map<LivingEntity,Integer> getBabyInteractionTargetCounts(PathAwareEntity entity)
private List<LivingEntity> getVisibleVillagerBabies(PathAwareEntity entity)
private LivingEntity getInteractionTarget(LivingEntity entity)
@Nullable private LivingEntity findVisibleVillagerBaby(LivingEntity entity)
private boolean hasInteractionTarget(LivingEntity entity)
private boolean isInteractionTargetOf(LivingEntity entity, LivingEntity other)
private boolean hasVisibleVillagerBabies(PathAwareEntity entity)