Commands/trigger

From Minecraft Wiki
Jump to: navigation, search
trigger
Restrictions

None

First introduced

1.8 (14w06a)

Modifies a scoreboard objective with a "trigger" criterion.

Syntax
trigger <objective> <add|set> <value>
Description
Used together with /tellraw to let players activate systems made by operators or mapmakers.
Arguments
objective
An enabled scoreboard objective with the "trigger" criterion.
add|set
  • add – Adds value to the current value of objective.
  • set – Sets the value of objective to value.
Result
Fails if the arguments are not specified correctly, if objective does not have the "trigger" criteria, or if the player who executed the command is not able to modify objective.
On success, the value of objective is changed for the player that executed the command.