mirror of https://github.com/FabricMC/yarn.git
Game mode stuff (#1899)
* Game mode stuff * working javadocs are better * Update TutorialManager.mapping
This commit is contained in:
parent
9de49c608f
commit
768f78c0ac
|
@ -3,7 +3,8 @@ CLASS net/minecraft/class_1156 net/minecraft/client/tutorial/TutorialManager
|
|||
FIELD field_5646 currentHandler Lnet/minecraft/class_1155;
|
||||
METHOD <init> (Lnet/minecraft/class_310;)V
|
||||
ARG 1 client
|
||||
METHOD method_4905 getGameMode ()Z
|
||||
METHOD method_4905 isInSurvival ()Z
|
||||
COMMENT Returns whether the current game mode of the client is {@linkplain net.minecraft.world.GameMode#SURVIVAL survival}.
|
||||
METHOD method_4906 onSlotUpdate (Lnet/minecraft/class_1799;)V
|
||||
ARG 1 stack
|
||||
METHOD method_4907 onBlockAttacked (Lnet/minecraft/class_638;Lnet/minecraft/class_2338;Lnet/minecraft/class_2680;F)V
|
||||
|
|
|
@ -169,8 +169,8 @@ CLASS net/minecraft/server/MinecraftServer
|
|||
COMMENT relative path from the run directory
|
||||
METHOD method_3759 isUsingNativeTransport ()Z
|
||||
METHOD method_3760 getPlayerManager ()Lnet/minecraft/class_3324;
|
||||
METHOD method_3761 shouldForceGameMode ()Lnet/minecraft/class_1934;
|
||||
COMMENT Checks whether a player's current game mode should be set to the server's current game mode when a player has connected.
|
||||
METHOD method_3761 getForcedGameMode ()Lnet/minecraft/class_1934;
|
||||
COMMENT Returns the game mode a player should be set to when connecting to the server, or {@code null} if none is set.
|
||||
METHOD method_3763 openToLan (Lnet/minecraft/class_1934;ZI)Z
|
||||
COMMENT Opens a server for LAN connections.
|
||||
COMMENT This is only supported on an integrated server, a dedicated server will always fail to open to LAN.
|
||||
|
|
|
@ -141,4 +141,20 @@ CLASS net/minecraft/class_3222 net/minecraft/server/network/ServerPlayerEntity
|
|||
ARG 2 centerPos
|
||||
METHOD method_30631 getSpawnAngle ()F
|
||||
METHOD method_31273 getTextStream ()Lnet/minecraft/class_5513;
|
||||
METHOD method_7336 setGameMode (Lnet/minecraft/class_1934;)Z
|
||||
METHOD method_32745 gameModeFromTag (Lnet/minecraft/class_2487;Ljava/lang/String;)Lnet/minecraft/class_1934;
|
||||
ARG 0 tag
|
||||
ARG 1 key
|
||||
METHOD method_32746 getServerGameMode (Lnet/minecraft/class_1934;)Lnet/minecraft/class_1934;
|
||||
COMMENT Returns the server game mode the player should be set to, namely the forced game mode.
|
||||
COMMENT
|
||||
COMMENT <p>If the forced game mode is not set, returns the {@code backupGameMode} if not {@code null},
|
||||
COMMENT or the server's default game mode otherwise.
|
||||
COMMENT
|
||||
COMMENT @see MinecraftServer#getForcedGameMode
|
||||
ARG 1 backupGameMode
|
||||
METHOD method_32748 setGameMode (Lnet/minecraft/class_2487;)V
|
||||
ARG 1 tag
|
||||
METHOD method_32749 gameModeToTag (Lnet/minecraft/class_2487;)V
|
||||
ARG 1 tag
|
||||
METHOD method_7336 changeGameMode (Lnet/minecraft/class_1934;)Z
|
||||
ARG 1 gameMode
|
||||
|
|
|
@ -46,5 +46,9 @@ CLASS net/minecraft/class_3225 net/minecraft/server/network/ServerPlayerInteract
|
|||
ARG 1 pos
|
||||
ARG 2 action
|
||||
ARG 3 reason
|
||||
METHOD method_30118 setGameMode (Lnet/minecraft/class_1934;)Z
|
||||
METHOD method_30118 changeGameMode (Lnet/minecraft/class_1934;)Z
|
||||
COMMENT Checks if current game mode is different to {@code gameMode}, and change it if so.
|
||||
COMMENT
|
||||
COMMENT @return whether the current game mode has been changed
|
||||
ARG 1 gameMode
|
||||
METHOD method_30119 getPreviousGameMode ()Lnet/minecraft/class_1934;
|
||||
|
|
|
@ -1,9 +1,17 @@
|
|||
CLASS net/minecraft/class_1934 net/minecraft/world/GameMode
|
||||
FIELD field_28045 DEFAULT Lnet/minecraft/class_1934;
|
||||
FIELD field_28046 simpleTranslatableName Lnet/minecraft/class_2561;
|
||||
FIELD field_28047 translatableName Lnet/minecraft/class_2561;
|
||||
FIELD field_9217 id I
|
||||
FIELD field_9221 name Ljava/lang/String;
|
||||
METHOD <init> (Ljava/lang/String;IILjava/lang/String;)V
|
||||
ARG 3 id
|
||||
ARG 4 name
|
||||
METHOD method_32761 getId (Lnet/minecraft/class_1934;)I
|
||||
ARG 0 gameMode
|
||||
METHOD method_32762 getOrNull (I)Lnet/minecraft/class_1934;
|
||||
ARG 0 id
|
||||
METHOD method_32763 getSimpleTranslatableName ()Lnet/minecraft/class_2561;
|
||||
METHOD method_8378 byName (Ljava/lang/String;Lnet/minecraft/class_1934;)Lnet/minecraft/class_1934;
|
||||
ARG 0 name
|
||||
ARG 1 defaultMode
|
||||
|
|
Loading…
Reference in New Issue