Package net.minecraft.gametest.framework
Class StructureUtils
java.lang.Object
net.minecraft.gametest.framework.StructureUtils
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
clearBlock
(int pStructureBlockY, BlockPos pPos, ServerLevel pServerLevel) static void
clearSpaceForStructure
(BoundingBox pBoundingBox, ServerLevel pLevel) static TestInstanceBlockEntity
createNewEmptyTest
(ResourceLocation pId, BlockPos pPos, Vec3i pSize, Rotation pRotation, ServerLevel pLevel) private static boolean
doesStructureContain
(BlockPos pStructureBlockPos, BlockPos pPosToTest, ServerLevel pServerLevel) findNearestTest
(BlockPos pPos, int pRadius, ServerLevel pLevel) findTestBlocks
(BlockPos pPos, int pRadius, ServerLevel pLevel) findTestContainingPos
(BlockPos pPos, int pRadius, ServerLevel pLevel) static Rotation
getRotationForRotationSteps
(int pRotationSteps) static int
getRotationStepsForRotation
(Rotation pRotation) static BoundingBox
getStructureBoundingBox
(BlockPos pPos, Vec3i pOffset, Rotation pRotation) static BlockPos
getTransformedFarCorner
(BlockPos pPos, Vec3i pOffset, Rotation pRotation) lookedAtTestPos
(BlockPos pPos, Entity pEntity, ServerLevel pLevel)
-
Field Details
-
DEFAULT_Y_SEARCH_RADIUS
public static final int DEFAULT_Y_SEARCH_RADIUS- See Also:
-
DEFAULT_TEST_STRUCTURES_DIR
- See Also:
-
testStructuresDir
-
-
Constructor Details
-
StructureUtils
public StructureUtils()
-
-
Method Details
-
getRotationForRotationSteps
-
getRotationStepsForRotation
-
createNewEmptyTest
public static TestInstanceBlockEntity createNewEmptyTest(ResourceLocation pId, BlockPos pPos, Vec3i pSize, Rotation pRotation, ServerLevel pLevel) -
clearSpaceForStructure
-
getTransformedFarCorner
-
getStructureBoundingBox
-
findTestContainingPos
public static Optional<BlockPos> findTestContainingPos(BlockPos pPos, int pRadius, ServerLevel pLevel) -
findNearestTest
-
findTestBlocks
-
lookedAtTestPos
-
clearBlock
-
doesStructureContain
private static boolean doesStructureContain(BlockPos pStructureBlockPos, BlockPos pPosToTest, ServerLevel pServerLevel)
-