Class WeightedRandomFeatureConfiguration.Builder
java.lang.Object
dev.wyck.worldgen.feature.configurations.WeightedRandomFeatureConfiguration.Builder
- Enclosing interface:
WeightedRandomFeatureConfiguration
Builder for
WeightedRandomFeatureConfiguration.- Since:
- 3.0.1
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the weighted random feature configuration.feature(PlacedFeature feature) Adds a feature with a weight of 1.feature(PlacedFeature feature, int weight) Adds a feature with the given weight.
-
Constructor Details
-
Builder
public Builder() -
Builder
-
-
Method Details
-
feature
Adds a feature with a weight of 1.- Parameters:
feature- the feature to add- Returns:
- this builder
- Since:
- 3.0.1
-
feature
@AsOf("3.0.1") public WeightedRandomFeatureConfiguration.Builder feature(PlacedFeature feature, int weight) Adds a feature with the given weight.- Parameters:
feature- the feature to addweight- the weight of the feature- Returns:
- this builder
- Since:
- 3.0.1
-
build
Builds the weighted random feature configuration.- Returns:
- the weighted random feature configuration
- Since:
- 3.0.1
-