Class GameRegistry


  • public class GameRegistry
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      GameRegistry()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <K extends IForgeRegistryEntry<K>>
      IForgeRegistry<K>
      findRegistry​(java.lang.Class<K> registryType)
      Retrieves the registry associated with this super class type.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • GameRegistry

        public GameRegistry()
    • Method Detail

      • findRegistry

        public static <K extends IForgeRegistryEntry<K>> IForgeRegistry<K> findRegistry​(java.lang.Class<K> registryType)
        Retrieves the registry associated with this super class type. If the return is non-null it is HIGHLY recommended that modders cache this value as the return will never change for a given type in a single run of Minecraft once set.
        Parameters:
        registryType - The base class of items in this registry.
        Returns:
        The registry, Null if none is registered.