Package net.minecraft.server.commands
Class RandomCommand
java.lang.Object
net.minecraft.server.commands.RandomCommand
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static com.mojang.brigadier.builder.LiteralArgumentBuilder
<CommandSourceStack> drawRandomValueTree
(String p_295419_, boolean p_295785_) private static int
randomSample
(CommandSourceStack pSource, MinMaxBounds.Ints pRange, ResourceLocation pSequence, boolean pDisplayResult) static void
register
(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> p_295018_) private static int
resetAllSequences
(CommandSourceStack pSource) private static int
resetAllSequencesAndSetNewDefaults
(CommandSourceStack pSource, int pSeed, boolean pIncludeWorldSeed, boolean pIncludeSequenceId) private static int
resetSequence
(CommandSourceStack pSource, ResourceLocation pSequence) private static int
resetSequence
(CommandSourceStack pSource, ResourceLocation pSequence, int pSeed, boolean pIncludeWorldSeed, boolean pIncludeSequenceId) private static CompletableFuture
<com.mojang.brigadier.suggestion.Suggestions> suggestRandomSequence
(com.mojang.brigadier.context.CommandContext<CommandSourceStack> p_296223_, com.mojang.brigadier.suggestion.SuggestionsBuilder p_295797_)
-
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
-
drawRandomValueTree
private static com.mojang.brigadier.builder.LiteralArgumentBuilder<CommandSourceStack> drawRandomValueTree(String p_295419_, boolean p_295785_) -
suggestRandomSequence
private static CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> suggestRandomSequence(com.mojang.brigadier.context.CommandContext<CommandSourceStack> p_296223_, com.mojang.brigadier.suggestion.SuggestionsBuilder p_295797_) -
randomSample
private static int randomSample(CommandSourceStack pSource, MinMaxBounds.Ints pRange, @Nullable ResourceLocation pSequence, boolean pDisplayResult) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
resetSequence
private static int resetSequence(CommandSourceStack pSource, ResourceLocation pSequence) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
resetSequence
private static int resetSequence(CommandSourceStack pSource, ResourceLocation pSequence, int pSeed, boolean pIncludeWorldSeed, boolean pIncludeSequenceId) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
resetAllSequences
-
resetAllSequencesAndSetNewDefaults
private static int resetAllSequencesAndSetNewDefaults(CommandSourceStack pSource, int pSeed, boolean pIncludeWorldSeed, boolean pIncludeSequenceId)
-