-
-
Save Dinnerbone/2a185a41dcddfb9abb67 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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) | |
) | |
) | |
) | |
); |
Oh the horror… Why don't you just use LUA for user-created stuff, like lots of other mature projects does? Instead of this… this… spaghetti.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Why do you have this marked "Secret" if you're posting it on Twitter? Why not let people find it from here too? You could put a comment or something explaining the context.