Class BlockPropertyTests.LightBlockEntity
java.lang.Object
net.neoforged.neoforge.attachment.AttachmentHolder
net.minecraft.world.level.block.entity.BlockEntity
net.neoforged.neoforge.debug.block.BlockPropertyTests.LightBlockEntity
- All Implemented Interfaces:
- IAttachmentHolder,- IBlockEntityExtension,- INBTSerializable<CompoundTag>
- Enclosing class:
- BlockPropertyTests
- 
Nested Class SummaryNested classes/interfaces inherited from class net.neoforged.neoforge.attachment.AttachmentHolderAttachmentHolder.AsField
- 
Field SummaryFieldsFields inherited from class net.minecraft.world.level.block.entity.BlockEntitylevel, remove, worldPositionFields inherited from class net.neoforged.neoforge.attachment.AttachmentHolderATTACHMENTS_NBT_KEY
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidCalled when the chunk's TE update tag, gotten fromBlockEntity.getUpdateTag(), is received on the client.voidload(CompoundTag tag) voidCalled when you receive a TileEntityData packet for the location this TileEntity is currently in.protected voidprivate voidsetLit(boolean lit) voidMethods inherited from class net.minecraft.world.level.block.entity.BlockEntityaddEntityType, clearRemoved, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getPersistentData, getPosFromTag, getType, hasLevel, isRemoved, loadStatic, onlyOpCanSetNbt, removeData, saveToItem, saveWithFullMetadata, saveWithId, saveWithoutMetadata, setBlockState, setChanged, setChanged, setData, setLevel, setRemoved, triggerEventMethods inherited from class net.neoforged.neoforge.attachment.AttachmentHolderareAttachmentsCompatible, deserializeAttachments, getData, hasAttachments, hasData, serializeAttachmentsMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.neoforged.neoforge.attachment.IAttachmentHoldergetData, hasData, removeData, setDataMethods inherited from interface net.neoforged.neoforge.common.extensions.IBlockEntityExtensiondeserializeNBT, getModelData, hasCustomOutlineRendering, invalidateCapabilities, onChunkUnloaded, onLoad, requestModelDataUpdate, serializeNBT
- 
Field Details- 
litprivate boolean lit
 
- 
- 
Constructor Details- 
LightBlockEntity
 
- 
- 
Method Details- 
switchLightpublic void switchLight()
- 
setLitprivate void setLit(boolean lit) 
- 
getUpdatePacket- Overrides:
- getUpdatePacketin class- BlockEntity
 
- 
onDataPacketDescription copied from interface:IBlockEntityExtensionCalled when you receive a TileEntityData packet for the location this TileEntity is currently in. On the client, the NetworkManager will always be the remote server. On the server, it will be whomever is responsible for sending the packet.- Parameters:
- net- The NetworkManager the packet originated from
- pkt- The data packet
 
- 
getUpdateTag- Overrides:
- getUpdateTagin class- BlockEntity
 
- 
handleUpdateTagDescription copied from interface:IBlockEntityExtensionCalled when the chunk's TE update tag, gotten fromBlockEntity.getUpdateTag(), is received on the client.Used to handle this tag in a special way. By default this simply calls BlockEntity.load(CompoundTag).- Parameters:
- tag- The- CompoundTagsent from- BlockEntity.getUpdateTag()
 
- 
load- Overrides:
- loadin class- BlockEntity
 
- 
saveAdditional- Overrides:
- saveAdditionalin class- BlockEntity
 
 
-