public final class VoxelShapes
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
VoxelShapes.ILineConsumer |
Modifier and Type | Field and Description |
---|---|
private static VoxelShape |
EMPTY |
private static VoxelShape |
FULL_CUBE |
static VoxelShape |
INFINITY |
Constructor and Description |
---|
VoxelShapes() |
Modifier and Type | Method and Description |
---|---|
static VoxelShape |
combine(VoxelShape shape1,
VoxelShape shape2,
IBooleanFunction function) |
static VoxelShape |
combineAndSimplify(VoxelShape shape1,
VoxelShape shape2,
IBooleanFunction function) |
static boolean |
compare(VoxelShape shape1,
VoxelShape shape2,
IBooleanFunction function) |
static VoxelShape |
create(AxisAlignedBB aabb) |
static VoxelShape |
create(double x1,
double y1,
double z1,
double x2,
double y2,
double z2) |
static boolean |
doAdjacentCubeSidesFillSquare(VoxelShape shape,
VoxelShape adjacentShape,
Direction side) |
static VoxelShape |
empty() |
static boolean |
faceShapeCovers(VoxelShape voxelShape1,
VoxelShape voxelShape2) |
static VoxelShape |
fullCube() |
private static double |
getAllowedOffset(AxisAlignedBB collisionBox,
IWorldReader worldReader,
double desiredOffset,
ISelectionContext selectionContext,
AxisRotation rotationAxis,
java.util.stream.Stream<VoxelShape> possibleHits) |
static double |
getAllowedOffset(Direction.Axis movementAxis,
AxisAlignedBB collisionBox,
IWorldReader worldReader,
double desiredOffset,
ISelectionContext selectionContext,
java.util.stream.Stream<VoxelShape> possibleHits) |
static double |
getAllowedOffset(Direction.Axis movementAxis,
AxisAlignedBB collisionBox,
java.util.stream.Stream<VoxelShape> possibleHits,
double desiredOffset) |
private static int |
getDifferenceFloored(double desiredOffset,
double min,
double max) |
static VoxelShape |
getFaceShape(VoxelShape voxelShapeIn,
Direction directionIn) |
private static int |
getPrecisionBits(double p_197885_0_,
double p_197885_2_) |
static boolean |
isCubeSideCovered(VoxelShape shape,
VoxelShape adjacentShape,
Direction side) |
private static boolean |
join(IDoubleListMerger p_197874_0_,
IDoubleListMerger p_197874_1_,
IDoubleListMerger p_197874_2_,
VoxelShapePart p_197874_3_,
VoxelShapePart p_197874_4_,
IBooleanFunction p_197874_5_) |
protected static long |
lcm(int aa,
int bb) |
protected static IDoubleListMerger |
makeListMerger(int p_199410_0_,
it.unimi.dsi.fastutil.doubles.DoubleList list1,
it.unimi.dsi.fastutil.doubles.DoubleList list2,
boolean p_199410_3_,
boolean p_199410_4_) |
static VoxelShape |
or(VoxelShape p_216384_0_,
VoxelShape... p_216384_1_) |
static VoxelShape |
or(VoxelShape shape1,
VoxelShape shape2) |
private static final VoxelShape FULL_CUBE
public static final VoxelShape INFINITY
private static final VoxelShape EMPTY
public static VoxelShape empty()
public static VoxelShape fullCube()
public static VoxelShape create(double x1, double y1, double z1, double x2, double y2, double z2)
public static VoxelShape create(AxisAlignedBB aabb)
private static int getPrecisionBits(double p_197885_0_, double p_197885_2_)
protected static long lcm(int aa, int bb)
public static VoxelShape or(VoxelShape shape1, VoxelShape shape2)
public static VoxelShape or(VoxelShape p_216384_0_, VoxelShape... p_216384_1_)
public static VoxelShape combineAndSimplify(VoxelShape shape1, VoxelShape shape2, IBooleanFunction function)
public static VoxelShape combine(VoxelShape shape1, VoxelShape shape2, IBooleanFunction function)
public static boolean compare(VoxelShape shape1, VoxelShape shape2, IBooleanFunction function)
private static boolean join(IDoubleListMerger p_197874_0_, IDoubleListMerger p_197874_1_, IDoubleListMerger p_197874_2_, VoxelShapePart p_197874_3_, VoxelShapePart p_197874_4_, IBooleanFunction p_197874_5_)
public static double getAllowedOffset(Direction.Axis movementAxis, AxisAlignedBB collisionBox, java.util.stream.Stream<VoxelShape> possibleHits, double desiredOffset)
public static double getAllowedOffset(Direction.Axis movementAxis, AxisAlignedBB collisionBox, IWorldReader worldReader, double desiredOffset, ISelectionContext selectionContext, java.util.stream.Stream<VoxelShape> possibleHits)
private static double getAllowedOffset(AxisAlignedBB collisionBox, IWorldReader worldReader, double desiredOffset, ISelectionContext selectionContext, AxisRotation rotationAxis, java.util.stream.Stream<VoxelShape> possibleHits)
private static int getDifferenceFloored(double desiredOffset, double min, double max)
public static boolean isCubeSideCovered(VoxelShape shape, VoxelShape adjacentShape, Direction side)
public static VoxelShape getFaceShape(VoxelShape voxelShapeIn, Direction directionIn)
public static boolean doAdjacentCubeSidesFillSquare(VoxelShape shape, VoxelShape adjacentShape, Direction side)
public static boolean faceShapeCovers(VoxelShape voxelShape1, VoxelShape voxelShape2)
protected static IDoubleListMerger makeListMerger(int p_199410_0_, it.unimi.dsi.fastutil.doubles.DoubleList list1, it.unimi.dsi.fastutil.doubles.DoubleList list2, boolean p_199410_3_, boolean p_199410_4_)