Class TitleCommand
java.lang.Object
net.minecraft.server.commands.TitleCommand
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final CommandResponseTracker.Messages<ServerPlayer> private static final CommandResponseTracker.Messages<ServerPlayer> private static final CommandResponseTracker.Messages<ServerPlayer> private static final CommandResponseTracker.Messages<ServerPlayer> private static final CommandResponseTracker.Messages<ServerPlayer> private static final CommandResponseTracker.Messages<ServerPlayer> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static intclearTitle(CommandSourceStack source, Collection<ServerPlayer> targets) static voidregister(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> dispatcher, CommandBuildContext context) private static intresetTitle(CommandSourceStack source, Collection<ServerPlayer> targets) private static intsendPacketToPlayers(CommandSourceStack source, Collection<ServerPlayer> targets, Packet<?> packet, CommandResponseTracker.Messages<ServerPlayer> messages) private static intsetTimes(CommandSourceStack source, Collection<ServerPlayer> targets, int fadeIn, int stay, int fadeOut) private static intshowTitle(CommandSourceStack source, Collection<ServerPlayer> targets, Component title, CommandResponseTracker.Messages<ServerPlayer> messages, Function<Component, Packet<?>> factory)
-
Field Details
-
RESPONSE_CLEAR_TITLE
-
RESPONSE_RESET_TITLE
-
RESPONSE_SHOW_TITLE
-
RESPONSE_SHOW_ACTIONBAR
-
RESPONSE_SHOW_SUBTITLE
-
RESPONSE_SET_TIMES
-
-
Constructor Details
-
TitleCommand
public TitleCommand()
-
-
Method Details
-
register
public static void register(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> dispatcher, CommandBuildContext context) -
sendPacketToPlayers
private static int sendPacketToPlayers(CommandSourceStack source, Collection<ServerPlayer> targets, Packet<?> packet, CommandResponseTracker.Messages<ServerPlayer> messages) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
clearTitle
private static int clearTitle(CommandSourceStack source, Collection<ServerPlayer> targets) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
resetTitle
private static int resetTitle(CommandSourceStack source, Collection<ServerPlayer> targets) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
showTitle
private static int showTitle(CommandSourceStack source, Collection<ServerPlayer> targets, Component title, CommandResponseTracker.Messages<ServerPlayer> messages, Function<Component, Packet<?>> factory) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
setTimes
private static int setTimes(CommandSourceStack source, Collection<ServerPlayer> targets, int fadeIn, int stay, int fadeOut) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-