commands
commands copied to clipboard
Unknown root command handling
May need paper only as a feature, but provide way to auto handle unknown root commands, and provide list of commands /help style, mixing Aikar command and Bukkit Commands
Relates with #3
This also technically falls under #3 in terms of management imo, My major thought is changes to the SimpleCommandMap so we can register a command to return in the event if there is no command under that name.
This would likely either require reflection in order to replace the existing command map and then mess around with the Commands themselves in order to enforce our ownership over the Command instance, which is something we could do, however, this would cause issues with any plugin that holds a reference to the SimpleCommandMap implementation in Bukkit before we get around to registering ours, and to be honest, the amount of work that code that would be needed to handle that, makes me question if this is actually a suitable method at all.
alternative is to get Paper to add methods to the SimpleCommandMap that allows us to register a fallback in the event no command is found
other idea: register to player preprocess, call getCommand() on the command map and determine ahead of time if the command is going to fail.