GMCP Tutorial Part 3
Table of Contents
- Part 1 Retrieving GMCP Data
- Part 2 Discovering GMCP's Data
- Part 3 Sending GMCP
- Part 4 Triggering on GMCP
Your MUD might support sending commands via GMCP to it - for examples, take a look at this sheet for IRE games or Aardwolf’s wiki. For example, on IRE games, you can ask the server Char.Skills.Get and the server will tell you what skills you have got - this can come in handy for auto-configuring scripts. In Mudlet, the function to send a GMCP request is sendGMCP() - so with our example, you’d do:
in a script and get an appropriate Char.Skills.Groups response (as the documentation mentions).
The same Char.Skills.Get request can take additional parameters with it, like the documentation mentions:
(note how I replaced "" with [] now - that's because you can't have a " inside a "). You can either use the example above, or you can also use this:
Both have the same effect, but you might find the latter easier to work with as you get better with Lua.