-
-
Notifications
You must be signed in to change notification settings - Fork 75
Closed
Labels
enhancementNew feature or requestNew feature or requestimplemented for next releaseThis has been implemented in the current dev build for the next public releaseThis has been implemented in the current dev build for the next public release
Description
Description
Commands with subcommands lose all of their subcommand information once the command is registered. This should be made accessible for runtime use.
Expected code
If you have this code:
CommandAPICommand main = null;main = new CommandAPICommand("main")
.executes((sender, args) -> {
System.out.println(main.getSubcommands().size());
});
CommandAPICommand sub = new CommandAPICommand("sub")
.executes((sender, args) -> {
System.out.println("Subcommand called");
});
main.withSubcommand(sub);
main.register();Then running /main should print 1.
Extra details
No response
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestimplemented for next releaseThis has been implemented in the current dev build for the next public releaseThis has been implemented in the current dev build for the next public release