I wrote some stuff.

Razorfish
:)
Chat Command System
I wrote this TurboHUD plugin to commandeer the in-game chat prompt, adding another way to accept player input and make plugins respond to requests. ChatCommand streamlines the implementation of custom chat commands, handling the quirks involved in polling for changes in UI text, parsing chat text and sending out neatly packaged notifications to IChatCommandHandler plugins that are listening for specific invocation strings.


ChatCommand matches any kind of text at the beginning of the input string. It doesn't have to be a forward slash command, but I prefer forward slash commands because they don't show up to other players in chat when you submit them (press Enter). It also notifies interested plugins whenever there is a change in the command parameters, which allows a plugin to respond on-the-fly if desired, not just upon submit.

Here is an example of a quick developer tool I put together with it that responds to a /texture chat command and displays the provided texture id in a movable, resizable area for testing. Resizing icons and getting the desired scaling and positioning now takes less trial and error.


CommandTexture takes the following types of input:
  • /texture texture_id
  • /texture texture_name_string
  • /texture texture_page_id frame_id
To delete a shown texture, go into the Movable Plugin System's Edit Mode (F12), hover over the image area and toggle it off (Ctrl+X).

Any other plugins I write that use the Chat Command system will be tagged with the Chat Command label.

Installation

Chat Command System + CommandTexture (Last Updated April 24, 2021)

Extract the files in the archive into your TurboHUD folder, the files should end up in the following locations:

TurboHUD \ plugins \ Razor \ Chat \ ChatCommand.cs
TurboHUD \ plugins \ Razor \ Chat \ IChatCommandHandler.cs
TurboHUD \ plugins \ Razor \ CommandTexture.cs (optional)

The CommandTexture plugin requires the Movable Plugin System to also be installed, but the Chat Command system itself does not.

Latest Movable