public static interface Mushroom.Builder extends ResettableBuilder<Mushroom,Mushroom.Builder>
Mushroom
populators.Modifier and Type | Method and Description |
---|---|
Mushroom |
build()
Builds a new instance of a
Mushroom populator with the
settings set within the builder. |
default Mushroom.Builder |
mushroomsPerChunk(int count)
Sets the number of mushrooms which will be attempted to be spawned.
|
Mushroom.Builder |
mushroomsPerChunk(VariableAmount count)
Sets the number of mushrooms which will be attempted to be spawned.
|
Mushroom.Builder |
supplier(Function<Location<Extent>,MushroomType> override)
Sets the overriding supplier.
|
Mushroom.Builder |
type(MushroomType type,
double weight)
Adds the weighted
MushroomType to the list of available
types. |
Mushroom.Builder |
types(ChanceTable<MushroomType> types)
Sets the weighted
MushroomType s to select from during
generation. |
from, reset
Mushroom.Builder types(ChanceTable<MushroomType> types)
MushroomType
s to select from during
generation.types
- The weighted typesMushroom.Builder type(MushroomType type, double weight)
MushroomType
to the list of available
types.type
- The new weighted typeweight
- The weight of the new typeMushroom.Builder mushroomsPerChunk(VariableAmount count)
Note: This number is not a definite number and the final count of mushrooms which are successfully spawned by the populator will almost always be lower.
count
- The new amount to attempt to createdefault Mushroom.Builder mushroomsPerChunk(int count)
Note: This number is not a definite number and the final count of mushrooms which are successfully spawned by the populator will almost always be lower.
count
- The new amount to attempt to createMushroom.Builder supplier(@Nullable Function<Location<Extent>,MushroomType> override)
override
- The new supplier override, or nullMushroom build() throws IllegalStateException
Mushroom
populator with the
settings set within the builder.IllegalStateException
- If there are any settings left unset
which do not have default values