Class CylinderGen
java.lang.Object
net.rodofire.easierworldcreator.shapeutil.Shape
net.rodofire.easierworldcreator.shapeutil.FillableShape
net.rodofire.easierworldcreator.shapegen.CylinderGen
Class to generate Sphere related shapes
the methods in this class basically stack multiple circles to generate a cylinder
- Since 2.1.0, the shape doesn't return a List<net.minecraft.util.math.BlockPos> but it returns instead a List<Set<BlockPos>>
- Before 2.1.0, the BlockPos list was a simple list.
- Starting from 2.1.0, the shapes returns a list of ChunkPos that has a set of BlockPos
The change from List to Set was done to avoid duplicates BlockPos wich resulted in unnecessary calculations.
this allow easy multithreading for the Block assignment done in the Shape which result in better performance;
-
Nested Class Summary
Nested classes/interfaces inherited from class net.rodofire.easierworldcreator.shapeutil.FillableShape
FillableShape.TypeNested classes/interfaces inherited from class net.rodofire.easierworldcreator.shapeutil.Shape
Shape.LayerPlace, Shape.LayersType, Shape.PlaceMoment, Shape.PlaceType -
Field Summary
Fields inherited from class net.rodofire.easierworldcreator.shapeutil.Shape
biggerThanChunk -
Constructor Summary
ConstructorsConstructorDescriptionCylinderGen(@NotNull net.minecraft.world.StructureWorldAccess world, @NotNull net.minecraft.util.math.BlockPos pos, int radius, int height, Shape.PlaceMoment placeMoment) Deprecated, for removal: This API element is subject to removal in a future version.CylinderGen(@NotNull net.minecraft.world.StructureWorldAccess world, @NotNull net.minecraft.util.math.BlockPos pos, Shape.PlaceMoment placeMoment, int radius, int height) -
Method Summary
Modifier and TypeMethodDescriptionvoidgenerateEmptyCylinder(Map<net.minecraft.util.math.ChunkPos, Set<net.minecraft.util.math.BlockPos>> chunkMap) this generates a full cylindervoidgenerateFullCylinder(Map<net.minecraft.util.math.ChunkPos, Set<net.minecraft.util.math.BlockPos>> chunkMap) this generates a full cylindermethod to get the coordinates that will be placed laterintintintList<net.minecraft.util.math.Vec3d> getVec3d()method to get the Vec3d that will be placed latervoidsetHeight(int height) voidsetRadiusX(int radius) voidsetRadiusZ(int radius) Methods inherited from class net.rodofire.easierworldcreator.shapeutil.FillableShape
getCustomFill, getFillingType, setCustomFill, setFill, setFillingTypeMethods inherited from class net.rodofire.easierworldcreator.shapeutil.Shape
addBlockLayer, addBlockLayers, addBlocksToForce, addBlocksToForce, addPosOffset, addSecondxrotation, addXrotation, addYrotation, getBlockLayer, getBlockLayers, getBlocksToForce, getBlockToPlace, getBlockToPlace, getChunkCovered, getCoordinatesRotation, getCoordinatesRotation, getCoordinatesRotationList, getFirstSurfaceBlockLayers, getForce, getInnerCylindricalBlocks, getInnerRadialBlocks, getLayerPlace, getLayers, getLayersType, getNoise, getOuterCylindricalBlocks, getOuterRadialBlocks, getPlaceMoment, getPlaceType, getPos, getRotations, getSecondXrotation, getWorld, getXrotation, getYrotation, place, place, placeBlocks, placeBlocks, placeBlocksWithVerification, placeBlocksWithVerification, placeFirstSurfaceBlockLayers, placeInnerCylindricalBlocks, placeInnerRadialBlocks, placeLayers, placeOuterCylindricalBlocks, placeOuterRadialBlocks, placeSurfaceBlockLayers, removeBlockLayer, removeBlockLayer, removeBlockLayer, setBlockLayers, setBlockLayers, setBlocksToForce, setForce, setLayerDirection, setLayerPlace, setLayersType, setNoise, setPlaceMoment, setPlaceType, setPos, setSecondxrotation, setXrotation, setYrotation, verifyBlocks
-
Constructor Details
-
CylinderGen
public CylinderGen(@NotNull @NotNull net.minecraft.world.StructureWorldAccess world, @NotNull @NotNull net.minecraft.util.math.BlockPos pos, Shape.PlaceMoment placeMoment, int radius, int height) -
CylinderGen
@Deprecated(forRemoval=true) public CylinderGen(@NotNull @NotNull net.minecraft.world.StructureWorldAccess world, @NotNull @NotNull net.minecraft.util.math.BlockPos pos, int radius, int height, Shape.PlaceMoment placeMoment) Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
setHeight
public void setHeight(int height) -
getHeight
public int getHeight() -
setRadiusX
public void setRadiusX(int radius) -
getRadiusX
public int getRadiusX() -
setRadiusZ
public void setRadiusZ(int radius) -
getRadiusZ
public int getRadiusZ() -
getBlockPos
Description copied from class:Shapemethod to get the coordinates that will be placed later- Specified by:
getBlockPosin classShape- Returns:
- a list of blockPos for every shape
-
generateCylinder
-
generateFullCylinder
public void generateFullCylinder(Map<net.minecraft.util.math.ChunkPos, Set<net.minecraft.util.math.BlockPos>> chunkMap) this generates a full cylinder -
generateEmptyCylinder
public void generateEmptyCylinder(Map<net.minecraft.util.math.ChunkPos, Set<net.minecraft.util.math.BlockPos>> chunkMap) this generates a full cylinder -
getVec3d
Description copied from class:Shapemethod to get the Vec3d that will be placed later
-