CommandTools

Features

CommandTools is a small plugin that allows you to execute commands simply by right-clicking an item.

  • Multiple commands can be assigned at once, using the book edition interface to manage a tool's commands, therefore creating a 'script'.
  • Commands are executed at the position you are looking at (for example, worldedit's chunk command will select the chunk you are looking at).
  • Tools are persistent, i.e. they will still work after the owner disconnects, put his tools in a chest, or if the server is restarted.
  • You can manage all your saved tools using the /ctool command (see the commands section below).
  • Tools can be shared with other player the same ways you can share any other item, by simply dropping them or putting them in a chest. However, they will only be able to use them if they have the commandtools.ctools permission.
  • An user can use a command in a script only if they have the appropriate permission, like if they used it normally.
  • Tools can be renamed, and giving different tools the exact same name is fine (they will be given an automatically generated internal ID in this particular case).
  • The # and ' characters can be used to comment a line in a tool's script.

Quick Tutorial

You can create and use Command Tools very easily, by following these few steps :

  1. Make sure you have an item in your hand, like a stick (any item or block will also work fine).
  2. Use the */ctool new* command, that will create a new tool in your hand.
  3. Use the */ctool edit* command, open the given book, and add the commands you want your tool to execute (for example, /say Hello world !).
  4. Close the book, and you can now right-click your tool to execute the given commands !

Commands

Command Tools are managed via the /ctool command. Since version 1.1, you can use the /ctool help command to get in-game help about all the supported commands. Here is a short extract :

  • /ctool new : creates a new tool, using the item you currently have in hand (the actual item used to create the tool will be put back in your inventory).
  • /ctool edit : transforms the tool you have in hand to an editable book, containing the tool's script. You can edit this book's content, and changes will be applied to your tool once you close the book, transforming it back to your tool.
  • /ctool list : shows a list of all the tools saved, i.e. all the tools you created using /ctool new.
  • /ctool get <name> : gives you the tool matching the given name.
  • /ctool rename <name> : renames the tool you have in hand with the given name.
  • /ctool delete : deletes the currently held tool from your hand and from the saved tools. The tool is therefore permanently lost.

Permissions

Currently, there is only one pemission : commandtools.ctools, that allows using Command Tools and the /ctool command.

Miscellaneous

I am open to any feature suggestion, and of course to bug reports on the plugin's Git repository. :-)

You can find the plugin's Git repository in here : https://github.com/prokopyl/CommandTools/ .

If you want to download experimental and unstable development versions, you can find them on Jenkins : http://jenkins.carrade.eu/job/CommandTools/ (adorably hosted by AmauryPi).

Enjoy ! :-)


Comments

  • To post a comment, please or register a new account.
Posts Quoted:
Reply
Clear All Quotes

About This Project

Categories

Members

Recent Files