Class WalkToNearestVisibleWantedItemTask<E extends LivingEntity>

java.lang.Object
net.minecraft.entity.ai.brain.task.Task<E>
net.minecraft.entity.ai.brain.task.WalkToNearestVisibleWantedItemTask<E>

public class WalkToNearestVisibleWantedItemTask<E extends LivingEntity> extends Task<E>
Mappings:
Namespace Name
official bej
intermediary net/minecraft/class_4815
named net/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask
  • Field Details

    • startCondition

      private final Predicate<E extends LivingEntity> startCondition
      Mappings:
      Namespace Name Mixin selector
      official a Lbej;a:Ljava/util/function/Predicate;
      intermediary field_22305 Lnet/minecraft/class_4815;field_22305:Ljava/util/function/Predicate;
      named startCondition Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;startCondition:Ljava/util/function/Predicate;
    • radius

      private final int radius
      Mappings:
      Namespace Name Mixin selector
      official d Lbej;d:I
      intermediary field_22306 Lnet/minecraft/class_4815;field_22306:I
      named radius Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;radius:I
    • speed

      private final float speed
      Mappings:
      Namespace Name Mixin selector
      official e Lbej;e:F
      intermediary field_23131 Lnet/minecraft/class_4815;field_23131:F
      named speed Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;speed:F
  • Constructor Details

    • WalkToNearestVisibleWantedItemTask

      public WalkToNearestVisibleWantedItemTask(float speed, boolean requiresWalkTarget, int radius)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lbej;<init>(FZI)V
      intermediary <init> Lnet/minecraft/class_4815;<init>(FZI)V
      named <init> Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;<init>(FZI)V
    • WalkToNearestVisibleWantedItemTask

      public WalkToNearestVisibleWantedItemTask(Predicate<E> startCondition, float speed, boolean requiresWalkTarget, int radius)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lbej;<init>(Ljava/util/function/Predicate;FZI)V
      intermediary <init> Lnet/minecraft/class_4815;<init>(Ljava/util/function/Predicate;FZI)V
      named <init> Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;<init>(Ljava/util/function/Predicate;FZI)V
  • Method Details

    • shouldRun

      protected boolean shouldRun(ServerWorld world, E entity)
      Overrides:
      shouldRun in class Task<E extends LivingEntity>
      Mappings:
      Namespace Name Mixin selector
      official a Lbdo;a(Lagg;Lbcc;)Z
      intermediary method_18919 Lnet/minecraft/class_4097;method_18919(Lnet/minecraft/class_3218;Lnet/minecraft/class_1309;)Z
      named shouldRun Lnet/minecraft/entity/ai/brain/task/Task;shouldRun(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/entity/LivingEntity;)Z
    • run

      protected void run(ServerWorld world, E entity, long time)
      Overrides:
      run in class Task<E extends LivingEntity>
      Mappings:
      Namespace Name Mixin selector
      official a Lbdo;a(Lagg;Lbcc;J)V
      intermediary method_18920 Lnet/minecraft/class_4097;method_18920(Lnet/minecraft/class_3218;Lnet/minecraft/class_1309;J)V
      named run Lnet/minecraft/entity/ai/brain/task/Task;run(Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/entity/LivingEntity;J)V
    • isInPickupCooldown

      private boolean isInPickupCooldown(E entity)
      Mappings:
      Namespace Name Mixin selector
      official a Lbej;a(Lbcc;)Z
      intermediary method_42652 Lnet/minecraft/class_4815;method_42652(Lnet/minecraft/class_1309;)Z
      named isInPickupCooldown Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;isInPickupCooldown(Lnet/minecraft/entity/LivingEntity;)Z
    • getNearestVisibleWantedItem

      private ItemEntity getNearestVisibleWantedItem(E entity)
      Mappings:
      Namespace Name Mixin selector
      official b Lbej;b(Lbcc;)Lbqv;
      intermediary method_24580 Lnet/minecraft/class_4815;method_24580(Lnet/minecraft/class_1309;)Lnet/minecraft/class_1542;
      named getNearestVisibleWantedItem Lnet/minecraft/entity/ai/brain/task/WalkToNearestVisibleWantedItemTask;getNearestVisibleWantedItem(Lnet/minecraft/entity/LivingEntity;)Lnet/minecraft/entity/ItemEntity;