Interface RegistrationHelper

All Known Implementing Classes:
RegistrationHelperImpl

public interface RegistrationHelper
A helper for registration in tests.
  • Method Details

    • registrar

      <T> DeferredRegister<T> registrar(ResourceKey<Registry<T>> registry)
      Returns a deferred register for the given registry.
      Returns:
      a deferred register for the given registry
    • blocks

      DeferredBlocks blocks()
      Returns a helper for block registration.
      Returns:
      a helper for block registration
    • items

      DeferredItems items()
      Returns a helper for item registration.
      Returns:
      a helper for item registration
    • entityTypes

      DeferredEntityTypes entityTypes()
      Returns a helper for entity type registration.
      Returns:
      a helper for entity type registration
    • attachments

      Returns a helper for attachment type registration.
      Returns:
      a helper for attachment type registration
    • modId

      String modId()
      Returns the mod id of this helper.
      Returns:
      the mod id of this helper
    • registerSubpack

      String registerSubpack(String name)
    • addProvider

      void addProvider(Function<GatherDataEvent,DataProvider> provider)
    • provider

      <T extends DataProvider> void provider(Class<T> type, Consumer<T> consumer)
    • eventListeners

      Consumer<Consumer<? extends net.neoforged.bus.api.Event>> eventListeners()
    • register

      void register(net.neoforged.bus.api.IEventBus bus)
    • create

      static RegistrationHelper create(String modId)