Interface RegistryHandler<T>

All Superinterfaces:
Consumer<RegistryService>
All Known Implementing Classes:
QuiltRegistryHandler

public interface RegistryHandler<T> extends Consumer<RegistryService>
  • Method Details

    • create

      static <T> RegistryHandler<T> create(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<T>> registryKey, String namespace)
    • register

      <S extends T> RegistrySupplier<S> register(String name, Supplier<S> factory)
    • values

      Map<net.minecraft.resources.ResourceLocation,RegistrySupplier<? extends T>> values()
    • getEntriesOrdered

      List<RegistrySupplier<? extends T>> getEntriesOrdered()
    • stream

      Stream<RegistrySupplier<? extends T>> stream()
    • registry

      net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<T>> registry()
    • createNewRegistry

      net.minecraft.core.Registry<T> createNewRegistry(boolean sync, @Nullable @Nullable net.minecraft.resources.ResourceLocation defaultEntry)
      Parameters:
      sync - Whether the registry int IDs should be synchronized to each client
      defaultEntry - The default entry for the registry. if null this method will return a MappedRegistry, otherwise a DefaultedRegistry
    • createNewRegistry

      default net.minecraft.core.Registry<T> createNewRegistry(boolean sync)
    • createNewRegistry

      default net.minecraft.core.Registry<T> createNewRegistry()
    • accept

      default void accept(RegistryService registryService)
      Specified by:
      accept in interface Consumer<T>