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 ClassesModifier and TypeClassDescriptionstatic enumstatic classNested 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
FieldsModifier and TypeFieldDescriptionstatic final net.minecraft.world.level.block.state.properties.BooleanPropertystatic final com.mojang.serialization.MapCodec<CartAssemblerBlock> static final net.minecraft.world.level.block.state.properties.BooleanPropertystatic 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, WATERLOGGEDFields 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
ConstructorsConstructorDescriptionCartAssemblerBlock(net.minecraft.world.level.block.state.BlockBehaviour.Properties properties) -
Method Summary
Modifier and TypeMethodDescriptionstatic booleancanAssembleTo(net.minecraft.world.entity.vehicle.AbstractMinecart cart) booleancanMakeSlopes(@NotNull net.minecraft.world.level.block.state.BlockState state, @NotNull net.minecraft.world.level.BlockGetter world, @NotNull net.minecraft.core.BlockPos pos) booleancanSurvive(@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> codec()static net.minecraft.world.level.block.state.BlockStatecreateAnchor(net.minecraft.world.level.block.state.BlockState state) protected voidcreateBlockStateDefinition(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.VoxelShapegetCollisionShape(@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.DirectiongetHorizontalDirection(net.minecraft.world.level.block.state.BlockState blockState) @NotNull net.minecraft.world.level.material.PushReactiongetPistonPushReaction(@NotNull net.minecraft.world.level.block.state.BlockState state) protected net.minecraft.core.Direction.AxisgetRailAxis(net.minecraft.world.level.block.state.BlockState state) static net.minecraft.world.level.block.state.BlockStategetRailBlock(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.VoxelShapegetShape(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 booleanisPathfindable(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.pathfinder.PathComputationType pathComputationType) net.minecraft.world.level.block.state.BlockStatemirror(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.Mirror mirror) voidneighborChanged(@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) voidonMinecartPass(@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.InteractionResultonSneakWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context) net.minecraft.world.InteractionResultonWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context) net.minecraft.world.level.block.state.BlockStaterotate(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.level.block.Rotation rotation) 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) Methods inherited from class net.minecraft.world.level.block.BaseRailBlock
getFluidState, getRailDirection, getStateForPlacement, isFlexibleRail, isRail, isRail, isStraight, onPlace, onRemove, updateDir, updateShape, updateState, updateStateMethods 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, withPropertiesOfMethods 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, 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 net.neoforged.neoforge.common.extensions.IBaseRailBlockExtension
getRailMaxSpeed, isValidRailShapeMethods 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, 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, 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, updateAfterWrenchedMethods 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
-
-
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:
createBlockStateDefinitionin classnet.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:
canMakeSlopesin interfacenet.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:
onMinecartPassin interfacenet.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:
useItemOnin classnet.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:
neighborChangedin classnet.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:
getShapePropertyin classnet.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:
getShapein classnet.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:
getCollisionShapein classnet.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:
getPistonPushReactionin interfacenet.neoforged.neoforge.common.extensions.IBlockExtension
-
getBlockEntityClass
- Specified by:
getBlockEntityClassin interfaceIBE<CartAssemblerBlockEntity>
-
getBlockEntityType
public net.minecraft.world.level.block.entity.BlockEntityType<? extends CartAssemblerBlockEntity> getBlockEntityType()- Specified by:
getBlockEntityTypein interfaceIBE<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:
canSurvivein classnet.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:
getRequiredItemsin interfaceSpecialBlockItemRequirement
-
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:
getDropsin classnet.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:
onSneakWrenchedin interfaceIWrenchable
-
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
-
onWrenched
public net.minecraft.world.InteractionResult onWrenched(net.minecraft.world.level.block.state.BlockState state, net.minecraft.world.item.context.UseOnContext context) - Specified by:
onWrenchedin interfaceIWrenchable
-
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:
rotatein classnet.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:
mirrorin classnet.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:
codecin classnet.minecraft.world.level.block.BaseRailBlock
-