Package net.minecraft.server.commands
Class TriggerCommand
java.lang.Object
net.minecraft.server.commands.TriggerCommand
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final com.mojang.brigadier.exceptions.SimpleCommandExceptionTypeprivate static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static intaddValue(CommandSourceStack source, ServerPlayer player, Objective objective, int value) private static ScoreAccessgetScore(Scoreboard scoreboard, ScoreHolder scoreHolder, Objective objective) static voidregister(com.mojang.brigadier.CommandDispatcher<CommandSourceStack> dispatcher) private static intsetValue(CommandSourceStack source, ServerPlayer player, Objective objective, int value) private static intsimpleTrigger(CommandSourceStack source, ServerPlayer player, Objective objective) static CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> suggestObjectives(CommandSourceStack source, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)
-
Field Details
-
ERROR_NOT_PRIMED
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_NOT_PRIMED -
ERROR_INVALID_OBJECTIVE
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_INVALID_OBJECTIVE
-
-
Constructor Details
-
TriggerCommand
public TriggerCommand()
-
-
Method Details
-
register
-
suggestObjectives
public static CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> suggestObjectives(CommandSourceStack source, com.mojang.brigadier.suggestion.SuggestionsBuilder builder) -
addValue
private static int addValue(CommandSourceStack source, ServerPlayer player, Objective objective, int value) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
setValue
private static int setValue(CommandSourceStack source, ServerPlayer player, Objective objective, int value) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
simpleTrigger
private static int simpleTrigger(CommandSourceStack source, ServerPlayer player, Objective objective) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getScore
private static ScoreAccess getScore(Scoreboard scoreboard, ScoreHolder scoreHolder, Objective objective) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-