Class EntityMemories
java.lang.Object
me.gamercoder215.mobchip.ai.memories.EntityMemories
Utility class for Entity Memories
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
doesMemoryExist
(@NotNull Memory<?> memory) Whether this entity has the given memory.static boolean
registerMemory
(@NotNull Memory<?> memory) Registers a new memory in the registry.
-
Method Details
-
registerMemory
public static boolean registerMemory(@NotNull @NotNull Memory<?> memory) throws IllegalArgumentException Registers a new memory in the registry.- Parameters:
memory
- Memory to register- Returns:
- true if memory was registered, false if memory already exists
- Throws:
IllegalArgumentException
- if memory is null
-
doesMemoryExist
Whether this entity has the given memory.- Parameters:
memory
- Memory to check- Returns:
- true if memory exists, false if memory does not exist
-