Class GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu>

java.lang.Object
org.cyclops.cyclopscore.config.extendedconfig.ExtendedConfig<C,I>
org.cyclops.cyclopscore.config.extendedconfig.ExtendedConfigForge<GuiConfig<T>,net.minecraft.world.inventory.MenuType<T>>
org.cyclops.cyclopscore.config.extendedconfig.GuiConfig<T>
All Implemented Interfaces:
Comparable<ExtendedConfig<GuiConfig<T>,net.minecraft.world.inventory.MenuType<T>>>
Direct Known Subclasses:
ContainerInfoBookTestConfig

public abstract class GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu> extends ExtendedConfigForge<GuiConfig<T>,net.minecraft.world.inventory.MenuType<T>>
Config for client-side guis and server-side containers.
See Also:
  • Constructor Details

    • GuiConfig

      public GuiConfig(ModBase mod, String namedId, Function<GuiConfig<T>,? extends net.minecraft.world.inventory.MenuType<T>> elementConstructor)
      Create a new config
      Parameters:
      mod - The mod instance.
      namedId - A unique name id
      elementConstructor - The element constructor.
  • Method Details

    • getTranslationKey

      public String getTranslationKey()
      Description copied from class: ExtendedConfig
      Get the unlocalized name (must be unique!) for this configurable.
      Specified by:
      getTranslationKey in class ExtendedConfig<GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu>,net.minecraft.world.inventory.MenuType<T extends net.minecraft.world.inventory.AbstractContainerMenu>>
      Returns:
      The unlocalized name.
    • getFullTranslationKey

      public String getFullTranslationKey()
      Description copied from class: ExtendedConfig
      Get the full unlocalized name for this configurable.
      Overrides:
      getFullTranslationKey in class ExtendedConfig<GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu>,net.minecraft.world.inventory.MenuType<T extends net.minecraft.world.inventory.AbstractContainerMenu>>
      Returns:
      The unlocalized name.
    • getConfigurableType

      public ConfigurableType getConfigurableType()
      Description copied from class: ExtendedConfig
      Return the configurable type for which this config holds data
      Specified by:
      getConfigurableType in class ExtendedConfig<GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu>,net.minecraft.world.inventory.MenuType<T extends net.minecraft.world.inventory.AbstractContainerMenu>>
      Returns:
      the type of the configurable to where the config belongs
    • getRegistry

      public net.minecraftforge.registries.IForgeRegistry<? super net.minecraft.world.inventory.MenuType<T>> getRegistry()
      Specified by:
      getRegistry in class ExtendedConfigForge<GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu>,net.minecraft.world.inventory.MenuType<T extends net.minecraft.world.inventory.AbstractContainerMenu>>
      Returns:
      The registry in which this should be registered.
    • getScreenFactory

      public abstract <U extends net.minecraft.client.gui.screens.Screen & net.minecraft.client.gui.screens.inventory.MenuAccess<T>> net.minecraft.client.gui.screens.MenuScreens.ScreenConstructor<T,U> getScreenFactory()
    • onRegistered

      public void onRegistered()
      Description copied from class: ExtendedConfig
      Overridable method that is called after the element of this config is fully registered, after the FMLCommonSetupEvent.
      Overrides:
      onRegistered in class ExtendedConfig<GuiConfig<T extends net.minecraft.world.inventory.AbstractContainerMenu>,net.minecraft.world.inventory.MenuType<T extends net.minecraft.world.inventory.AbstractContainerMenu>>