I'm having problems with the wait.lua module.
I have MUSHclient version 4.86 installed on a Windows 7 machine, and I play Simutronics' Modus Operandi.
MO requires you to log into an authorization server, exchange some information with the server and use that information to log into the actual game server.
I have the following Simutronics.lua script file:
The first step in interacting with the Simu authorization server is to send "K" to the server. The server responds by sending a 32-character string of gibberish that is commungled with one's account password for additional processing. The script above is written to perform that first step.
When I reload the Simutronics.lua script, connect to the server and enter "/Main()" (without the quotes) from the command line, I get the following output.
This is a problem, because when I've added other functions to process the value of KLine in my Main () function, they read the value of KLine as nil.
However, if I run the Main () function as described above, and then type "/Note (KLine)" (without the quotes) into the command line immediately after running Main (), the value of the 32-character string is printed in blue.
I would appreciate any advice that anyone can give.
Thank you for your help.
I have MUSHclient version 4.86 installed on a Windows 7 machine, and I play Simutronics' Modus Operandi.
MO requires you to log into an authorization server, exchange some information with the server and use that information to log into the actual game server.
I have the following Simutronics.lua script file:
function ObtainK ()
Send "K"
KLine, wildcards = wait.regexp ("^(.*?)$", 10)
end --ObtainK()
function Main ()
require "wait"
wait.make (ObtainK)
Note (KLine)
end --Main()
The first step in interacting with the Simu authorization server is to send "K" to the server. The server responds by sending a 32-character string of gibberish that is commungled with one's account password for additional processing. The script above is written to perform that first step.
When I reload the Simutronics.lua script, connect to the server and enter "/Main()" (without the quotes) from the command line, I get the following output.
K <--in white, echo of "K" sent to server
nil <--in blue, MUSHclient Note of value of KLine
Fv`HOxP|aM\WfwE_lEP__eOsymNNWet <--in white, response from server of 32-character string
This is a problem, because when I've added other functions to process the value of KLine in my Main () function, they read the value of KLine as nil.
However, if I run the Main () function as described above, and then type "/Note (KLine)" (without the quotes) into the command line immediately after running Main (), the value of the 32-character string is printed in blue.
I would appreciate any advice that anyone can give.
Thank you for your help.