Class MultiTask<E extends LivingEntity>
- java.lang.Object
-
- net.minecraft.entity.ai.brain.task.Task<E>
-
- net.minecraft.entity.ai.brain.task.MultiTask<E>
-
- Direct Known Subclasses:
FirstShuffledTask
public class MultiTask<E extends LivingEntity> extends Task<E>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
MultiTask.Ordering
(package private) static class
MultiTask.RunType
-
Nested classes/interfaces inherited from class net.minecraft.entity.ai.brain.task.Task
Task.Status
-
-
Field Summary
Fields Modifier and Type Field Description private WeightedList<Task<? super E>>
behaviors
private java.util.Set<MemoryModuleType<?>>
exitErasedMemories
private MultiTask.Ordering
orderPolicy
private MultiTask.RunType
runningPolicy
-
Fields inherited from class net.minecraft.entity.ai.brain.task.Task
entryCondition
-
-
Constructor Summary
Constructors Constructor Description MultiTask(java.util.Map<MemoryModuleType<?>,MemoryModuleStatus> p_i51503_1_, java.util.Set<MemoryModuleType<?>> p_i51503_2_, MultiTask.Ordering p_i51503_3_, MultiTask.RunType p_i51503_4_, java.util.List<com.mojang.datafixers.util.Pair<Task<? super E>,java.lang.Integer>> p_i51503_5_)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
canStillUse(ServerWorld p_212834_1_, E p_212834_2_, long p_212834_3_)
protected void
start(ServerWorld p_212831_1_, E p_212831_2_, long p_212831_3_)
protected void
stop(ServerWorld p_212835_1_, E p_212835_2_, long p_212835_3_)
protected void
tick(ServerWorld p_212833_1_, E p_212833_2_, long p_212833_3_)
protected boolean
timedOut(long p_220383_1_)
java.lang.String
toString()
-
Methods inherited from class net.minecraft.entity.ai.brain.task.Task
checkExtraStartConditions, doStop, getStatus, tickOrStop, tryStart
-
-
-
-
Field Detail
-
exitErasedMemories
private final java.util.Set<MemoryModuleType<?>> exitErasedMemories
-
orderPolicy
private final MultiTask.Ordering orderPolicy
-
runningPolicy
private final MultiTask.RunType runningPolicy
-
behaviors
private final WeightedList<Task<? super E extends LivingEntity>> behaviors
-
-
Constructor Detail
-
MultiTask
public MultiTask(java.util.Map<MemoryModuleType<?>,MemoryModuleStatus> p_i51503_1_, java.util.Set<MemoryModuleType<?>> p_i51503_2_, MultiTask.Ordering p_i51503_3_, MultiTask.RunType p_i51503_4_, java.util.List<com.mojang.datafixers.util.Pair<Task<? super E>,java.lang.Integer>> p_i51503_5_)
-
-
Method Detail
-
canStillUse
protected boolean canStillUse(ServerWorld p_212834_1_, E p_212834_2_, long p_212834_3_)
- Overrides:
canStillUse
in classTask<E extends LivingEntity>
-
timedOut
protected boolean timedOut(long p_220383_1_)
- Overrides:
timedOut
in classTask<E extends LivingEntity>
-
start
protected void start(ServerWorld p_212831_1_, E p_212831_2_, long p_212831_3_)
- Overrides:
start
in classTask<E extends LivingEntity>
-
tick
protected void tick(ServerWorld p_212833_1_, E p_212833_2_, long p_212833_3_)
- Overrides:
tick
in classTask<E extends LivingEntity>
-
stop
protected void stop(ServerWorld p_212835_1_, E p_212835_2_, long p_212835_3_)
- Overrides:
stop
in classTask<E extends LivingEntity>
-
toString
public java.lang.String toString()
- Overrides:
toString
in classTask<E extends LivingEntity>
-
-