Class ConfigurableTypeAction<C extends ExtendedConfig<C,I>,I>

java.lang.Object
org.cyclops.cyclopscore.config.configurabletypeaction.ConfigurableTypeAction<C,I>
Type Parameters:
C - The subclass of ExtendedConfig.
I - The instance corresponding to this config.
Direct Known Subclasses:
CapabilityAction, ConfigurableTypeActionForge, DummyAction, FluidAction

public abstract class ConfigurableTypeAction<C extends ExtendedConfig<C,I>,I> extends Object
An action that is used to register Configurables. Used inside of ConfigHandler.
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    onRegisterForge(C eConfig)
    Logic to register things right after the Forge registries have been created.
    void
    Logic to register things before Forge registries are being filled.
    void
    Logic to register the eConfig target when the config is being loaded during mod construction.
    void
    onRegisterSetup(C eConfig)
    Logic to register the eConfig target when the config is being loaded during the FMLCommonSetupEvent.
    static <C extends ExtendedConfigForge<C, I>, I>
    void
    register(C config)
    Register the forge registry entry inside the given config.
    static <C extends ExtendedConfigForge<C, I>, I>
    void
    register(C config, Callable<?> callback)
    Register the forge registry entry inside the given config.
    static <C extends ExtendedConfigForge<C, I>, I>
    void
    register(net.minecraft.core.Registry<? super I> registry, C config)
    Register the forge registry entry inside the given config.
    static <C extends ExtendedConfigForge<C, I>, I>
    void
    register(net.minecraft.core.Registry<? super I> registry, C config, Callable<?> callback)
    Register the forge registry entry inside the given config.

    Methods inherited from class java.lang.Object

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

    • ConfigurableTypeAction

      public ConfigurableTypeAction()
  • Method Details

    • onRegisterModInit

      public void onRegisterModInit(C eConfig)
      Logic to register the eConfig target when the config is being loaded during mod construction.
      Parameters:
      eConfig - The config to be registered.
    • onRegisterForge

      public void onRegisterForge(C eConfig)
      Logic to register things right after the Forge registries have been created.
      Parameters:
      eConfig - The config to be registered.
    • onRegisterForgeFilled

      public void onRegisterForgeFilled(C eConfig)
      Logic to register things before Forge registries are being filled.
      Parameters:
      eConfig - The config to be registered.
    • onRegisterSetup

      public void onRegisterSetup(C eConfig)
      Logic to register the eConfig target when the config is being loaded during the FMLCommonSetupEvent.
      Parameters:
      eConfig - The config to be registered.
    • register

      public static <C extends ExtendedConfigForge<C, I>, I> void register(C config)
      Register the forge registry entry inside the given config.
      Type Parameters:
      C - The subclass of ExtendedConfig.
      I - The instance corresponding to this config.
      Parameters:
      config - The corresponding config.
    • register

      public static <C extends ExtendedConfigForge<C, I>, I> void register(C config, @Nullable Callable<?> callback)
      Register the forge registry entry inside the given config.
      Type Parameters:
      C - The subclass of ExtendedConfig.
      I - The instance corresponding to this config.
      Parameters:
      config - The corresponding config.
      callback - A callback that will be called when the entry is registered.
    • register

      public static <C extends ExtendedConfigForge<C, I>, I> void register(net.minecraft.core.Registry<? super I> registry, C config)
      Register the forge registry entry inside the given config.
      Type Parameters:
      C - The subclass of ExtendedConfig.
      I - The instance corresponding to this config.
      Parameters:
      registry - The registry.
      config - The corresponding config.
    • register

      public static <C extends ExtendedConfigForge<C, I>, I> void register(net.minecraft.core.Registry<? super I> registry, C config, @Nullable Callable<?> callback)
      Register the forge registry entry inside the given config.
      Type Parameters:
      C - The subclass of ExtendedConfig.
      I - The instance corresponding to this config.
      Parameters:
      registry - The registry.
      config - The config.
      callback - A callback that will be called when the entry is registered.