ShortCommands v1.0.5.3Make your own Commands!For TerrariaAPI[v1.12]Features: Create your own commands, these commands are shortcuts to other commands. Config to create as many commands as you want. Commands /scmdrl - reloads the config file, Requires the permission "shortcmd" Any other commands you specify in the config. If the user has the permission "shortcmd.nocooldown" they will not have to wait for cooldowns. Configuration File: Located in: tshock/PluginConfigs/ShortCommands.json The config should automatically generate once you start the server If you have problems or need help, please PM me your config file, and I will help you set it up (if i can). Installation: Download & Extract. Place the .dll file in the ServerPlugins folder. Setup your config (An example config is included in the download). Have fun! Download: ShortCommands.dll (v1.0.5.3) Source Code (GitHub) TODO: I am completely open to suggestions, so if you want something changed or added, Just ask! This Configure a default value if a parameter isnt specified. Changelog: v1.0.5.3 Fixed /user group not updating v1.0.5.2 Fixed a problem in 1.0.5.1. v1.0.5.1 %variables get automatically wrapped in quotes incase they contain spaces. v1.0.5 Fixed quotes still making space a new parameter. "%name" will be replaced with the executing player's name. "%account" will be replaced with the executing player's account name (or empty if not logged in). "%group" will be replaced with the executing player's group name. v1.0.4 Added cooldown option in config using string.format to allow parameters in different positions cleanup v1.0.3 [Update] API tick to 1.12 New permission system: added a configurable permission for the alias, where you dont need permission to do the 'long' commands if you have permission to do the alias. set the alias's permission to nothing to disable this. Changed config format, see example config in download. v1.0.2 Pagination support (Parameters you use when typing the short command will be put at the end of all long commands). Renamed ShortCMD.dll to ShortCommands.dll v1.0.1 Aliases can do multiple commands v1.0 Initial Release.
I forgot to tell everyone, A blank config is created in tshock/PluginConfigs/ShortCommands.json What do you mean? ... The short commands don't show in /help
Interesting idea. So this is basically like a "macro" in a sense for commands you use frequently? The only suggestion I have would be to add optional arguments. Although in a lot of cases supplying arguments with a "short command" would make it just as long as a long command, if you only had to change 1 argument out of say 5 it would still be quicker.
a per-user command alias database would be really neat like /alias lava 'buff "obsidian skin"' /lava or even scripts of commands /alias adventure 'gentraps 5000' 'genchests 999' 'i "shine potion"' /adventure
each user would be able to save their own commands, in a database. for instance, if i ran a certain command a lot (even as a regular default user) /warp emerald_city i could be like /alias 1 'warp emerald_city' and from then on, i could always just /1 to issue that command (or list of commands!)
the commands could be registered on greet player - with a check to see if that particular command exists it might be wise to use a different indicator for aliased commands so the plugin could e.handled it only obstacle would be multiple commands - how to reissue them as the player in sequence?
There is a similar shortcut commands in Chat Blocker but stringing commands together under one letter is obviously much cooler. This could go rather far.
I meant replace the "real" command with the "short" command in /help Pagination support would be awesome. /ss masterpricelist - i want it short, but pages wont work when its a short. ;( Great plugin, using and watching. ;P
great idea, also a fan of scripting features if possible. this would make all the region/schematic/conversion tasks just that much faster.
Done, an alias can now do multiple commands! Make sure you update your config using the example, It will say theres an error if you keep your old conifg. Edit: also added Pagination support etc... Last time I tried I wasnt sucessful in removing commands from /help. However I can add the short commands to /help, But if you reload the config then I wouldnt be able to remove any commands you removed from the config. Oh, and I will add Pagination support.
oh nice, /r1 and /r2; /rd <name>, /ra <person>, /rp <true> (region set, region define, region allow, region protect) I had /rg instead of /region, but that looks much cooler.