Package net.minecraft.entity.ai.brain
Class Brain.MemoryCodec<U>
- java.lang.Object
-
- net.minecraft.entity.ai.brain.Brain.MemoryCodec<U>
-
- Enclosing class:
- Brain<E extends LivingEntity>
static final class Brain.MemoryCodec<U> extends java.lang.Object
-
-
Constructor Summary
Constructors Modifier Constructor Description private
MemoryCodec(MemoryModuleType<U> p_i231496_1_, java.util.Optional<? extends Memory<U>> p_i231496_2_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private static <U> Brain.MemoryCodec<U>
createUnchecked(MemoryModuleType<U> p_233743_0_, java.util.Optional<? extends Memory<?>> p_233743_1_)
<T> void
serialize(com.mojang.serialization.DynamicOps<T> p_233740_1_, com.mojang.serialization.RecordBuilder<T> p_233740_2_)
private void
setMemoryInternal(Brain<?> p_233738_1_)
-
-
-
Field Detail
-
type
private final MemoryModuleType<U> type
-
-
Constructor Detail
-
MemoryCodec
private MemoryCodec(MemoryModuleType<U> p_i231496_1_, java.util.Optional<? extends Memory<U>> p_i231496_2_)
-
-
Method Detail
-
createUnchecked
private static <U> Brain.MemoryCodec<U> createUnchecked(MemoryModuleType<U> p_233743_0_, java.util.Optional<? extends Memory<?>> p_233743_1_)
-
setMemoryInternal
private void setMemoryInternal(Brain<?> p_233738_1_)
-
serialize
public <T> void serialize(com.mojang.serialization.DynamicOps<T> p_233740_1_, com.mojang.serialization.RecordBuilder<T> p_233740_2_)
-
-