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.DoubleAttachFace

    Nested classes/interfaces inherited from class net.minecraft.world.level.block.Block

    net.minecraft.world.level.block.Block.BlockStatePairKey

    Nested 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

    Fields
    Modifier and Type
    Field
    Description
    protected final net.minecraft.world.item.DyeColor
     

    Fields inherited from class com.simibubi.create.content.redstone.nixieTube.DoubleFaceAttachedBlock

    CODEC, FACE

    Fields inherited from class net.minecraft.world.level.block.HorizontalDirectionalBlock

    FACING

    Fields 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_DROPS

    Fields inherited from class net.minecraft.world.level.block.state.BlockBehaviour

    drops, dynamicShape, explosionResistance, friction, hasCollision, isRandomlyTicking, jumpFactor, properties, requiredFeatures, soundType, speedFactor, UPDATE_SHAPE_ORDER

    Fields inherited from interface net.minecraft.world.flag.FeatureElement

    FILTERED_REGISTRIES
  • Constructor Summary

    Constructors
    Constructor
    Description
    NixieTubeBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties, net.minecraft.world.item.DyeColor color)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    areNixieBlocksEqual(net.minecraft.world.level.block.state.BlockState blockState, net.minecraft.world.level.block.state.BlockState otherState)
     
    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)
     
    static net.minecraft.world.item.DyeColor
    colorOf(net.minecraft.world.level.block.state.BlockState blockState)
     
    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)
     
     
    net.minecraft.world.level.block.entity.BlockEntityType<? extends NixieTubeBlockEntity>
     
    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)
     
    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)
     
    net.minecraft.world.item.DyeColor
     
    static net.minecraft.core.Direction
    getFacing(net.minecraft.world.level.block.state.BlockState sideState)
     
    net.minecraft.world.level.material.FluidState
    getFluidState(net.minecraft.world.level.block.state.BlockState state)
     
    static net.minecraft.core.Direction
    getLeftNixieDirection(@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.Direction
    getRightNixieDirection(@NotNull net.minecraft.world.level.block.state.BlockState state)
     
    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)
     
    net.minecraft.world.level.block.state.BlockState
    getStateForPlacement(net.minecraft.world.item.context.BlockPlaceContext context)
     
    static boolean
    isInComputerControlledRow(@NotNull net.minecraft.world.level.LevelAccessor world, @NotNull net.minecraft.core.BlockPos pos)
     
    protected boolean
    isPathfindable(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.pathfinder.PathComputationType pathComputationType)
     
    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)
     
    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)
     
    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)
     
    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)
     
    static void
     
    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)
     
    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)
     
    static boolean
    walkNixies(@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.BlockState
    withColor(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, getConnectedDirection

    Methods inherited from class net.minecraft.world.level.block.HorizontalDirectionalBlock

    mirror, rotate

    Methods 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, withPropertiesOf

    Methods 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, useWithoutItem

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface net.minecraft.world.level.block.EntityBlock

    getListener

    Methods inherited from interface net.minecraft.world.flag.FeatureElement

    isEnabled

    Methods inherited from interface com.simibubi.create.foundation.block.IBE

    getBlockEntity, getBlockEntityOptional, getTicker, newBlockEntity, onBlockEntityUse, onBlockEntityUseItemOn, withBlockEntityDo

    Methods 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, supportsExternalFaceHiding

    Methods inherited from interface net.neoforged.neoforge.common.extensions.IBucketPickupExtension

    getPickupSound

    Methods inherited from interface com.simibubi.create.content.equipment.wrench.IWrenchable

    getRotatedBlockState, onSneakWrenched, onWrenched, updateAfterWrenched

    Methods 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:
      useItemOn in class net.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:
      createBlockStateDefinition in class net.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:
      onRemove in class net.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:
      getCloneItemStack in class net.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:
      getRequiredItems in interface SpecialBlockItemRequirement
    • 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:
      getShape in class net.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:
      getCloneItemStack in interface net.neoforged.neoforge.common.extensions.IBlockExtension
    • getFluidState

      public net.minecraft.world.level.material.FluidState getFluidState(net.minecraft.world.level.block.state.BlockState state)
      Overrides:
      getFluidState in class net.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:
      updateShape in class net.minecraft.world.level.block.state.BlockBehaviour
    • getStateForPlacement

      public net.minecraft.world.level.block.state.BlockState getStateForPlacement(net.minecraft.world.item.context.BlockPlaceContext context)
      Overrides:
      getStateForPlacement in class DoubleFaceAttachedBlock
    • 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:
      neighborChanged in class net.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:
      tick in class net.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:
      onPlace in class net.minecraft.world.level.block.state.BlockBehaviour
    • updateDisplayedRedstoneValue

      public static void updateDisplayedRedstoneValue(NixieTubeBlockEntity be, boolean force)
    • isPathfindable

      protected boolean isPathfindable(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.pathfinder.PathComputationType pathComputationType)
      Overrides:
      isPathfindable in class net.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:
      canConnectRedstone in interface net.neoforged.neoforge.common.extensions.IBlockExtension
    • getBlockEntityClass

      public Class<NixieTubeBlockEntity> getBlockEntityClass()
      Specified by:
      getBlockEntityClass in interface IBE<NixieTubeBlockEntity>
    • getBlockEntityType

      public net.minecraft.world.level.block.entity.BlockEntityType<? extends NixieTubeBlockEntity> getBlockEntityType()
      Specified by:
      getBlockEntityType in interface IBE<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)