Package net.minecraft.world
Enum Class GameMode
- All Implemented Interfaces:
Serializable,Comparable<GameMode>,Constable
- Mappings:
Namespace Name official arcintermediary net/minecraft/class_1157named net/minecraft/world/GameMode
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidgameModeAbilities(PlayerAbilities abilities) intbooleanbooleanstatic GameModesetGameModeWithId(int gamemode) static GameModesetGameModeWithString(String gamemode) static GameModeReturns the enum constant of this class with the specified name.static GameMode[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
NOT_SET
- Mappings:
Namespace Name Mixin selector official aLarc;a:Larc;intermediary field_4572Lnet/minecraft/class_1157;field_4572:Lnet/minecraft/class_1157;named NOT_SETLnet/minecraft/world/GameMode;NOT_SET:Lnet/minecraft/world/GameMode;
-
SURVIVAL
- Mappings:
Namespace Name Mixin selector official bLarc;b:Larc;intermediary field_4573Lnet/minecraft/class_1157;field_4573:Lnet/minecraft/class_1157;named SURVIVALLnet/minecraft/world/GameMode;SURVIVAL:Lnet/minecraft/world/GameMode;
-
CREATIVE
- Mappings:
Namespace Name Mixin selector official cLarc;c:Larc;intermediary field_4574Lnet/minecraft/class_1157;field_4574:Lnet/minecraft/class_1157;named CREATIVELnet/minecraft/world/GameMode;CREATIVE:Lnet/minecraft/world/GameMode;
-
ADVENTURE
- Mappings:
Namespace Name Mixin selector official dLarc;d:Larc;intermediary field_4575Lnet/minecraft/class_1157;field_4575:Lnet/minecraft/class_1157;named ADVENTURELnet/minecraft/world/GameMode;ADVENTURE:Lnet/minecraft/world/GameMode;
-
SPECTATOR
- Mappings:
Namespace Name Mixin selector official eLarc;e:Larc;intermediary field_9216Lnet/minecraft/class_1157;field_9216:Lnet/minecraft/class_1157;named SPECTATORLnet/minecraft/world/GameMode;SPECTATOR:Lnet/minecraft/world/GameMode;
-
-
Field Details
-
gameModeId
int gameModeId- Mappings:
Namespace Name Mixin selector official fLarc;f:Iintermediary field_4576Lnet/minecraft/class_1157;field_4576:Inamed gameModeIdLnet/minecraft/world/GameMode;gameModeId:I
-
gameModeName
String gameModeName- Mappings:
Namespace Name Mixin selector official gLarc;g:Ljava/lang/String;intermediary field_4577Lnet/minecraft/class_1157;field_4577:Ljava/lang/String;named gameModeNameLnet/minecraft/world/GameMode;gameModeName:Ljava/lang/String;
-
-
Constructor Details
-
GameMode
- Mappings:
Namespace Name Mixin selector official <init>Larc;<init>(Ljava/lang/String;IILjava/lang/String;)Vintermediary <init>Lnet/minecraft/class_1157;<init>(Ljava/lang/String;IILjava/lang/String;)Vnamed <init>Lnet/minecraft/world/GameMode;<init>(Ljava/lang/String;IILjava/lang/String;)V
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
getGameModeId
public int getGameModeId()- Mappings:
Namespace Name Mixin selector official aLarc;a()Iintermediary method_3763Lnet/minecraft/class_1157;method_3763()Inamed getGameModeIdLnet/minecraft/world/GameMode;getGameModeId()I
-
getGameModeName
- Mappings:
Namespace Name Mixin selector official bLarc;b()Ljava/lang/String;intermediary method_3767Lnet/minecraft/class_1157;method_3767()Ljava/lang/String;named getGameModeNameLnet/minecraft/world/GameMode;getGameModeName()Ljava/lang/String;
-
gameModeAbilities
- Mappings:
Namespace Name Mixin selector official aLarc;a(Laha;)Vintermediary method_3766Lnet/minecraft/class_1157;method_3766(Lnet/minecraft/class_986;)Vnamed gameModeAbilitiesLnet/minecraft/world/GameMode;gameModeAbilities(Lnet/minecraft/entity/player/PlayerAbilities;)V
-
isAdventure
public boolean isAdventure()- Mappings:
Namespace Name Mixin selector official cLarc;c()Zintermediary method_3768Lnet/minecraft/class_1157;method_3768()Znamed isAdventureLnet/minecraft/world/GameMode;isAdventure()Z
-
isCreative
public boolean isCreative()- Mappings:
Namespace Name Mixin selector official dLarc;d()Zintermediary method_3769Lnet/minecraft/class_1157;method_3769()Znamed isCreativeLnet/minecraft/world/GameMode;isCreative()Z
-
canBeDamaged
public boolean canBeDamaged()- Mappings:
Namespace Name Mixin selector official eLarc;e()Zintermediary method_3770Lnet/minecraft/class_1157;method_3770()Znamed canBeDamagedLnet/minecraft/world/GameMode;canBeDamaged()Z
-
setGameModeWithId
- Mappings:
Namespace Name Mixin selector official aLarc;a(I)Larc;intermediary method_3764Lnet/minecraft/class_1157;method_3764(I)Lnet/minecraft/class_1157;named setGameModeWithIdLnet/minecraft/world/GameMode;setGameModeWithId(I)Lnet/minecraft/world/GameMode;
-
setGameModeWithString
- Mappings:
Namespace Name Mixin selector official aLarc;a(Ljava/lang/String;)Larc;intermediary method_3765Lnet/minecraft/class_1157;method_3765(Ljava/lang/String;)Lnet/minecraft/class_1157;named setGameModeWithStringLnet/minecraft/world/GameMode;setGameModeWithString(Ljava/lang/String;)Lnet/minecraft/world/GameMode;
-