Skip to content

Instantly share code, notes, and snippets.

@Dinnerbone
Created September 29, 2014 11:21
Show Gist options
  • Select an option

  • Save Dinnerbone/2a185a41dcddfb9abb67 to your computer and use it in GitHub Desktop.

Select an option

Save Dinnerbone/2a185a41dcddfb9abb67 to your computer and use it in GitHub Desktop.

Revisions

  1. Dinnerbone created this gist Sep 29, 2014.
    25 changes: 25 additions & 0 deletions gistfile1.java
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,25 @@
    dispatcher.registerCommand(
    literal("scoreboard").then(
    literal("players").then(
    literal("reset").then(
    argument("players", players()).then(
    optional("objective", objective())
    ).executes(SOME_COMMAND)
    )
    ).then(
    literal("list").then(
    argument("players", players())
    ).executes(SOME_COMMAND)
    )
    ).then(
    literal("objectives").then(
    literal("list").executes(SOME_COMMAND)
    ).then(
    literal("setdisplay").then(
    argument("slot", enumValues(ScoreboardSlotTypes.class)).then(
    argument("objective", objective())
    ).executes(SOME_COMMAND)
    )
    )
    )
    );