Contents
Class PlayerMemories
java.lang.Object
com.hypixel.hytale.builtin.adventure.memories.component.PlayerMemories
- All Implemented Interfaces:
Component<EntityStore>, Cloneable
A component that represents the memories that a player entity has collected.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final BuilderCodec<PlayerMemories> The codec used to parsePlayerMemoriesinstances.Fields inherited from interface Component
EMPTY_ARRAY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()static ComponentType<EntityStore, PlayerMemories> intbooleanbooleanrecordMemory(Memory memory) Records a memory in the players memories.voidsetMemoriesCapacity(int memoriesCapacity) booleantakeMemories(Set<Memory> outMemories) Removes all the memories from this player's memories and adds it to the provided set.Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Component
cloneSerializable
-
Field Details
-
CODEC
The codec used to parsePlayerMemoriesinstances.
-
-
Constructor Details
-
PlayerMemories
public PlayerMemories()
-
-
Method Details
-
getComponentType
-
clone
- Specified by:
clonein interfaceComponent<EntityStore>- Returns:
- a clone instance of the original component instance.
-
getMemoriesCapacity
public int getMemoriesCapacity() -
setMemoriesCapacity
public void setMemoriesCapacity(int memoriesCapacity) -
recordMemory
Records a memory in the players memories.- Parameters:
memory- The memory to record.- Returns:
trueif the memory is new
-
hasMemories
public boolean hasMemories() -
takeMemories
-
getRecordedMemories
-