Open Lemar98 opened 2 years ago
It should tab complete on the sub commands as well. Do you have a simplified example?
Most likely you did not understand me because of my bad English, sorry.
Let's say I have /macommand sub
I want to display a list of tabcompletions to the player when he types /maincommand sub so he has a hint for arg1, arg2 and arg3
Is it possible with your api to provide the player with options for arguments in the form of tabcompletions ?
Actually that's exactly what it should do. When you type /maincommand sub
and hit space then it should then show a list of the options you can choose from. I'll double check that I didn't break anything in one of my recent changes that affect sub command completion.
I want to pass my own list of hints as tab completions, for example, taken from the config
are you here?
Regarding this issue. It may be that you need to write a custom parser (which is pretty easy). For example in my plugin PortalNetwork it has definitions of portal types in a config file. I then have a custom parser registered with the string @parsertype
that when dropped into @Arg
will load the config and show completions based on their names, with descriptions as their tooltips.
Here's a screenshot of the parser (since it's not committed yet) and I'll make sure to write some docs on how to create the parsers.
Why is it not possible to add tabcompletions to a subcommand?