Class ChestMenu


public class ChestMenu extends AbstractContainerMenu
  • Field Details

    • container

      private final Container container
    • containerRows

      private final int containerRows
  • Constructor Details

    • ChestMenu

      private ChestMenu(MenuType<?> type, int containerId, Inventory playerInventory, int rows)
    • ChestMenu

      public ChestMenu(MenuType<?> type, int containerId, Inventory playerInventory, Container container, int rows)
  • Method Details

    • oneRow

      public static ChestMenu oneRow(int containerId, Inventory playerInventory)
    • twoRows

      public static ChestMenu twoRows(int containerId, Inventory playerInventory)
    • threeRows

      public static ChestMenu threeRows(int containerId, Inventory playerInventory)
    • fourRows

      public static ChestMenu fourRows(int containerId, Inventory playerInventory)
    • fiveRows

      public static ChestMenu fiveRows(int containerId, Inventory playerInventory)
    • sixRows

      public static ChestMenu sixRows(int containerId, Inventory playerInventory)
    • threeRows

      public static ChestMenu threeRows(int containerId, Inventory playerInventory, Container container)
    • sixRows

      public static ChestMenu sixRows(int containerId, Inventory playerInventory, Container container)
    • addChestGrid

      private void addChestGrid(Container container, int x, int y)
    • stillValid

      public boolean stillValid(Player player)
      Determines whether supplied player can use this container
      Specified by:
      stillValid in class AbstractContainerMenu
    • quickMoveStack

      public ItemStack quickMoveStack(Player player, int index)
      Handle when the stack in slot index is shift-clicked. Normally this moves the stack between the player inventory and the other inventory(s).
      Specified by:
      quickMoveStack in class AbstractContainerMenu
    • removed

      public void removed(Player player)
      Called when the container is closed.
      Overrides:
      removed in class AbstractContainerMenu
    • getContainer

      public Container getContainer()
    • getRowCount

      public int getRowCount()