接口 RegisterEvent.RegisterHelper<T>

封闭类:
RegisterEvent
函数接口:
这是一个函数接口, 因此可用作 lambda 表达式或方法引用的赋值目标。

@FunctionalInterface public static interface RegisterEvent.RegisterHelper<T>
  • 方法概要

    修饰符和类型
    方法
    说明
    default void
    register(ResourceKey<T> key, T value)
    Registers the given value with the given name to the registry.
    void
    register(ResourceLocation name, T value)
    Registers the given value with the given name to the registry.
  • 方法详细资料

    • register

      default void register(ResourceKey<T> key, T value)
      Registers the given value with the given name to the registry.
      参数:
      key - the resource key of the object to register
      value - the object value
    • register

      void register(ResourceLocation name, T value)
      Registers the given value with the given name to the registry.
      参数:
      name - the name of the object to register as its key
      value - the object value