Interface ConfiguredFeature

All Superinterfaces:
Keyed, Wrapper
All Known Subinterfaces:
AbstractCustomFeature
All Known Implementing Classes:
ConfiguredFeature.CustomConfigured, ConfiguredFeature.Reference, ConfiguredFeature.VanillaConfigured, CustomFeature

Wraps Minecraft's ConfiguredFeature.

Since:
2.3.0
  • Field Details

  • Method Details

    • reference

      @AsOf("2.3.0") static ConfiguredFeature reference(ResourceKey key)
      References a configured feature already registered under the given key.
      Parameters:
      key - the registry key of the configured feature
      Returns:
      a reference to the registered configured feature
      Since:
      2.3.0
    • vanilla

      @AsOf("2.3.0") static ConfiguredFeature.VanillaConfigured vanilla(FeatureType featureType, FeatureConfiguration configuration)
      Authors a configured feature from a vanilla feature type and configuration.
      Parameters:
      featureType - the vanilla feature algorithm
      configuration - the vanilla configuration for it
      Returns:
      an authored configured feature
      Since:
      2.3.0
    • custom

      @AsOf("2.3.0") static ConfiguredFeature.CustomConfigured custom(ResourceKey featureKey, Object config)
      Composes a registered custom feature with a config instance. The feature must already be registered under featureKey via CustomFeature.register(...). The same feature may be composed with different configs.
      Parameters:
      featureKey - the key the custom feature was registered under
      config - the config instance to place with
      Returns:
      an authored configured feature
      Since:
      2.3.0
    • toMinecraft

      @AsOf("2.3.0") default Object toMinecraft()
      Description copied from interface: Wrapper
      Convert this handle to the real Minecraft object.
      Specified by:
      toMinecraft in interface Wrapper
      Returns:
      the real Minecraft object