Package net.minecraft
Class BlockUtil
java.lang.Object
net.minecraft.BlockUtil
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
static class
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic BlockUtil.FoundRectangle
getLargestRectangleAround
(BlockPos pCenterPos, Direction.Axis pAxis1, int pMax1, Direction.Axis pAxis2, int pMax2, Predicate<BlockPos> pPosPredicate) Finds the rectangle with the largest area containing centerPos within the blocks specified by the predicateprivate static int
getLimit
(Predicate<BlockPos> pPosPredicate, BlockPos.MutableBlockPos pCenterPos, Direction pDirection, int pMax) Finds the distance we can travel in the given direction while the predicate returns true(package private) static com.mojang.datafixers.util.Pair
<BlockUtil.IntBounds, Integer> getMaxRectangleLocation
(int[] p_124347_) getTopConnectedBlock
(BlockGetter pGetter, BlockPos pPos, Block pBaseBlock, Direction pDirection, Block pEndBlock)
-
Constructor Details
-
BlockUtil
public BlockUtil()
-
-
Method Details
-
getLargestRectangleAround
public static BlockUtil.FoundRectangle getLargestRectangleAround(BlockPos pCenterPos, Direction.Axis pAxis1, int pMax1, Direction.Axis pAxis2, int pMax2, Predicate<BlockPos> pPosPredicate) Finds the rectangle with the largest area containing centerPos within the blocks specified by the predicate -
getLimit
private static int getLimit(Predicate<BlockPos> pPosPredicate, BlockPos.MutableBlockPos pCenterPos, Direction pDirection, int pMax) Finds the distance we can travel in the given direction while the predicate returns true -
getMaxRectangleLocation
static com.mojang.datafixers.util.Pair<BlockUtil.IntBounds,Integer> getMaxRectangleLocation(int[] p_124347_) -
getTopConnectedBlock
-