Class ItemVaultBlockEntity
java.lang.Object
net.neoforged.neoforge.attachment.AttachmentHolder
net.minecraft.world.level.block.entity.BlockEntity
com.simibubi.create.foundation.blockEntity.SyncedBlockEntity
com.simibubi.create.foundation.blockEntity.CachedRenderBBBlockEntity
com.simibubi.create.foundation.blockEntity.SmartBlockEntity
com.simibubi.create.content.logistics.vault.ItemVaultBlockEntity
- All Implemented Interfaces:
PartialSafeNBT,SpecialBlockEntityItemRequirement,IMultiBlockEntityContainer,IMultiBlockEntityContainer.Inventory,IInteractionChecker,net.createmod.ponder.api.VirtualBlockEntity,net.neoforged.neoforge.attachment.IAttachmentHolder,net.neoforged.neoforge.common.extensions.IBlockEntityExtension
public class ItemVaultBlockEntity
extends SmartBlockEntity
implements IMultiBlockEntityContainer.Inventory
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.block.entity.BlockEntity
net.minecraft.world.level.block.entity.BlockEntity.DataComponentInputNested classes/interfaces inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
net.neoforged.neoforge.attachment.AttachmentHolder.AsFieldNested classes/interfaces inherited from interface com.simibubi.create.foundation.blockEntity.IMultiBlockEntityContainer
IMultiBlockEntityContainer.Fluid, IMultiBlockEntityContainer.Inventory -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected net.minecraft.core.BlockPosprotected net.neoforged.neoforge.items.ItemStackHandlerprotected InventoryIdentifierprotected ICapabilityProvider<net.neoforged.neoforge.items.IItemHandler> protected net.minecraft.core.BlockPosprotected intprotected intprotected booleanFields inherited from class com.simibubi.create.foundation.blockEntity.SmartBlockEntity
lazyTickCounter, lazyTickRateFields inherited from class net.minecraft.world.level.block.entity.BlockEntity
level, remove, worldPositionFields inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
ATTACHMENTS_NBT_KEY -
Constructor Summary
ConstructorsConstructorDescriptionItemVaultBlockEntity(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 TypeMethodDescriptionvoidaddBehaviours(List<BlockEntityBehaviour> behaviours) voidapplyInventoryToBlock(net.neoforged.neoforge.items.ItemStackHandler handler) net.minecraft.core.BlockPosintnet.neoforged.neoforge.items.ItemStackHandlergetInvId()net.minecraft.core.BlockPosnet.minecraft.core.Direction.Axisstatic intgetMaxLength(int radius) intgetMaxLength(net.minecraft.core.Direction.Axis longAxis, int width) intintgetWidth()booleanbooleanvoidvoidprotected voidread(net.minecraft.nbt.CompoundTag compound, net.minecraft.core.HolderLookup.Provider registries, boolean clientPacket) Hook only these in future subclasses of STEstatic voidregisterCapabilities(net.neoforged.neoforge.capabilities.RegisterCapabilitiesEvent event) voidremoveController(boolean keepContents) voidsetController(net.minecraft.core.BlockPos controller) voidsetHeight(int height) voidsetWidth(int width) voidtick()protected voidprotected voidprotected voidwrite(net.minecraft.nbt.CompoundTag compound, net.minecraft.core.HolderLookup.Provider registries, boolean clientPacket) Hook only these in future subclasses of STEMethods inherited from class com.simibubi.create.foundation.blockEntity.SmartBlockEntity
addBehavioursDeferred, attachBehaviourLate, award, awardIfNear, canPlayerUse, destroy, forEachBehaviour, getAllBehaviours, getBehaviour, getRequiredItems, initialize, invalidate, isChunkUnloaded, isVirtual, lazyTick, loadAdditional, markVirtual, onChunkUnloaded, readClient, refreshBlockState, registerAwardables, remove, removeBehaviour, saveAdditional, sendToMenu, setLazyTickRate, setRemoved, writeClient, writeSafeMethods inherited from class com.simibubi.create.foundation.blockEntity.CachedRenderBBBlockEntity
createRenderBoundingBox, getRenderBoundingBox, invalidateRenderBoundingBoxMethods inherited from class com.simibubi.create.foundation.blockEntity.SyncedBlockEntity
blockHolderGetter, getUpdatePacket, getUpdateTag, handleUpdateTag, notifyUpdate, onDataPacket, sendDataMethods inherited from class net.minecraft.world.level.block.entity.BlockEntity
addEntityType, applyComponents, applyComponentsFromItemStack, applyImplicitComponents, clearRemoved, collectComponents, collectImplicitComponents, components, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getPersistentData, getPosFromTag, getType, hasLevel, isRemoved, isValidBlockState, loadCustomOnly, loadStatic, loadWithComponents, onlyOpCanSetNbt, parseCustomNameSafe, removeComponentsFromTag, removeData, saveCustomAndMetadata, saveCustomOnly, saveToItem, saveWithFullMetadata, saveWithId, saveWithoutMetadata, setBlockState, setChanged, setChanged, setComponents, setData, setLevel, triggerEventMethods inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
deserializeAttachments, getData, getExistingData, hasAttachments, hasData, serializeAttachmentsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.neoforged.neoforge.attachment.IAttachmentHolder
getData, getExistingData, hasData, removeData, setDataMethods inherited from interface net.neoforged.neoforge.common.extensions.IBlockEntityExtension
getModelData, hasCustomOutlineRendering, invalidateCapabilities, onLoad, requestModelDataUpdateMethods inherited from interface com.simibubi.create.foundation.blockEntity.IMultiBlockEntityContainer
getExtraData, getMainAxisOf, modifyExtraData, setExtraData
-
Field Details
-
itemCapability
-
invId
-
inventory
protected net.neoforged.neoforge.items.ItemStackHandler inventory -
controller
protected net.minecraft.core.BlockPos controller -
lastKnownPos
protected net.minecraft.core.BlockPos lastKnownPos -
updateConnectivity
protected boolean updateConnectivity -
radius
protected int radius -
length
protected int length
-
-
Constructor Details
-
ItemVaultBlockEntity
public ItemVaultBlockEntity(net.minecraft.world.level.block.entity.BlockEntityType<?> type, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state)
-
-
Method Details
-
registerCapabilities
public static void registerCapabilities(net.neoforged.neoforge.capabilities.RegisterCapabilitiesEvent event) -
addBehaviours
- Specified by:
addBehavioursin classSmartBlockEntity
-
updateConnectivity
protected void updateConnectivity() -
updateComparators
protected void updateComparators() -
tick
public void tick()- Overrides:
tickin classSmartBlockEntity
-
getLastKnownPos
public net.minecraft.core.BlockPos getLastKnownPos()- Specified by:
getLastKnownPosin interfaceIMultiBlockEntityContainer
-
isController
public boolean isController()- Specified by:
isControllerin interfaceIMultiBlockEntityContainer
-
getControllerBE
- Specified by:
getControllerBEin interfaceIMultiBlockEntityContainer
-
removeController
public void removeController(boolean keepContents) - Specified by:
removeControllerin interfaceIMultiBlockEntityContainer
-
setController
public void setController(net.minecraft.core.BlockPos controller) - Specified by:
setControllerin interfaceIMultiBlockEntityContainer
-
getController
public net.minecraft.core.BlockPos getController()- Specified by:
getControllerin interfaceIMultiBlockEntityContainer
-
read
protected void read(net.minecraft.nbt.CompoundTag compound, net.minecraft.core.HolderLookup.Provider registries, boolean clientPacket) Description copied from class:SmartBlockEntityHook only these in future subclasses of STE- Overrides:
readin classSmartBlockEntity
-
write
protected void write(net.minecraft.nbt.CompoundTag compound, net.minecraft.core.HolderLookup.Provider registries, boolean clientPacket) Description copied from class:SmartBlockEntityHook only these in future subclasses of STE- Overrides:
writein classSmartBlockEntity
-
getInventoryOfBlock
public net.neoforged.neoforge.items.ItemStackHandler getInventoryOfBlock() -
getInvId
-
applyInventoryToBlock
public void applyInventoryToBlock(net.neoforged.neoforge.items.ItemStackHandler handler) -
getMaxLength
public static int getMaxLength(int radius) -
preventConnectivityUpdate
public void preventConnectivityUpdate()- Specified by:
preventConnectivityUpdatein interfaceIMultiBlockEntityContainer
-
notifyMultiUpdated
public void notifyMultiUpdated()- Specified by:
notifyMultiUpdatedin interfaceIMultiBlockEntityContainer
-
getMainConnectionAxis
public net.minecraft.core.Direction.Axis getMainConnectionAxis()- Specified by:
getMainConnectionAxisin interfaceIMultiBlockEntityContainer
-
getMaxLength
public int getMaxLength(net.minecraft.core.Direction.Axis longAxis, int width) - Specified by:
getMaxLengthin interfaceIMultiBlockEntityContainer
-
getMaxWidth
public int getMaxWidth()- Specified by:
getMaxWidthin interfaceIMultiBlockEntityContainer
-
getHeight
public int getHeight()- Specified by:
getHeightin interfaceIMultiBlockEntityContainer
-
getWidth
public int getWidth()- Specified by:
getWidthin interfaceIMultiBlockEntityContainer
-
setHeight
public void setHeight(int height) - Specified by:
setHeightin interfaceIMultiBlockEntityContainer
-
setWidth
public void setWidth(int width) - Specified by:
setWidthin interfaceIMultiBlockEntityContainer
-
hasInventory
public boolean hasInventory()- Specified by:
hasInventoryin interfaceIMultiBlockEntityContainer.Inventory
-