public abstract class UTileEntity
extends net.minecraft.tileentity.TileEntity
TileEntity with some extra data synchronization methods.| Constructor and Description |
|---|
UTileEntity(net.minecraft.tileentity.TileEntityType<?> type) |
| Modifier and Type | Method and Description |
|---|---|
net.minecraft.network.play.server.SUpdateTileEntityPacket |
getUpdatePacket() |
net.minecraft.nbt.CompoundNBT |
getUpdateTag() |
void |
handleChunkLoadData(net.minecraft.nbt.CompoundNBT compound)
The data from the chunk load is received here.
|
void |
handleUpdateStateData(net.minecraft.nbt.CompoundNBT compound)
The data from the block update is received here.
|
void |
handleUpdateTag(net.minecraft.nbt.CompoundNBT compound) |
void |
onDataPacket(net.minecraft.network.NetworkManager manager,
net.minecraft.network.play.server.SUpdateTileEntityPacket packet) |
void |
read(net.minecraft.nbt.CompoundNBT compound) |
void |
readNBT(net.minecraft.nbt.CompoundNBT compound)
Reads data from disk.
|
void |
sendChangesToClient()
Calls
sendChangesToClient(int) with flag 2 (send changes to client) |
void |
sendChangesToClient(int flags)
Triggers a block update to send the data from the server to the client.
|
void |
sendChunkLoadData(net.minecraft.nbt.CompoundNBT compound)
Data here will be send to the client side when the chunk is loaded.
|
void |
sendUpdateStateData(net.minecraft.nbt.CompoundNBT compound)
Data here will be send to the client side when the block is updated.
|
net.minecraft.nbt.CompoundNBT |
write(net.minecraft.nbt.CompoundNBT compound) |
void |
writeNBT(net.minecraft.nbt.CompoundNBT compound)
Save data to disk.
|
addInfoToCrashReport, create, getBlockState, getDistanceSq, getMaxRenderDistanceSquared, getPos, getTileData, getType, getWorld, hasWorld, isRemoved, markDirty, mirror, onlyOpsCanSetNbt, receiveClientEvent, remove, rotate, setPos, setWorld, updateContainingBlockInfo, validate, warnInvalidBlockareCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, getCapabilities, getCapability, invalidateCaps, reviveCaps, serializeCapsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitpublic net.minecraft.nbt.CompoundNBT write(net.minecraft.nbt.CompoundNBT compound)
write in class net.minecraft.tileentity.TileEntitypublic void read(net.minecraft.nbt.CompoundNBT compound)
read in class net.minecraft.tileentity.TileEntitypublic void writeNBT(net.minecraft.nbt.CompoundNBT compound)
TileEntity.markDirty() method must be called before.compound - public void readNBT(net.minecraft.nbt.CompoundNBT compound)
compound - public net.minecraft.nbt.CompoundNBT getUpdateTag()
getUpdateTag in class net.minecraft.tileentity.TileEntitypublic void handleUpdateTag(net.minecraft.nbt.CompoundNBT compound)
public void sendChunkLoadData(net.minecraft.nbt.CompoundNBT compound)
handleChunkLoadData(CompoundNBT)compound - public void handleChunkLoadData(net.minecraft.nbt.CompoundNBT compound)
sendChunkLoadData(CompoundNBT)compound - public net.minecraft.network.play.server.SUpdateTileEntityPacket getUpdatePacket()
getUpdatePacket in class net.minecraft.tileentity.TileEntitypublic void onDataPacket(net.minecraft.network.NetworkManager manager,
net.minecraft.network.play.server.SUpdateTileEntityPacket packet)
public void sendUpdateStateData(net.minecraft.nbt.CompoundNBT compound)
handleUpdateStateData(CompoundNBT). To trigger an update call
World.notifyBlockUpdate(net.minecraft.util.math.BlockPos, BlockState, BlockState, int) or
sendChangesToClient(int)compound - public void handleUpdateStateData(net.minecraft.nbt.CompoundNBT compound)
sendUpdateStateData(CompoundNBT)compound - public void sendChangesToClient()
sendChangesToClient(int) with flag 2 (send changes to client)public void sendChangesToClient(int flags)
World.setBlockState(net.minecraft.util.math.BlockPos, BlockState, int)flags - Are described above