Class AbstractMultiBlockEntity
java.lang.Object
net.minecraft.world.level.block.entity.BlockEntity
net.nikdo53.tinymultiblocklib.blockentities.AbstractMultiBlockEntity
- All Implemented Interfaces:
net.fabricmc.fabric.api.attachment.v1.AttachmentTarget,net.fabricmc.fabric.api.blockview.v2.RenderDataBlockEntity,IMultiBlockEntity
- Direct Known Subclasses:
AbstractStructureMultiBlockEntity,SimpleMultiBlockEntity
public class AbstractMultiBlockEntity
extends net.minecraft.world.level.block.entity.BlockEntity
implements IMultiBlockEntity
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.block.entity.BlockEntity
net.minecraft.world.level.block.entity.BlockEntity.DataComponentInput -
Field Summary
Fields inherited from class net.minecraft.world.level.block.entity.BlockEntity
level, remove, worldPositionFields inherited from interface net.fabricmc.fabric.api.attachment.v1.AttachmentTarget
NBT_ATTACHMENT_KEY -
Constructor Summary
ConstructorsConstructorDescriptionAbstractMultiBlockEntity(net.minecraft.world.level.block.entity.BlockEntityType<?> type, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state) -
Method Summary
Modifier and TypeMethodDescriptionList<net.minecraft.core.BlockPos> net.minecraft.core.BlockPosnet.minecraft.network.protocol.Packet<net.minecraft.network.protocol.game.ClientGamePacketListener> @NotNull net.minecraft.nbt.CompoundTaggetUpdateTag(net.minecraft.core.HolderLookup.Provider registries) voidbooleanisPlaced()True once the whole placing logic runs (to prevent updateShape from breaking it early)protected voidloadAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider registries) protected voidsaveAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider registries) voidsetFullBlockShapeCache(List<net.minecraft.core.BlockPos> blockPosList) voidsetOffset(net.minecraft.core.BlockPos offset) voidsetPlaced(boolean placed) Methods inherited from class net.minecraft.world.level.block.entity.BlockEntity
addEntityType, applyComponents, applyComponentsFromItemStack, applyImplicitComponents, clearRemoved, collectComponents, collectImplicitComponents, components, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getPosFromTag, getType, hasLevel, isRemoved, isValidBlockState, loadCustomOnly, loadStatic, loadWithComponents, onlyOpCanSetNbt, parseCustomNameSafe, removeComponentsFromTag, saveCustomAndMetadata, saveCustomOnly, saveToItem, saveWithFullMetadata, saveWithId, saveWithoutMetadata, setBlockState, setChanged, setChanged, setComponents, setLevel, setRemoved, triggerEventMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.fabricmc.fabric.api.attachment.v1.AttachmentTarget
getAttached, getAttachedOrCreate, getAttachedOrCreate, getAttachedOrElse, getAttachedOrGet, getAttachedOrSet, getAttachedOrThrow, hasAttached, modifyAttached, removeAttached, setAttachedMethods inherited from interface net.nikdo53.tinymultiblocklib.blockentities.IMultiBlockEntity
getBlockEntity, getCenter, getPreviewMode, isCenter, setCenter, setPreviewModeMethods inherited from interface net.fabricmc.fabric.api.blockview.v2.RenderDataBlockEntity
getRenderData
-
Constructor Details
-
AbstractMultiBlockEntity
public AbstractMultiBlockEntity(net.minecraft.world.level.block.entity.BlockEntityType<?> type, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)
-
-
Method Details
-
saveAdditional
protected void saveAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider registries) - Overrides:
saveAdditionalin classnet.minecraft.world.level.block.entity.BlockEntity
-
getUpdateTag
@NotNull public @NotNull net.minecraft.nbt.CompoundTag getUpdateTag(net.minecraft.core.HolderLookup.Provider registries) - Overrides:
getUpdateTagin classnet.minecraft.world.level.block.entity.BlockEntity
-
loadAdditional
protected void loadAdditional(net.minecraft.nbt.CompoundTag tag, net.minecraft.core.HolderLookup.Provider registries) - Overrides:
loadAdditionalin classnet.minecraft.world.level.block.entity.BlockEntity
-
getUpdatePacket
public net.minecraft.network.protocol.Packet<net.minecraft.network.protocol.game.ClientGamePacketListener> getUpdatePacket()- Overrides:
getUpdatePacketin classnet.minecraft.world.level.block.entity.BlockEntity
-
getOffset
public net.minecraft.core.BlockPos getOffset()- Specified by:
getOffsetin interfaceIMultiBlockEntity
-
setOffset
public void setOffset(net.minecraft.core.BlockPos offset) - Specified by:
setOffsetin interfaceIMultiBlockEntity
-
isPlaced
public boolean isPlaced()Description copied from interface:IMultiBlockEntityTrue once the whole placing logic runs (to prevent updateShape from breaking it early)- Specified by:
isPlacedin interfaceIMultiBlockEntity
-
setPlaced
public void setPlaced(boolean placed) - Specified by:
setPlacedin interfaceIMultiBlockEntity
-
getFullBlockShapeCache
- Specified by:
getFullBlockShapeCachein interfaceIMultiBlockEntity
-
setFullBlockShapeCache
- Specified by:
setFullBlockShapeCachein interfaceIMultiBlockEntity
-
invalidateCaches
public void invalidateCaches()- Specified by:
invalidateCachesin interfaceIMultiBlockEntity
-