Class RandomCommand

java.lang.Object
net.minecraft.server.commands.RandomCommand

public class RandomCommand extends Object
  • Field Details

    • ERROR_RANGE_TOO_LARGE

      private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_RANGE_TOO_LARGE
    • ERROR_RANGE_TOO_SMALL

      private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_RANGE_TOO_SMALL
  • Constructor Details

    • RandomCommand

      public RandomCommand()
  • Method Details

    • register

      public static void register(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> dispatcher)
    • drawRandomValueTree

      private static com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> drawRandomValueTree(String subcommand, boolean displayResult)
    • suggestRandomSequence

      private static CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> suggestRandomSequence(com.mojang.brigadier.context.CommandContext<CommandSourceStack> context, com.mojang.brigadier.suggestion.SuggestionsBuilder suggestionsBuilder)
    • randomSample

      private static int randomSample(CommandSourceStack source, MinMaxBounds.Ints range, @Nullable ResourceLocation sequence, boolean displayResult) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • resetSequence

      private static int resetSequence(CommandSourceStack source, ResourceLocation sequence) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • resetSequence

      private static int resetSequence(CommandSourceStack source, ResourceLocation sequence, int seed, boolean includeWorldSeed, boolean includeSequenceId) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • resetAllSequences

      private static int resetAllSequences(CommandSourceStack source)
    • resetAllSequencesAndSetNewDefaults

      private static int resetAllSequencesAndSetNewDefaults(CommandSourceStack source, int seed, boolean includeWorldSeed, boolean includeSequenceId)