Class PickupWantedItemTask<E extends LivingEntity>
java.lang.Object
net.minecraft.entity.ai.brain.task.Task<E>
net.minecraft.entity.ai.brain.task.PickupWantedItemTask<E>
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.entity.ai.brain.task.Task
Task.Status
-
Field Summary
Modifier and TypeFieldDescriptionprivate final int
private final float
Fields inherited from class net.minecraft.entity.ai.brain.task.Task
entryCondition
-
Constructor Summary
ConstructorDescriptionPickupWantedItemTask
(float p_i231520_1_, boolean p_i231520_2_, int p_i231520_3_) PickupWantedItemTask
(Predicate<E> p_i231521_1_, float p_i231521_2_, boolean p_i231521_3_, int p_i231521_4_) -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
checkExtraStartConditions
(ServerWorld p_212832_1_, E p_212832_2_) private ItemEntity
getClosestLovedItem
(E p_233909_1_) protected void
start
(ServerWorld p_212831_1_, E p_212831_2_, long p_212831_3_) Methods inherited from class net.minecraft.entity.ai.brain.task.Task
canStillUse, doStop, getStatus, stop, tick, tickOrStop, timedOut, toString, tryStart
-
Field Details
-
predicate
-
maxDistToWalk
private final int maxDistToWalk -
speedModifier
private final float speedModifier
-
-
Constructor Details
-
PickupWantedItemTask
public PickupWantedItemTask(float p_i231520_1_, boolean p_i231520_2_, int p_i231520_3_) -
PickupWantedItemTask
-
-
Method Details
-
checkExtraStartConditions
- Overrides:
checkExtraStartConditions
in classTask<E extends LivingEntity>
-
start
- Overrides:
start
in classTask<E extends LivingEntity>
-
getClosestLovedItem
-