public class AgeableStore<T extends GlowAgeable> extends LivingEntityStore<T>
entityType, type
Constructor and Description |
---|
AgeableStore(Class<T> clazz,
org.bukkit.entity.EntityType type,
Function<org.bukkit.Location,? extends T> creator) |
AgeableStore(Class<T> clazz,
String type,
Function<org.bukkit.Location,? extends T> creator) |
Modifier and Type | Method and Description |
---|---|
T |
createEntity(org.bukkit.Location location,
CompoundTag compound)
Create a new entity of this store's type at the given location.
|
void |
load(T entity,
CompoundTag compound)
Load data into an existing entity of the appropriate type from the given compound tag.
|
void |
save(T entity,
CompoundTag tag)
Save information about this entity to the given tag.
|
canEqual, createEntity, equals, getEntityType, getType, hashCode, toString
public AgeableStore(Class<T> clazz, org.bukkit.entity.EntityType type, Function<org.bukkit.Location,? extends T> creator)
public T createEntity(org.bukkit.Location location, CompoundTag compound)
EntityStore
createEntity
in class EntityStore<T extends GlowAgeable>
location
- The location.compound
- The entity's tag, if extra data is needed.public void load(T entity, CompoundTag compound)
EntityStore
entity
- The target entity.compound
- The entity's tag.public void save(T entity, CompoundTag tag)
EntityStore
entity
- The entity to save.tag
- The target tag.Copyright © 2021. All rights reserved.