Interface BotanyPotsPlugin

All Known Implementing Classes:
BaseBotanyPotsPlugin

public interface BotanyPotsPlugin
Botany pots plugins can be used to hook into various botany pot systems and improve integration with the mod.

Plugins are registered using a service loader. This makes them viable on several mod loaders using a single entry point. In order to define your plugin define the fully qualified class name in the META-INF/services/net.darkhax.botanypots.common.api.BotanyPotsPlugin. Please refer to the built-in plugin which is also defined using this system if you need more info.

  • Field Details

    • PLUGINS

      static final net.darkhax.bookshelf.common.api.function.CachedSupplier<List<BotanyPotsPlugin>> PLUGINS
      Provides a list of registered botany pot plugins. Resolving the plugin list will cause all plugins to be initialized.
  • Method Details

    • registerSoilGenerators

      default void registerSoilGenerators(BiConsumer<net.minecraft.resources.ResourceLocation,SoilGenerator> register)
      Registers soil generators with Botany Pots. These are data generators that are accessed using the in-game command. These do NOT automatically create and register soils with the mod. Use datapack files for that.
      Parameters:
      register - A consumer that will register any accepted soil generator.
    • registerCropGenerators

      default void registerCropGenerators(BiConsumer<net.minecraft.resources.ResourceLocation,CropGenerator> register)
      Registers crop generators with Botany Pots. These are data generators that are accessed using the in-game command. These do NOT automatically create and register soils with the mod. Use datapack files for that.
      Parameters:
      register - A consumer that will register any accepted crop generator.
    • registerDisplayTypes

      default void registerDisplayTypes()
      Register new display types with Botany Pots. These are registered using DisplayType.register(ResourceLocation, MapCodec, StreamCodec).
    • registerDropProviders

      default void registerDropProviders()
      Register new item drop provider types. These are registered using ItemDropProviderType.register(ResourceLocation, MapCodec, StreamCodec).
    • registerGrowthAmountTypes

      default void registerGrowthAmountTypes()
      Registers new growth amount calculation types. These are registered using GrowthAmountType.register(ResourceLocation, MapCodec, StreamCodec).
    • bindDisplayRenderers

      default void bindDisplayRenderers()
      Binds a renderer to a display type. This method is only invoked on the client, and it is safe to use client side only code within this method. These are bound using DisplayRenderer.bind(DisplayType, DisplayRenderer).