Class Commands

java.lang.Object
net.minecraft.commands.Commands

public class Commands extends Object
  • Field Details

  • Constructor Details

  • Method Details

    • mapSource

      public static <S> com.mojang.brigadier.ParseResults<S> mapSource(com.mojang.brigadier.ParseResults<S> p_242928_, UnaryOperator<S> p_242890_)
    • performPrefixedCommand

      public int performPrefixedCommand(CommandSourceStack p_230958_, String p_230959_)
    • performCommand

      public int performCommand(com.mojang.brigadier.ParseResults<CommandSourceStack> p_242844_, String p_242841_)
    • sendCommands

      public void sendCommands(ServerPlayer p_82096_)
    • fillUsableCommands

      private void fillUsableCommands(com.mojang.brigadier.tree.CommandNode<CommandSourceStack> p_82113_, com.mojang.brigadier.tree.CommandNode<SharedSuggestionProvider> p_82114_, CommandSourceStack p_82115_, Map<com.mojang.brigadier.tree.CommandNode<CommandSourceStack>,com.mojang.brigadier.tree.CommandNode<SharedSuggestionProvider>> p_82116_)
    • literal

      public static com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> literal(String p_82128_)
    • argument

      public static <T> com.mojang.brigadier.builder.RequiredArgumentBuilder<CommandSourceStack,T> argument(String p_82130_, com.mojang.brigadier.arguments.ArgumentType<T> p_82131_)
    • createValidator

      public static Predicate<String> createValidator(Commands.ParseFunction p_82121_)
    • getDispatcher

      public com.mojang.brigadier.CommandDispatcher<CommandSourceStack> getDispatcher()
    • getParseException

      @Nullable public static <S> com.mojang.brigadier.exceptions.CommandSyntaxException getParseException(com.mojang.brigadier.ParseResults<S> p_82098_)
    • validate

      public static void validate()