Package net.minecraft.client.gui.screen
Enum GamemodeSelectionScreen.Mode
- java.lang.Object
-
- java.lang.Enum<GamemodeSelectionScreen.Mode>
-
- net.minecraft.client.gui.screen.GamemodeSelectionScreen.Mode
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<GamemodeSelectionScreen.Mode>
- Enclosing class:
- GamemodeSelectionScreen
static enum GamemodeSelectionScreen.Mode extends java.lang.Enum<GamemodeSelectionScreen.Mode>
-
-
Field Summary
Fields Modifier and Type Field Description (package private) java.lang.String
command
(package private) ITextComponent
name
(package private) ItemStack
renderStack
protected static GamemodeSelectionScreen.Mode[]
VALUES
-
Constructor Summary
Constructors Modifier Constructor Description private
Mode(ITextComponent p_i232285_3_, java.lang.String p_i232285_4_, ItemStack p_i232285_5_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
drawIcon(ItemRenderer p_238729_1_, int p_238729_2_, int p_238729_3_)
private java.lang.String
getCommand()
private static java.util.Optional<GamemodeSelectionScreen.Mode>
getFromGameType(GameType p_238731_0_)
private ITextComponent
getName()
private java.util.Optional<GamemodeSelectionScreen.Mode>
getNext()
static GamemodeSelectionScreen.Mode
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static GamemodeSelectionScreen.Mode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
CREATIVE
public static final GamemodeSelectionScreen.Mode CREATIVE
-
SURVIVAL
public static final GamemodeSelectionScreen.Mode SURVIVAL
-
ADVENTURE
public static final GamemodeSelectionScreen.Mode ADVENTURE
-
SPECTATOR
public static final GamemodeSelectionScreen.Mode SPECTATOR
-
-
Field Detail
-
VALUES
protected static final GamemodeSelectionScreen.Mode[] VALUES
-
name
final ITextComponent name
-
command
final java.lang.String command
-
renderStack
final ItemStack renderStack
-
-
Constructor Detail
-
Mode
private Mode(ITextComponent p_i232285_3_, java.lang.String p_i232285_4_, ItemStack p_i232285_5_)
-
-
Method Detail
-
values
public static GamemodeSelectionScreen.Mode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (GamemodeSelectionScreen.Mode c : GamemodeSelectionScreen.Mode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static GamemodeSelectionScreen.Mode valueOf(java.lang.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:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
drawIcon
private void drawIcon(ItemRenderer p_238729_1_, int p_238729_2_, int p_238729_3_)
-
getName
private ITextComponent getName()
-
getCommand
private java.lang.String getCommand()
-
getNext
private java.util.Optional<GamemodeSelectionScreen.Mode> getNext()
-
getFromGameType
private static java.util.Optional<GamemodeSelectionScreen.Mode> getFromGameType(GameType p_238731_0_)
-
-