Class StructureUtil
java.lang.Object
net.rodofire.easierworldcreator.structure.StructureUtil
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvertNbtToBlockList(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName) This method is used to get every block in a structure.static voidplace(net.minecraft.world.StructureWorldAccess world, List<BlockList> blockLists, net.minecraft.util.math.BlockPos block, boolean force, Set<net.minecraft.block.Block> blockToForce, List<net.minecraft.block.Block> blockToSkip, float integrity) static voidplace(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName, float integrity, net.minecraft.util.math.BlockPos pos, net.minecraft.util.math.BlockPos offset, net.minecraft.util.BlockMirror mirror, net.minecraft.util.BlockRotation rotation, boolean ignoreEntities) this method allows you to place a structure in the world during world gen or notstatic voidplace(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName, float integrity, net.minecraft.util.math.ChunkPos chunk) static voidplace(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName, float integrity, net.minecraft.world.chunk.Chunk chunk)
-
Constructor Details
-
StructureUtil
public StructureUtil()
-
-
Method Details
-
convertNbtToBlockList
public static List<BlockList> convertNbtToBlockList(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName) This method is used to get every block in a structure.- Parameters:
world- the world the structure is being usedtemplateName- the identifier of the structure- Returns:
- the List of blockList that compose the structure
-
place
-
place
public static void place(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName, float integrity, net.minecraft.world.chunk.Chunk chunk) -
place
public static void place(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName, float integrity, net.minecraft.util.math.ChunkPos chunk) -
place
public static void place(net.minecraft.world.StructureWorldAccess world, net.minecraft.util.Identifier templateName, float integrity, net.minecraft.util.math.BlockPos pos, net.minecraft.util.math.BlockPos offset, net.minecraft.util.BlockMirror mirror, net.minecraft.util.BlockRotation rotation, boolean ignoreEntities) this method allows you to place a structure in the world during world gen or not- Parameters:
world- the world the structure will spawn intemplateName- the identifier of the structureintegrity- the integrity of the structure must be between 0f and 1fpos- the pos of the structureoffset- the offset of the pos structuremirror- the block mirror if wantedrotation- the structure rotation if wantedignoreEntities- ignore entities of the structure
-