Class ConduitBlockEntity
java.lang.Object
net.neoforged.neoforge.attachment.AttachmentHolder
net.minecraft.world.level.block.entity.BlockEntity
net.minecraft.world.level.block.entity.ConduitBlockEntity
- All Implemented Interfaces:
IAttachmentHolder
,IBlockEntityExtension
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.block.entity.BlockEntity
BlockEntity.ComponentHelper, BlockEntity.DataComponentInput
Nested classes/interfaces inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
AttachmentHolder.AsField
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate float
private static final int
private LivingEntity
private UUID
private static final int
private boolean
private boolean
private static final int
private static final int
private static final int
private long
private static final float
int
private static final Block[]
Fields inherited from class net.minecraft.world.level.block.entity.BlockEntity
level, remove, worldPosition
Fields inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
ATTACHMENTS_NBT_KEY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
private static void
applyEffects
(Level level, BlockPos pos, List<BlockPos> positions) static void
clientTick
(Level level, BlockPos pos, BlockState state, ConduitBlockEntity blockEntity) private static LivingEntity
findDestroyTarget
(Level level, BlockPos pos, UUID targetId) float
getActiveRotation
(float partialTick) private static AABB
getUpdateTag
(HolderLookup.Provider registries) boolean
isActive()
boolean
protected void
loadAdditional
(CompoundTag tag, HolderLookup.Provider registries) protected void
saveAdditional
(CompoundTag tag, HolderLookup.Provider registries) static void
serverTick
(Level level, BlockPos pos, BlockState state, ConduitBlockEntity blockEntity) private void
setHunting
(boolean isHunting) private static void
updateClientTarget
(Level level, BlockPos pos, ConduitBlockEntity blockEntity) private static void
updateDestroyTarget
(Level level, BlockPos pos, BlockState state, List<BlockPos> positions, ConduitBlockEntity blockEntity) private static void
updateHunting
(ConduitBlockEntity blockEntity, List<BlockPos> positions) private static boolean
updateShape
(Level level, BlockPos pos, List<BlockPos> positions) Methods 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, setRemoved, triggerEvent
Methods inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
deserializeAttachments, getData, getExistingDataOrNull, hasAttachments, hasData, serializeAttachments
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.neoforged.neoforge.attachment.IAttachmentHolder
getData, getExistingData, getExistingData, getExistingDataOrNull, hasData, removeData, setData
Methods inherited from interface net.neoforged.neoforge.common.extensions.IBlockEntityExtension
getModelData, handleUpdateTag, hasCustomOutlineRendering, invalidateCapabilities, onChunkUnloaded, onDataPacket, onLoad, requestModelDataUpdate
-
Field Details
-
BLOCK_REFRESH_RATE
private static final int BLOCK_REFRESH_RATE- See Also:
-
EFFECT_DURATION
private static final int EFFECT_DURATION- See Also:
-
ROTATION_SPEED
private static final float ROTATION_SPEED- See Also:
-
MIN_ACTIVE_SIZE
private static final int MIN_ACTIVE_SIZE- See Also:
-
MIN_KILL_SIZE
private static final int MIN_KILL_SIZE- See Also:
-
KILL_RANGE
private static final int KILL_RANGE- See Also:
-
VALID_BLOCKS
-
tickCount
public int tickCount -
activeRotation
private float activeRotation -
isActive
private boolean isActive -
isHunting
private boolean isHunting -
effectBlocks
-
destroyTarget
-
destroyTargetUUID
-
nextAmbientSoundActivation
private long nextAmbientSoundActivation
-
-
Constructor Details
-
ConduitBlockEntity
-
-
Method Details
-
loadAdditional
- Overrides:
loadAdditional
in classBlockEntity
-
saveAdditional
- Overrides:
saveAdditional
in classBlockEntity
-
getUpdatePacket
- Overrides:
getUpdatePacket
in classBlockEntity
-
getUpdateTag
- Overrides:
getUpdateTag
in classBlockEntity
-
clientTick
public static void clientTick(Level level, BlockPos pos, BlockState state, ConduitBlockEntity blockEntity) -
serverTick
public static void serverTick(Level level, BlockPos pos, BlockState state, ConduitBlockEntity blockEntity) -
updateHunting
-
updateShape
-
applyEffects
-
updateDestroyTarget
private static void updateDestroyTarget(Level level, BlockPos pos, BlockState state, List<BlockPos> positions, ConduitBlockEntity blockEntity) -
updateClientTarget
-
getDestroyRangeAABB
-
findDestroyTarget
-
animationTick
-
isActive
public boolean isActive() -
isHunting
public boolean isHunting() -
setHunting
private void setHunting(boolean isHunting) -
getActiveRotation
public float getActiveRotation(float partialTick)
-