public interface IEntityDataCapability
extends net.minecraftforge.common.capabilities.ICapabilitySerializable<net.minecraft.nbt.NBTBase>
| Modifier and Type | Method and Description |
|---|---|
<T extends net.minecraft.entity.Entity> |
getData()
Gets all registered entity data on this cap
|
<T extends net.minecraft.entity.Entity> |
getData(java.lang.String identifier)
Gets registered entity data with the given identifier
|
void |
init(net.minecraft.entity.Entity entity,
net.minecraft.world.World world,
boolean init)
Initialize this data context.
|
void |
loadFromNBT(net.minecraft.nbt.NBTTagCompound compound)
Loads this capability from NBT.
|
<T extends net.minecraft.entity.Entity> |
registerData(IEntityData<T> data)
Registered entity data to this capability
|
void |
saveToNBT(net.minecraft.nbt.NBTTagCompound compound)
Saves this capability to NBT.
|
void init(net.minecraft.entity.Entity entity,
net.minecraft.world.World world,
boolean init)
entity - the new entityworld - the new worldinit - true if all managers should be initializedvoid saveToNBT(net.minecraft.nbt.NBTTagCompound compound)
compound - the tag to write tovoid loadFromNBT(net.minecraft.nbt.NBTTagCompound compound)
compound - the tag to read from<T extends net.minecraft.entity.Entity> void registerData(IEntityData<T> data)
T - the entity typedata - the data to register@Nullable <T extends net.minecraft.entity.Entity> IEntityData<T> getData(java.lang.String identifier)
T - the entity typeidentifier - the identifier to retrieve<T extends net.minecraft.entity.Entity> java.util.List<IEntityData<T>> getData()
T - the entity type