Hi guys,
I'm in the process of making a COM script that allows MUSHclient to talk to CMUD (to pull data from the map).
Here is it so far:
Works fine, but now I'm stuck and after hours of searching the internet still don't have an answer.
Firstly, how would I go about putting a wildcard into the function? I'd want to replace CASTLE with a wildcard word, that would be picked up when the alias is typed.
My attempts so far have failed.
Next I can't figure out how to send (val) to the MUD, I can only print it, I've tried send,execute etc and nothing works.
Thanks in advance for your help.
I'm in the process of making a COM script that allows MUSHclient to talk to CMUD (to pull data from the map).
Here is it so far:
require("luacom")
require("luacom5")
cmud = luacom.CreateObject("cMUD.Application")
cmuds = cmud.CurrentSession
cmuds:processcommand("go CASTLE")
var = cmuds.getvar(Route,"Route")
val = var.value
print(val)
Works fine, but now I'm stuck and after hours of searching the internet still don't have an answer.
Firstly, how would I go about putting a wildcard into the function? I'd want to replace CASTLE with a wildcard word, that would be picked up when the alias is typed.
My attempts so far have failed.
Next I can't figure out how to send (val) to the MUD, I can only print it, I've tried send,execute etc and nothing works.
Thanks in advance for your help.