Interface GenerationUnit
public interface GenerationUnit
Represents an area that can be generated.
The size is guaranteed to be a multiple of 16 (section).
-
Method Summary
Modifier and TypeMethodDescription@NotNull Point
The absolute end (max x, y, z) of this unit.@NotNull Point
The absolute start (min x, y, z) of this unit.void
fork
(@NotNull Consumer<@NotNull Block.Setter> consumer) Creates a fork of this unit depending on the blocks placed within the consumer.@NotNull GenerationUnit
Creates a fork of this unit, which will be applied to the instance whenever possible.@NotNull UnitModifier
modifier()
This unit's modifier, used to place blocks and biomes within this unit.@NotNull Point
size()
The size of this unit in blocks.default @NotNull List
<GenerationUnit> Divides this unit into the smallest independent units.
-
Method Details
-
modifier
This unit's modifier, used to place blocks and biomes within this unit.- Returns:
- the modifier
-
size
The size of this unit in blocks.Guaranteed to be a multiple of 16.
- Returns:
- the size of this unit
-
absoluteStart
The absolute start (min x, y, z) of this unit.- Returns:
- the absolute start
-
absoluteEnd
The absolute end (max x, y, z) of this unit.- Returns:
- the absolute end
-
fork
Creates a fork of this unit, which will be applied to the instance whenever possible.- Parameters:
start
- the start of the forkend
- the end of the fork- Returns:
- the fork
-
fork
Creates a fork of this unit depending on the blocks placed within the consumer.- Parameters:
consumer
- the consumer
-
subdivide
Divides this unit into the smallest independent units.- Returns:
- an immutable list of independent units
-