jk2mv icon indicating copy to clipboard operation
jk2mv copied to clipboard

Create autocompletion API for modules

Open aufau opened this issue 8 years ago • 3 comments

Ability to autocomplete command arguments, eg. callvote or tell would be particularly useful (latter could probably go straight to JK2MV). Should we allow mods to override autocompletion functions defined by JK2MV?

I hope I can make it before next release, but I wouldn't make it a milestione as there are enough changes by now.

aufau avatar May 19 '16 19:05 aufau

override the autocompletion functions should be optional for mods if this will be an api

TriForceX avatar May 19 '16 19:05 TriForceX

i'd prevent mods from overriding engine cmds completely anyway

ouned avatar May 19 '16 22:05 ouned

I think it would be nice to offer some calls for mods to register own auto-complete functions (for commands like callvote), but I don't see a reason why a mod should be able to overwrite the auto-complete functions of engine-commands like map, bind or exec.

Auto-complete for tell doesn't really make sense in my opinion, cause basejk only accepts clientNums and you can't really auto-complete those. There are mods that allow the use of full or partial names when using the tell command, but having name-completion on basejk servers that don't support the use of tell with names is far more confusing for players than helping them. So I would prefer to leave auto-complete functions for mods up to mods.

Daggolin avatar May 22 '16 17:05 Daggolin