public interface ICubicStructureGenerator
MapGenBase class.
The basic idea is to loop over all cubes within some radius (max structure size) and figure out which parts of structures starting there intersect currently generated cube.
| Modifier and Type | Interface and Description |
|---|---|
static interface |
ICubicStructureGenerator.Handler |
| Modifier and Type | Method and Description |
|---|---|
void |
generate(net.minecraft.world.World world,
CubePrimer cube,
CubePos cubePos) |
default void |
generate(net.minecraft.world.World world,
CubePrimer cube,
CubePos cubePos,
ICubicStructureGenerator.Handler handler,
int range,
int rangeY,
int spacingBitCount,
int spacingBitCountY)
Generates structures in given cube, with supplied parameters and handler
|
void generate(net.minecraft.world.World world,
CubePrimer cube,
CubePos cubePos)
default void generate(net.minecraft.world.World world,
CubePrimer cube,
CubePos cubePos,
ICubicStructureGenerator.Handler handler,
int range,
int rangeY,
int spacingBitCount,
int spacingBitCountY)
world - the world that the structure is generated incube - the block buffer to be filled with blocks (Cube)cubePos - position of the cube to generate structures inhandler - generation handler, to generate blocks for a given structure source point, in the specified cuberange - horizontal search distance for structure sources (in cubes)rangeY - vertical search distance for structure sources (in cubes)spacingBitCount - only structure sources on a grid of size 2^spacingBitCount will be considered for generationspacingBitCountY - only structure sources on a grid of size 2^spacingBitCount will be considered for generation (y coordinate)