Enum GameModeSelection

java.lang.Object
java.lang.Enum<GameModeSelection>
net.minecraft.client.gui.screen.world.GameModeSelection
All Implemented Interfaces:
Serializable, Comparable<GameModeSelection>, java.lang.constant.Constable

@Environment(CLIENT)
public enum GameModeSelection
extends Enum<GameModeSelection>
  • Enum Constant Details

  • Field Details

    • gameMode

      private final GameMode gameMode
      The game mode being chosen.
    • name

      private final Text name
      The name of the game mode.
  • Constructor Details

    • GameModeSelection

      private GameModeSelection​(GameMode gameMode)
  • Method Details

    • values

      public static GameModeSelection[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static GameModeSelection valueOf​(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null
    • getGameMode

      public GameMode getGameMode()
      Gets the game mode with the given name (i.e. enum field).
    • getName

      public Text getName()
      Gets the name of the given game mode.