Updated Command system (markdown)
parent
5ab2be0588
commit
60d40a26ee
1 changed files with 2 additions and 0 deletions
|
@ -30,6 +30,8 @@ What it does and why
|
||||||
Usage: /some <someArg>
|
Usage: /some <someArg>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Subcommand methods
|
||||||
|
|
||||||
The return type can be void or boolean, if you return false it will display the help text. You can use any simple type (primitives and String) as parameters, and can add more types using `command2.addParamConverter()`. Plugins are also supported via a builtin param converter. Command2 instances can also be obtained using `getManager()` from a command class.
|
The return type can be void or boolean, if you return false it will display the help text. You can use any simple type (primitives and String) as parameters, and can add more types using `command2.addParamConverter()`. Plugins are also supported via a builtin param converter. Command2 instances can also be obtained using `getManager()` from a command class.
|
||||||
|
|
||||||
You can define optional arguments or text arguments (that can take spaces) and define custom tab completion instead of one based on parameter type. `@CustomTabComplete` lets you define constant strings while `@CustomTabCompleteMethod` lets you use a method to figure out what options are available based on previous arguments.
|
You can define optional arguments or text arguments (that can take spaces) and define custom tab completion instead of one based on parameter type. `@CustomTabComplete` lets you define constant strings while `@CustomTabCompleteMethod` lets you use a method to figure out what options are available based on previous arguments.
|
||||||
|
|
Loading…
Reference in a new issue