net.minecraft.block

public class MultifaceBlock

extends Block implements Waterloggable

All mapped superinterfaces:

ToggleableFeature, ItemConvertible, Waterloggable, FluidDrainable, FluidFillable

net.minecraft.world.level.block.MultifaceBlock
net.minecraft.world.level.block.MultifaceBlock
net.minecraft.class_5778
net.minecraft.block.MultifaceBlock

Field summary

Modifier and TypeField
public static final com.mojang.serialization.MapCodec<MultifaceBlock>
CODEC
CODEC
field_55079
CODEC
public static final BooleanProperty
WATERLOGGED
WATERLOGGED
field_55497
WATERLOGGED
private static final Map<Direction, BooleanProperty>
PROPERTY_BY_DIRECTION
PROPERTY_BY_DIRECTION
field_28419
FACING_PROPERTIES
protected static final Direction[]
DIRECTIONS
DIRECTIONS
field_28421
DIRECTIONS
private final Function<BlockState, VoxelShape>
shapes
shapes
field_55780
shapeFunction
private final boolean
canRotate
canRotate
field_28423
hasAllHorizontalDirections
private final boolean
canMirrorX
canMirrorX
field_28424
canMirrorX
private final boolean
canMirrorZ
canMirrorZ
field_28425
canMirrorZ

Constructor summary

ModifierConstructor
public (AbstractBlock$Settings properties)

Method summary

Modifier and TypeMethod
protected com.mojang.serialization.MapCodec<? extends MultifaceBlock>
codec()
codec()
method_53969()
getCodec()
private Function<BlockState, VoxelShape>
makeShapes()
makeShapes()
method_66455()
createShapeFunction()
public static Set<Direction>
availableFaces(BlockState state)
availableFaces(BlockState state)
method_41440(class_2680 arg0)
collectDirections(BlockState state)
public static Set<Direction>
unpack(byte data)
unpack(byte data)
method_41437(byte arg0)
flagToDirections(byte flag)
public static byte
pack(Collection<Direction> directions)
pack(Collection<Direction> directions)
method_41439(Collection<class_2350> arg0)
directionsToFlag(Collection<Direction> directions)
protected boolean
isFaceSupported(Direction faceDirection)
isFaceSupported(Direction faceDirection)
method_33369(class_2350 arg0)
canHaveDirection(Direction direction)
protected void
createBlockStateDefinition(StateDefinition$Builder<Block, BlockState> builder)
createBlockStateDefinition(StateDefinition$Builder<Block, BlockState> builder)
method_9515(class_2689$class_2690<class_2248, class_2680> arg0)
appendProperties(StateManager$Builder<Block, BlockState> arg0)
protected BlockState
updateShape(BlockState state, LevelReader level, ScheduledTickAccess ticks, BlockPos pos, Direction directionToNeighbour, BlockPos neighbourPos, BlockState neighbourState, RandomSource random)
updateShape(BlockState state, LevelReader level, ScheduledTickAccess ticks, BlockPos pos, Direction directionToNeighbour, BlockPos neighbourPos, BlockState neighbourState, RandomSource random)
method_9559(class_2680 arg0, class_4538 arg1, class_10225 arg2, class_2338 arg3, class_2350 arg4, class_2338 arg5, class_2680 arg6, class_5819 arg7)
getStateForNeighborUpdate(BlockState arg0, WorldView arg1, ScheduledTickView arg2, BlockPos arg3, Direction arg4, BlockPos arg5, BlockState arg6, Random arg7)
protected FluidState
getFluidState(BlockState state)
getFluidState(BlockState state)
method_9545(class_2680 arg0)
getFluidState(BlockState arg0)
protected VoxelShape
getShape(BlockState state, BlockGetter level, BlockPos pos, CollisionContext context)
getShape(BlockState state, BlockGetter level, BlockPos pos, CollisionContext context)
method_9530(class_2680 arg0, class_1922 arg1, class_2338 arg2, class_3726 arg3)
getOutlineShape(BlockState arg0, BlockView arg1, BlockPos arg2, ShapeContext arg3)
protected boolean
canSurvive(BlockState state, LevelReader level, BlockPos pos)
canSurvive(BlockState state, LevelReader level, BlockPos pos)
method_9558(class_2680 arg0, class_4538 arg1, class_2338 arg2)
canPlaceAt(BlockState arg0, WorldView arg1, BlockPos arg2)
protected boolean
canBeReplaced(BlockState state, BlockPlaceContext context)
canBeReplaced(BlockState state, BlockPlaceContext context)
method_9616(class_2680 arg0, class_1750 arg1)
canReplace(BlockState arg0, ItemPlacementContext arg1)
public BlockState
getStateForPlacement(BlockPlaceContext context)
getStateForPlacement(BlockPlaceContext context)
method_9605(class_1750 arg0)
getPlacementState(ItemPlacementContext arg0)
public boolean
isValidStateForPlacement(BlockGetter level, BlockState oldState, BlockPos placementPos, Direction placementDirection)
isValidStateForPlacement(BlockGetter level, BlockState oldState, BlockPos placementPos, Direction placementDirection)
method_41438(class_1922 arg0, class_2680 arg1, class_2338 arg2, class_2350 arg3)
canGrowWithDirection(BlockView world, BlockState state, BlockPos pos, Direction direction)
public BlockState
getStateForPlacement(BlockState oldState, BlockGetter level, BlockPos placementPos, Direction placementDirection)
getStateForPlacement(BlockState oldState, BlockGetter level, BlockPos placementPos, Direction placementDirection)
method_33362(class_2680 arg0, class_1922 arg1, class_2338 arg2, class_2350 arg3)
withDirection(BlockState state, BlockView world, BlockPos pos, Direction direction)
protected BlockState
rotate(BlockState state, Rotation rotation)
rotate(BlockState state, Rotation rotation)
method_9598(class_2680 arg0, class_2470 arg1)
rotate(BlockState arg0, BlockRotation arg1)
protected BlockState
mirror(BlockState state, Mirror mirror)
mirror(BlockState state, Mirror mirror)
method_9569(class_2680 arg0, class_2415 arg1)
mirror(BlockState arg0, BlockMirror arg1)
private BlockState
mapDirections(BlockState state, Function<Direction, Direction> mapping)
mapDirections(BlockState state, Function<Direction, Direction> mapping)
method_33367(class_2680 arg0, Function<class_2350, class_2350> arg1)
mirror(BlockState state, Function<Direction, Direction> mirror)
public static boolean
hasFace(BlockState state, Direction faceDirection)
hasFace(BlockState state, Direction faceDirection)
method_33366(class_2680 arg0, class_2350 arg1)
hasDirection(BlockState state, Direction direction)
public static boolean
canAttachTo(BlockGetter level, BlockPos pos, Direction directionTowardsNeighbour)
canAttachTo(BlockGetter level, BlockPos pos, Direction directionTowardsNeighbour)
method_65162(class_1922 arg0, class_2338 arg1, class_2350 arg2)
canGrowOn(BlockView world, BlockPos pos, Direction direction)
public static boolean
canAttachTo(BlockGetter level, Direction directionTowardsNeighbour, BlockPos neighbourPos, BlockState neighbourState)
canAttachTo(BlockGetter level, Direction directionTowardsNeighbour, BlockPos neighbourPos, BlockState neighbourState)
method_33358(class_1922 arg0, class_2350 arg1, class_2338 arg2, class_2680 arg3)
canGrowOn(BlockView world, Direction direction, BlockPos pos, BlockState state)
private static BlockState
removeFace(BlockState state, BooleanProperty property)
removeFace(BlockState state, BooleanProperty property)
method_33365(class_2680 arg0, class_2746 arg1)
disableDirection(BlockState state, BooleanProperty direction)
public static BooleanProperty
getFaceProperty(Direction faceDirection)
getFaceProperty(Direction faceDirection)
method_33374(class_2350 arg0)
getProperty(Direction direction)
private static BlockState
getDefaultMultifaceState(StateDefinition<Block, BlockState> stateDefinition)
getDefaultMultifaceState(StateDefinition<Block, BlockState> stateDefinition)
method_33368(class_2689<class_2248, class_2680> arg0)
withAllDirections(StateManager<Block, BlockState> stateManager)
protected static boolean
hasAnyFace(BlockState state)
hasAnyFace(BlockState state)
method_33381(class_2680 arg0)
hasAnyDirection(BlockState state)
private static boolean
hasAnyVacantFace(BlockState state)
hasAnyVacantFace(BlockState state)
method_33382(class_2680 arg0)
isNotFullBlock(BlockState state)