Interface MenuRegistry.ScreenFactory<H extends net.minecraft.world.inventory.AbstractContainerMenu,S extends net.minecraft.client.gui.screens.Screen & net.minecraft.client.gui.screens.inventory.MenuAccess<H>>

Type Parameters:
H - The type of AbstractContainerMenu for the screen
S - The type for the Screen
Enclosing class:
MenuRegistry
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@Environment(CLIENT) @FunctionalInterface public static interface MenuRegistry.ScreenFactory<H extends net.minecraft.world.inventory.AbstractContainerMenu,S extends net.minecraft.client.gui.screens.Screen & net.minecraft.client.gui.screens.inventory.MenuAccess<H>>
Creates new screens.
  • Method Summary

    Modifier and Type
    Method
    Description
    create(H containerMenu, net.minecraft.world.entity.player.Inventory inventory, net.minecraft.network.chat.Component component)
    Creates a new MenuRegistry.ScreenFactory that extends Screen
  • Method Details

    • create

      S create(H containerMenu, net.minecraft.world.entity.player.Inventory inventory, net.minecraft.network.chat.Component component)
      Creates a new MenuRegistry.ScreenFactory that extends Screen
      Parameters:
      containerMenu - The AbstractContainerMenu that controls the game logic for the screen
      inventory - The Inventory for the screen
      component - The Component for the screen
      Returns:
      A new MenuRegistry.ScreenFactory that extends Screen