Class CartAssemblerBlock

java.lang.Object
net.minecraft.world.level.block.state.BlockBehaviour
net.minecraft.world.level.block.Block
net.minecraft.world.level.block.BaseRailBlock
com.simibubi.create.content.contraptions.mounted.CartAssemblerBlock
All Implemented Interfaces:
SpecialBlockItemRequirement, IWrenchable, IBE<CartAssemblerBlockEntity>, 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.IBaseRailBlockExtension, net.neoforged.neoforge.common.extensions.IBlockExtension, net.neoforged.neoforge.common.extensions.IBucketPickupExtension

public class CartAssemblerBlock extends net.minecraft.world.level.block.BaseRailBlock implements IBE<CartAssemblerBlockEntity>, IWrenchable, SpecialBlockItemRequirement
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
     
    static class 
     

    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
    static final net.minecraft.world.level.block.state.properties.BooleanProperty
     
    static final com.mojang.serialization.MapCodec<CartAssemblerBlock>
     
    static final net.minecraft.world.level.block.state.properties.BooleanProperty
     
    static final net.minecraft.world.level.block.state.properties.Property<net.minecraft.world.level.block.state.properties.RailShape>
     
    static final net.minecraft.world.level.block.state.properties.Property<CartAssembleRailType>
     

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

    FLAT_AABB, HALF_BLOCK_AABB, WATERLOGGED

    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
    CartAssemblerBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    canAssembleTo(net.minecraft.world.entity.vehicle.AbstractMinecart cart)
     
    boolean
    canMakeSlopes(@NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.BlockGetter world, @NotNull net.minecraft.core.BlockPos pos)
     
    boolean
    canSurvive(@NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.LevelReader world, @NotNull net.minecraft.core.BlockPos pos)
     
    protected @NotNull com.mojang.serialization.MapCodec<? extends net.minecraft.world.level.block.BaseRailBlock>
     
    static net.minecraft.world.level.block.state.BlockState
    createAnchor(net.minecraft.world.level.block.state.BlockState state)
     
    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)
     
    getActionForCart(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.entity.vehicle.AbstractMinecart cart)
     
     
    net.minecraft.world.level.block.entity.BlockEntityType<? extends CartAssemblerBlockEntity>
     
    @NotNull net.minecraft.world.phys.shapes.VoxelShape
    getCollisionShape(@NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.BlockGetter worldIn, @NotNull net.minecraft.core.BlockPos pos, net.minecraft.world.phys.shapes.CollisionContext context)
     
    @NotNull List<net.minecraft.world.item.ItemStack>
    getDrops(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.storage.loot.LootParams.Builder builder)
     
    List<net.minecraft.world.item.ItemStack>
    getDropsNoRail(net.minecraft.world.level.block.state.BlockState state, net.minecraft.server.level.ServerLevel world, net.minecraft.core.BlockPos pos, @Nullable net.minecraft.world.level.block.entity.BlockEntity p_220077_3_, @Nullable net.minecraft.world.entity.Entity p_220077_4_, net.minecraft.world.item.ItemStack p_220077_5_)
     
    static net.minecraft.core.Direction
    getHorizontalDirection(net.minecraft.world.level.block.state.BlockState blockState)
     
    @NotNull net.minecraft.world.level.material.PushReaction
    getPistonPushReaction(@NotNull net.minecraft.world.level.block.state.BlockState state)
     
    protected net.minecraft.core.Direction.Axis
    getRailAxis(net.minecraft.world.level.block.state.BlockState state)
     
    static net.minecraft.world.level.block.state.BlockState
    getRailBlock(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)
     
    @NotNull net.minecraft.world.phys.shapes.VoxelShape
    getShape(net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.BlockGetter worldIn, @NotNull net.minecraft.core.BlockPos pos, @NotNull net.minecraft.world.phys.shapes.CollisionContext context)
     
    @NotNull net.minecraft.world.level.block.state.properties.Property<net.minecraft.world.level.block.state.properties.RailShape>
     
    protected boolean
    isPathfindable(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.pathfinder.PathComputationType pathComputationType)
     
    net.minecraft.world.level.block.state.BlockState
    mirror(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.Mirror mirror)
     
    void
    neighborChanged(@NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.Level worldIn, @NotNull net.minecraft.core.BlockPos pos, @NotNull net.minecraft.world.level.block.Block blockIn, @NotNull net.minecraft.core.BlockPos fromPos, boolean isMoving)
     
    void
    onMinecartPass(@NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.Level world, @NotNull net.minecraft.core.BlockPos pos, net.minecraft.world.entity.vehicle.AbstractMinecart cart)
     
    net.minecraft.world.InteractionResult
    onSneakWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context)
     
    net.minecraft.world.InteractionResult
    onWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context)
     
    net.minecraft.world.level.block.state.BlockState
    rotate(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.Rotation rotation)
     
    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)
     

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

    getFluidState, getRailDirection, getStateForPlacement, isFlexibleRail, isRail, isRail, isStraight, onPlace, onRemove, updateDir, updateShape, updateState, updateState

    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, getCloneItemStack, 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, defaultDestroyTime, defaultMapColor, entityInside, getAnalogOutputSignal, getBlockSupportShape, getDestroyProgress, getDirectSignal, 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, tick, 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 net.neoforged.neoforge.common.extensions.IBaseRailBlockExtension

    getRailMaxSpeed, isValidRailShape

    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, canConnectRedstone, canDropFromExplosion, canEntityDestroy, canHarvestBlock, canStickTo, canSustainPlant, collisionExtendsVertically, getAdjacentBlockPathType, getAppearance, getBeaconColorMultiplier, getBedDirection, getBlockPathType, getBubbleColumnDirection, getCloneItemStack, getEnchantPowerBonus, getExpDrop, getExplosionResistance, getFireSpreadSpeed, getFlammability, getFriction, getLightEmission, getMapColor, getRespawnPosition, getSoundType, getStateAtViewpoint, getToolModifiedState, getWeakChanges, hasDynamicLightEmission, hidesNeighborFace, ignitedByLava, 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, updateAfterWrenched

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

    canPlaceLiquid, getPickupSound, pickupBlock, placeLiquid
  • Field Details

    • POWERED

      public static final net.minecraft.world.level.block.state.properties.BooleanProperty POWERED
    • BACKWARDS

      public static final net.minecraft.world.level.block.state.properties.BooleanProperty BACKWARDS
    • RAIL_SHAPE

      public static final net.minecraft.world.level.block.state.properties.Property<net.minecraft.world.level.block.state.properties.RailShape> RAIL_SHAPE
    • RAIL_TYPE

      public static final net.minecraft.world.level.block.state.properties.Property<CartAssembleRailType> RAIL_TYPE
    • CODEC

      public static final com.mojang.serialization.MapCodec<CartAssemblerBlock> CODEC
  • Constructor Details

    • CartAssemblerBlock

      public CartAssemblerBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties)
  • Method Details

    • createAnchor

      public static net.minecraft.world.level.block.state.BlockState createAnchor(net.minecraft.world.level.block.state.BlockState state)
    • getRailBlock

      public static net.minecraft.world.level.block.state.BlockState getRailBlock(net.minecraft.world.level.block.state.BlockState state)
    • 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
    • canMakeSlopes

      public boolean canMakeSlopes(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull @NotNull net.minecraft.world.level.BlockGetter world, @NotNull @NotNull net.minecraft.core.BlockPos pos)
      Specified by:
      canMakeSlopes in interface net.neoforged.neoforge.common.extensions.IBaseRailBlockExtension
    • onMinecartPass

      public void onMinecartPass(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull @NotNull net.minecraft.world.level.Level world, @NotNull @NotNull net.minecraft.core.BlockPos pos, net.minecraft.world.entity.vehicle.AbstractMinecart cart)
      Specified by:
      onMinecartPass in interface net.neoforged.neoforge.common.extensions.IBaseRailBlockExtension
    • getActionForCart

      public static CartAssemblerBlock.CartAssemblerAction getActionForCart(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.entity.vehicle.AbstractMinecart cart)
    • canAssembleTo

      public static boolean canAssembleTo(net.minecraft.world.entity.vehicle.AbstractMinecart cart)
    • 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
    • neighborChanged

      public void neighborChanged(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull @NotNull net.minecraft.world.level.Level worldIn, @NotNull @NotNull net.minecraft.core.BlockPos pos, @NotNull @NotNull net.minecraft.world.level.block.Block blockIn, @NotNull @NotNull net.minecraft.core.BlockPos fromPos, boolean isMoving)
      Overrides:
      neighborChanged in class net.minecraft.world.level.block.BaseRailBlock
    • getShapeProperty

      @NotNull public @NotNull net.minecraft.world.level.block.state.properties.Property<net.minecraft.world.level.block.state.properties.RailShape> getShapeProperty()
      Specified by:
      getShapeProperty in class net.minecraft.world.level.block.BaseRailBlock
    • getShape

      @NotNull public @NotNull net.minecraft.world.phys.shapes.VoxelShape getShape(net.minecraft.world.level.block.state.BlockState state, @NotNull @NotNull net.minecraft.world.level.BlockGetter worldIn, @NotNull @NotNull net.minecraft.core.BlockPos pos, @NotNull @NotNull net.minecraft.world.phys.shapes.CollisionContext context)
      Overrides:
      getShape in class net.minecraft.world.level.block.BaseRailBlock
    • getRailAxis

      protected net.minecraft.core.Direction.Axis getRailAxis(net.minecraft.world.level.block.state.BlockState state)
    • getCollisionShape

      @NotNull public @NotNull net.minecraft.world.phys.shapes.VoxelShape getCollisionShape(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull @NotNull net.minecraft.world.level.BlockGetter worldIn, @NotNull @NotNull net.minecraft.core.BlockPos pos, net.minecraft.world.phys.shapes.CollisionContext context)
      Overrides:
      getCollisionShape in class net.minecraft.world.level.block.state.BlockBehaviour
    • getPistonPushReaction

      @NotNull public @NotNull net.minecraft.world.level.material.PushReaction getPistonPushReaction(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state)
      Specified by:
      getPistonPushReaction in interface net.neoforged.neoforge.common.extensions.IBlockExtension
    • getBlockEntityClass

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

      public net.minecraft.world.level.block.entity.BlockEntityType<? extends CartAssemblerBlockEntity> getBlockEntityType()
      Specified by:
      getBlockEntityType in interface IBE<CartAssemblerBlockEntity>
    • canSurvive

      public boolean canSurvive(@NotNull @NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull @NotNull net.minecraft.world.level.LevelReader world, @NotNull @NotNull net.minecraft.core.BlockPos pos)
      Overrides:
      canSurvive in class net.minecraft.world.level.block.BaseRailBlock
    • 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
    • getDrops

      @NotNull public @NotNull List<net.minecraft.world.item.ItemStack> getDrops(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.storage.loot.LootParams.Builder builder)
      Overrides:
      getDrops in class net.minecraft.world.level.block.state.BlockBehaviour
    • getDropsNoRail

      public List<net.minecraft.world.item.ItemStack> getDropsNoRail(net.minecraft.world.level.block.state.BlockState state, net.minecraft.server.level.ServerLevel world, net.minecraft.core.BlockPos pos, @Nullable @Nullable net.minecraft.world.level.block.entity.BlockEntity p_220077_3_, @Nullable @Nullable net.minecraft.world.entity.Entity p_220077_4_, net.minecraft.world.item.ItemStack p_220077_5_)
    • onSneakWrenched

      public net.minecraft.world.InteractionResult onSneakWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context)
      Specified by:
      onSneakWrenched in interface IWrenchable
    • 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
    • onWrenched

      public net.minecraft.world.InteractionResult onWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context)
      Specified by:
      onWrenched in interface IWrenchable
    • rotate

      public net.minecraft.world.level.block.state.BlockState rotate(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.Rotation rotation)
      Overrides:
      rotate in class net.minecraft.world.level.block.state.BlockBehaviour
    • mirror

      public net.minecraft.world.level.block.state.BlockState mirror(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.Mirror mirror)
      Overrides:
      mirror in class net.minecraft.world.level.block.state.BlockBehaviour
    • getHorizontalDirection

      public static net.minecraft.core.Direction getHorizontalDirection(net.minecraft.world.level.block.state.BlockState blockState)
    • codec

      @NotNull protected @NotNull com.mojang.serialization.MapCodec<? extends net.minecraft.world.level.block.BaseRailBlock> codec()
      Specified by:
      codec in class net.minecraft.world.level.block.BaseRailBlock