Class NixieTubeBlock
java.lang.Object
net.minecraft.world.level.block.state.BlockBehaviour
net.minecraft.world.level.block.Block
net.minecraft.world.level.block.HorizontalDirectionalBlock
com.simibubi.create.content.redstone.nixieTube.DoubleFaceAttachedBlock
com.simibubi.create.content.redstone.nixieTube.NixieTubeBlock
- All Implemented Interfaces:
SpecialBlockItemRequirement,IWrenchable,IBE<NixieTubeBlockEntity>,net.minecraft.world.flag.FeatureElement,net.minecraft.world.level.block.BucketPickup,net.minecraft.world.level.block.EntityBlock,net.minecraft.world.level.block.LiquidBlockContainer,net.minecraft.world.level.block.SimpleWaterloggedBlock,net.minecraft.world.level.ItemLike,net.neoforged.neoforge.common.extensions.IBlockExtension,net.neoforged.neoforge.common.extensions.IBucketPickupExtension
public class NixieTubeBlock
extends DoubleFaceAttachedBlock
implements IBE<NixieTubeBlockEntity>, IWrenchable, net.minecraft.world.level.block.SimpleWaterloggedBlock, SpecialBlockItemRequirement
-
Nested Class Summary
Nested classes/interfaces inherited from class com.simibubi.create.content.redstone.nixieTube.DoubleFaceAttachedBlock
DoubleFaceAttachedBlock.DoubleAttachFaceNested classes/interfaces inherited from class net.minecraft.world.level.block.Block
net.minecraft.world.level.block.Block.BlockStatePairKeyNested classes/interfaces inherited from class net.minecraft.world.level.block.state.BlockBehaviour
net.minecraft.world.level.block.state.BlockBehaviour.BlockStateBase, net.minecraft.world.level.block.state.BlockBehaviour.OffsetFunction, net.minecraft.world.level.block.state.BlockBehaviour.OffsetType, net.minecraft.world.level.block.state.BlockBehaviour.Properties, net.minecraft.world.level.block.state.BlockBehaviour.StateArgumentPredicate<A>, net.minecraft.world.level.block.state.BlockBehaviour.StatePredicate -
Field Summary
FieldsFields inherited from class com.simibubi.create.content.redstone.nixieTube.DoubleFaceAttachedBlock
CODEC, FACEFields inherited from class net.minecraft.world.level.block.HorizontalDirectionalBlock
FACINGFields inherited from class net.minecraft.world.level.block.Block
BLOCK_STATE_REGISTRY, INDESTRUCTIBLE, INSTANT, stateDefinition, UPDATE_ALL, UPDATE_ALL_IMMEDIATE, UPDATE_CLIENTS, UPDATE_IMMEDIATE, UPDATE_INVISIBLE, UPDATE_KNOWN_SHAPE, UPDATE_LIMIT, UPDATE_MOVE_BY_PISTON, UPDATE_NEIGHBORS, UPDATE_NONE, UPDATE_SUPPRESS_DROPSFields inherited from class net.minecraft.world.level.block.state.BlockBehaviour
drops, dynamicShape, explosionResistance, friction, hasCollision, isRandomlyTicking, jumpFactor, properties, requiredFeatures, soundType, speedFactor, UPDATE_SHAPE_ORDERFields inherited from interface net.minecraft.world.flag.FeatureElement
FILTERED_REGISTRIES -
Constructor Summary
ConstructorsConstructorDescriptionNixieTubeBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties, net.minecraft.world.item.DyeColor color) -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanareNixieBlocksEqual(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.world.level.block.state.BlockState otherState) booleancanConnectRedstone(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockGetter world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction side) static net.minecraft.world.item.DyeColorcolorOf(net.minecraft.world.level.block.state.BlockState blockState) protected voidcreateBlockStateDefinition(net.minecraft.world.level.block.state.StateDefinition.Builder<net.minecraft.world.level.block.Block, net.minecraft.world.level.block.state.BlockState> builder) net.minecraft.world.level.block.entity.BlockEntityType<? extends NixieTubeBlockEntity> net.minecraft.world.item.ItemStackgetCloneItemStack(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.phys.HitResult target, net.minecraft.world.level.LevelReader level, net.minecraft.core.BlockPos pos, net.minecraft.world.entity.player.Player player) net.minecraft.world.item.ItemStackgetCloneItemStack(net.minecraft.world.level.LevelReader pLevel, net.minecraft.core.BlockPos pPos, net.minecraft.world.level.block.state.BlockState pState) net.minecraft.world.item.DyeColorgetColor()static net.minecraft.core.DirectiongetFacing(net.minecraft.world.level.block.state.BlockState sideState) net.minecraft.world.level.material.FluidStategetFluidState(net.minecraft.world.level.block.state.BlockState state) static net.minecraft.core.DirectiongetLeftNixieDirection(@NotNull net.minecraft.world.level.block.state.BlockState state) getRequiredItems(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.entity.BlockEntity be) static net.minecraft.core.DirectiongetRightNixieDirection(@NotNull net.minecraft.world.level.block.state.BlockState state) net.minecraft.world.phys.shapes.VoxelShapegetShape(net.minecraft.world.level.block.state.BlockState pState, net.minecraft.world.level.BlockGetter pLevel, net.minecraft.core.BlockPos pPos, net.minecraft.world.phys.shapes.CollisionContext pContext) net.minecraft.world.level.block.state.BlockStategetStateForPlacement(net.minecraft.world.item.context.BlockPlaceContext context) static booleanisInComputerControlledRow(@NotNull net.minecraft.world.level.LevelAccessor world, @NotNull net.minecraft.core.BlockPos pos) protected booleanisPathfindable(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.pathfinder.PathComputationType pathComputationType) voidneighborChanged(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.Block block, net.minecraft.core.BlockPos fromPos, boolean isMoving) voidonPlace(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level worldIn, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState oldState, boolean isMoving) voidonRemove(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState newState, boolean isMoving) voidtick(net.minecraft.world.level.block.state.BlockState state, net.minecraft.server.level.ServerLevel worldIn, net.minecraft.core.BlockPos pos, net.minecraft.util.RandomSource r) static voidupdateDisplayedRedstoneValue(NixieTubeBlockEntity be, net.minecraft.world.level.block.state.BlockState state, boolean force) net.minecraft.world.level.block.state.BlockStateupdateShape(net.minecraft.world.level.block.state.BlockState state, net.minecraft.core.Direction direction, net.minecraft.world.level.block.state.BlockState neighbourState, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos, net.minecraft.core.BlockPos neighbourPos) protected net.minecraft.world.ItemInteractionResultuseItemOn(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.entity.player.Player player, net.minecraft.world.InteractionHand hand, net.minecraft.world.phys.BlockHitResult hitResult) static booleanwalkNixies(@NotNull net.minecraft.world.level.LevelAccessor world, @NotNull net.minecraft.core.BlockPos start, boolean allowComputerControlled, @Nullable BiConsumer<net.minecraft.core.BlockPos, Integer> callback) Walk down a nixie tube row and execute a callback on each tube in said row.static net.minecraft.world.level.block.state.BlockStatewithColor(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.DyeColor color) Methods inherited from class com.simibubi.create.content.redstone.nixieTube.DoubleFaceAttachedBlock
codec, getConnectedDirectionMethods inherited from class net.minecraft.world.level.block.HorizontalDirectionalBlock
mirror, rotateMethods inherited from class net.minecraft.world.level.block.Block
animateTick, appendHoverText, asBlock, asItem, box, builtInRegistryHolder, byItem, canSupportCenter, canSupportRigidBlock, defaultBlockState, destroy, dropFromExplosion, dropResources, dropResources, dropResources, fallOn, getDescriptionId, getDrops, getDrops, getExplosionResistance, getFriction, getId, getJumpFactor, getName, getShapeForEachState, getSpeedFactor, getStateDefinition, handlePrecipitation, hasDynamicShape, initializeClient, isExceptionForConnection, isFaceFull, isPossibleToRespawnInThis, isShapeFullBlock, playerDestroy, playerWillDestroy, popExperience, popResource, popResourceFromFace, pushEntitiesUp, registerDefaultState, setPlacedBy, shouldRenderFace, spawnDestroyParticles, stateById, stepOn, toString, tryDropExperience, updateEntityAfterFallOn, updateFromNeighbourShapes, updateOrDestroy, updateOrDestroy, wasExploded, withPropertiesOfMethods inherited from class net.minecraft.world.level.block.state.BlockBehaviour
attack, canBeReplaced, canBeReplaced, canSurvive, defaultDestroyTime, defaultMapColor, entityInside, getAnalogOutputSignal, getBlockSupportShape, getCollisionShape, getDestroyProgress, getDirectSignal, getDrops, getInteractionShape, getLightBlock, getLootTable, getMaxHorizontalOffset, getMaxVerticalOffset, getMenuProvider, getOcclusionShape, getRenderShape, getSeed, getShadeBrightness, getSignal, getSoundType, getVisualShape, hasAnalogOutputSignal, isAir, isCollisionShapeFullBlock, isOcclusionShapeFullBlock, isRandomlyTicking, isSignalSource, onExplosionHit, onProjectileHit, propagatesSkylightDown, properties, propertiesCodec, randomTick, requiredFeatures, simpleCodec, skipRendering, spawnAfterBreak, triggerEvent, updateIndirectNeighbourShapes, useShapeForLightOcclusion, useWithoutItemMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.world.level.block.EntityBlock
getListenerMethods inherited from interface net.minecraft.world.flag.FeatureElement
isEnabledMethods inherited from interface com.simibubi.create.foundation.block.IBE
getBlockEntity, getBlockEntityOptional, getTicker, newBlockEntity, onBlockEntityUse, onBlockEntityUseItemOn, withBlockEntityDoMethods inherited from interface net.neoforged.neoforge.common.extensions.IBlockExtension
addLandingEffects, addRunningEffects, canBeHydrated, canDropFromExplosion, canEntityDestroy, canHarvestBlock, canStickTo, canSustainPlant, collisionExtendsVertically, getAdjacentBlockPathType, getAppearance, getBeaconColorMultiplier, getBedDirection, getBlockPathType, getBubbleColumnDirection, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getFireSpreadSpeed, getFlammability, getFriction, getLightEmission, getMapColor, getPistonPushReaction, getRespawnPosition, getSoundType, getStateAtViewpoint, getToolModifiedState, getWeakChanges, hasDynamicLightEmission, hidesNeighborFace, isBed, isBurning, isConduitFrame, isEmpty, isFertile, isFireSource, isFlammable, isLadder, isPortalFrame, isScaffolding, isSlimeBlock, isStickyBlock, makesOpenTrapdoorAboveClimbable, onBlockExploded, onBlockStateChange, onCaughtFire, onDestroyedByPlayer, onDestroyedByPushReaction, onNeighborChange, onTreeGrow, rotate, setBedOccupied, shouldCheckWeakPower, shouldDisplayFluidOverlay, shouldHideAdjacentFluidFace, supportsExternalFaceHidingMethods inherited from interface net.neoforged.neoforge.common.extensions.IBucketPickupExtension
getPickupSoundMethods inherited from interface com.simibubi.create.content.equipment.wrench.IWrenchable
getRotatedBlockState, onSneakWrenched, onWrenched, updateAfterWrenchedMethods inherited from interface net.minecraft.world.level.block.SimpleWaterloggedBlock
canPlaceLiquid, getPickupSound, pickupBlock, placeLiquid
-
Field Details
-
color
protected final net.minecraft.world.item.DyeColor color
-
-
Constructor Details
-
NixieTubeBlock
public NixieTubeBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties, net.minecraft.world.item.DyeColor color)
-
-
Method Details
-
useItemOn
protected net.minecraft.world.ItemInteractionResult useItemOn(net.minecraft.world.item.ItemStack stack, net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.entity.player.Player player, net.minecraft.world.InteractionHand hand, net.minecraft.world.phys.BlockHitResult hitResult) - Overrides:
useItemOnin classnet.minecraft.world.level.block.state.BlockBehaviour
-
getLeftNixieDirection
public static net.minecraft.core.Direction getLeftNixieDirection(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state) -
getRightNixieDirection
public static net.minecraft.core.Direction getRightNixieDirection(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state) -
isInComputerControlledRow
public static boolean isInComputerControlledRow(@NotNull @NotNull net.minecraft.world.level.LevelAccessor world, @NotNull @NotNull net.minecraft.core.BlockPos pos) -
walkNixies
public static boolean walkNixies(@NotNull @NotNull net.minecraft.world.level.LevelAccessor world, @NotNull @NotNull net.minecraft.core.BlockPos start, boolean allowComputerControlled, @Nullable @Nullable BiConsumer<net.minecraft.core.BlockPos, Integer> callback) Walk down a nixie tube row and execute a callback on each tube in said row.- Parameters:
world- The world the tubes are in.start- Start position for the walk.allowComputerControlled- Allow or disallow running callbacks if the row is computer-controlled.callback- Callback to run for each tube.- Returns:
- True if the row was walked, false if the walk was aborted because it is computer-controlled.
-
createBlockStateDefinition
protected void createBlockStateDefinition(net.minecraft.world.level.block.state.StateDefinition.Builder<net.minecraft.world.level.block.Block, net.minecraft.world.level.block.state.BlockState> builder) - Overrides:
createBlockStateDefinitionin classnet.minecraft.world.level.block.Block
-
onRemove
public void onRemove(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level world, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState newState, boolean isMoving) - Overrides:
onRemovein classnet.minecraft.world.level.block.state.BlockBehaviour
-
getCloneItemStack
public net.minecraft.world.item.ItemStack getCloneItemStack(net.minecraft.world.level.LevelReader pLevel, net.minecraft.core.BlockPos pPos, net.minecraft.world.level.block.state.BlockState pState) - Overrides:
getCloneItemStackin classnet.minecraft.world.level.block.Block
-
getRequiredItems
public ItemRequirement getRequiredItems(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.entity.BlockEntity be) - Specified by:
getRequiredItemsin interfaceSpecialBlockItemRequirement
-
getShape
public net.minecraft.world.phys.shapes.VoxelShape getShape(net.minecraft.world.level.block.state.BlockState pState, net.minecraft.world.level.BlockGetter pLevel, net.minecraft.core.BlockPos pPos, net.minecraft.world.phys.shapes.CollisionContext pContext) - Overrides:
getShapein classnet.minecraft.world.level.block.state.BlockBehaviour
-
getCloneItemStack
public net.minecraft.world.item.ItemStack getCloneItemStack(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.phys.HitResult target, net.minecraft.world.level.LevelReader level, net.minecraft.core.BlockPos pos, net.minecraft.world.entity.player.Player player) - Specified by:
getCloneItemStackin interfacenet.neoforged.neoforge.common.extensions.IBlockExtension
-
getFluidState
public net.minecraft.world.level.material.FluidState getFluidState(net.minecraft.world.level.block.state.BlockState state) - Overrides:
getFluidStatein classnet.minecraft.world.level.block.state.BlockBehaviour
-
updateShape
public net.minecraft.world.level.block.state.BlockState updateShape(net.minecraft.world.level.block.state.BlockState state, net.minecraft.core.Direction direction, net.minecraft.world.level.block.state.BlockState neighbourState, net.minecraft.world.level.LevelAccessor world, net.minecraft.core.BlockPos pos, net.minecraft.core.BlockPos neighbourPos) - Overrides:
updateShapein classnet.minecraft.world.level.block.state.BlockBehaviour
-
getStateForPlacement
public net.minecraft.world.level.block.state.BlockState getStateForPlacement(net.minecraft.world.item.context.BlockPlaceContext context) - Overrides:
getStateForPlacementin classDoubleFaceAttachedBlock
-
neighborChanged
public void neighborChanged(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.Block block, net.minecraft.core.BlockPos fromPos, boolean isMoving) - Overrides:
neighborChangedin classnet.minecraft.world.level.block.state.BlockBehaviour
-
tick
public void tick(net.minecraft.world.level.block.state.BlockState state, net.minecraft.server.level.ServerLevel worldIn, net.minecraft.core.BlockPos pos, net.minecraft.util.RandomSource r) - Overrides:
tickin classnet.minecraft.world.level.block.state.BlockBehaviour
-
onPlace
public void onPlace(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.Level worldIn, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState oldState, boolean isMoving) - Overrides:
onPlacein classnet.minecraft.world.level.block.state.BlockBehaviour
-
updateDisplayedRedstoneValue
public static void updateDisplayedRedstoneValue(NixieTubeBlockEntity be, net.minecraft.world.level.block.state.BlockState state, boolean force) -
isPathfindable
protected boolean isPathfindable(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.pathfinder.PathComputationType pathComputationType) - Overrides:
isPathfindablein classnet.minecraft.world.level.block.state.BlockBehaviour
-
canConnectRedstone
public boolean canConnectRedstone(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.BlockGetter world, net.minecraft.core.BlockPos pos, net.minecraft.core.Direction side) - Specified by:
canConnectRedstonein interfacenet.neoforged.neoforge.common.extensions.IBlockExtension
-
getBlockEntityClass
- Specified by:
getBlockEntityClassin interfaceIBE<NixieTubeBlockEntity>
-
getBlockEntityType
public net.minecraft.world.level.block.entity.BlockEntityType<? extends NixieTubeBlockEntity> getBlockEntityType()- Specified by:
getBlockEntityTypein interfaceIBE<NixieTubeBlockEntity>
-
getColor
public net.minecraft.world.item.DyeColor getColor() -
areNixieBlocksEqual
public static boolean areNixieBlocksEqual(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.world.level.block.state.BlockState otherState) -
withColor
public static net.minecraft.world.level.block.state.BlockState withColor(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.DyeColor color) -
colorOf
public static net.minecraft.world.item.DyeColor colorOf(net.minecraft.world.level.block.state.BlockState blockState) -
getFacing
public static net.minecraft.core.Direction getFacing(net.minecraft.world.level.block.state.BlockState sideState)
-