CommandAPI
CommandAPI copied to clipboard
The new annotation system should support multiple command executors
Please describe your suggestion The new annotation system should support multiple command executors for a single command, similarly to how the CommandAPI does already
Please supply examples of the desired inputs and outputs Example: Input:
public class MyCommand {
public void blah(ConsoleCommandSender sender) {
// ...
}
public void blah(Player player) {
// ...
}
}
Output:
new CommandAPICommand("cmd")
.executesConsole((sender, args) -> {
// ...
})
.executesPlayer((player, args) -> {
// ...
})
.register();