Page 2 of 2

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 1:21 pm
by Golem
I actually decided to check out this problem, and after a very short investigation ;-) found out that the Mudbot + Mudlet combination works as intended.
Yes, the gmcp array is empty on reconnect, but that is no surprise. Issue a command or simply wait for a new prompt and the values should come back.

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 1:56 pm
by bluebaleen
Golem wrote:I actually decided to check out this problem, and after a very short investigation ;-) found out that the Mudbot + Mudlet combination works as intended.
Yes, the gmcp array is empty on reconnect, but that is no surprise. Issue a command or simply wait for a new prompt and the values should come back.
Golem,

Firstly, let me say thank you for taking the time to setup the Mudbot software purely to investigate my problem. That said, the problem that I am experiencing occurs if I actually -close- the Mudlet software, reopen it, and reconnect through my profile. When you do this, Mudbot keeps its connection to the MUD server alive for a short period of time such that you do not have to re-enter your character's username and password.

I have found this feature to be quite useful for system development as it allows me to accommodate for any code changes that require my system to be reloaded while preserving the present state of my character in the MUD. Without this feature, any changes that require a fresh loading of the profile require that I log my character out, log back in, and re-raise all of their defenses. I understand that this may not be a big deal to some, but given my personal style of system development, it is a huge pain. I am apparently not alone in this pain as I posted this same question on the Aetolia forums and found that a number of other folks are struggling with the same thing:

http://forums.aetolia.com/discussion/38 ... ued#latest

If I have misunderstood your post and you did actually close the Mudlet client, re-open it, and reconnect to Mudbot through your profile with the connection to the MUD server kept alive and were successful in receiving gmcp, I would ask that you clarify which version of Mudbot you are testing and where you obtained the source code.

Thank you again for your time. It is greatly appreciated! :)

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 2:05 pm
by kevutian
Is a long shot as I don't use Mudbot, but this might be worth adding to the top level of your scripts:
Code: [show] | [select all] lua
sendGMCP(Core.Hello { "client": "Mudbot", "version": "2.42" })

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 2:07 pm
by kevutian
Actually, change that to:
Code: [show] | [select all] lua
if not gmcp then
   sendGMCP(Core.Hello { "client": "Mudbot", "version": "2.42" })
end

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 2:14 pm
by Golem
I used the 2.42 version from https://github.com/xondk/Mudbot
And yes, I did close the entire Mudlet app.

This is the result I got:
[Welcome back.]
[Nothing happened meanwhile.]
lua gmcp
{}
look
Beneath the waterfall. (...)
- lua gmcp
{
Char = {
Status = {
pk_level = "1 (0%)",
quest_level = "1 (0%)",
bash_level = "1 (0%)", (...)

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 2:26 pm
by kevutian
Time to crack open Wireshark!

Though it's likely just something simple like Mudlet not receiving a response when sending IAC DO GMCP.

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 3:49 pm
by Heiko
Mudlet decodes any GMCP/ATCP/MXP etc. data when it recieves it. There are no static switches that prevent interpretation of data packages if certain telnet negotiations haven't been done before to enable a given feature.
Consequently, if Mudbot passes through all GMCP data to Mudlet, Mudlet will be able to deal with the server GMCP it recieves. Your problem seems to be rooted more deeply in Mudbot not passing on gmcp data on client reconnect for existing game connections - presumably (just guessing here, I've never ever used Mudbot before) because there is no gmcp negotiations taking place. If my assumption is correct, you can initiate the gmcp telnet negotioantions with the server in your scripts by using the special unfiltered socket out function.

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 6:42 pm
by Curu
Hey,

I'm the one on the Aetolia forums that said I experienced the same problem. I just tested it quitting and restarting CMud multiple times with Mudbot still on and GMCP was fine every time. For Mudlet if I quit and restart without closing Mudbot I get this:

lua gmcp
{}

Over and over again. I've moved around, reset the prompt, all that good stuff, it still just gives that. Basically the GMCP normally looks like this:
{
Char = {
Name = {
name = "Ezalor",
fullname = "Arch Duke Ezalor D'baen"
},
Status = {
guild = "(None)",
explorer = "a Searcher of Horizons",
class = "Praenomen",
race = "azudim",
name = "Ezalor",
order = "(None)",
status = "Vampire",
level = "108 (19)",
city = "Bloodloch",
fullname = "Arch Duke Ezalor D'baen"
},
Skills = {
Groups = {
{
name = "Vision",
rank = "Transcendent 100%"
},
{
name = "Avoidance",
rank = "Transcendent 100%"
},
{
name = "Tattoos",
rank = "Transcendent 100%"
},
{
name = "Survival",
rank = "Transcendent 100%"
},
{
name = "Weaponry",
rank = "Transcendent 100%"
},
{
name = "Forging",
rank = "Transcendent 100%"
},
{
name = "Corpus",
rank = "Transcendent 100%"
},
{
name = "Mentis",
rank = "Transcendent 100%"
},
{
name = "Sanguis",
rank = "Transcendent 100%"
},
{
name = "Refining",
rank = "Gifted 0%"
},
{
name = "Constitution",
rank = "Transcendent 100%"
},
{
name = "Thermology",
rank = "Transcendent 100%"
},
{
name = "Frost",
rank = "Transcendent 100%"
},
{
name = "Antidotes",
rank = "Transcendent 100%"
},
{
name = "Fitness",
rank = "Transcendent 100%"
},
{
name = "Galvanism",
rank = "Transcendent 100%"
},
{
name = "Philosophy",
rank = "Transcendent 100%"
},
{
name = "Horsemanship",
rank = "Virtuoso 19%"
}
}
},
Vitals = {
deaf = "1",
moss = "1",
wield_right = "buckler266061",
class = "praenomen",
balance = "1",
status = "vampire",
wp = "23655",
soul = "100",
maxhp = "6461",
xp = "1000219",
blood = "100",
maxep = "29400",
maxmp = "5200",
wield_left = "spear142233",
herb = "1",
renew = "1",
residual = "2",
ep = "29400",
hp = "6461",
prone = "0",
elixir = "1",
focus = "1",
maxwp = "23655",
cloak = "0",
right_arm = "1",
blind = "1",
string = "H:6461/6461 M:5200/5200 E:29400/29400 W:23655/23655 NL:19/100 ",
left_arm = "1",
flying = "0",
nl = "19",
equilibrium = "1",
mp = "5200",
salve = "1",
pipe = "1",
tree = "1",
bleeding = "0",
maxxp = "5119380",
fangbarrier = "0"
},
StatusVars = {
guild = "Guild",
explorer = "Explorer rank",
class = "Class",
race = "Race",
name = "Name",
order = "Order",
status = "Status",
level = "Level",
city = "City",
fullname = "Full name"
}
}
}
If I log in and out, all that will be gone replaced by just

{}

So GMCP isn't being received. However, if I load up another Mudbot Module that also transmits GMCP then with a fresh login I get all that information PLUS this at the bottom:
Citadel = {
Data = {
auto_cloak = 1,
afflictions = {
},
auto_breath = 0,
todo_free = {
},
balances = {
rage = 1,
moss = 1,
right_arm = 1,
pipe = 1,
tree = 1,
renew = 1,
purgative = 1,
equilibrium = 1,
balance = 1,
salve = 1,
focus = 1,
nimbleness = 1,
left_arm = 1,
elixir = 1,
herb = 1
},
auto_mass = 1,
defences = {
deafness = "1",
Blindness = "1",
parry_left = "head"
},
settings = {
sip_smart_default = 0,
sip_priority = 2,
use_aesthesis = 1,
use_thirdeye = 1,
mana_sip = 0.9,
parry_mode = "norm",
sip_smart_health = 0.6,
use_insomnia = 1,
pipe_sets = 1,
mana_moss = 0.75,
health_moss = 0.5,
renew_cmd = "reconstitute",
health_sip = 0.9,
insomnia_mana = 0.5,
sip_smart_mana = 0.6,
clot_mana = 0.5
},
flags = {
},
auto_scans = {
renew = 1,
precache = 1,
moss = 1,
mana = 1,
writhe = 1,
elixir = 1,
focusing = 1,
rage = 0,
stand = 1,
tree = 1,
parrying = 1,
wake = 1,
smoke = 1,
reject = 1,
health = 1,
salve = 1,
clotting = 1,
defence = 1,
prerestore = 1,
herb = 1
},
todo_list = {
},
auto_aura = 1
}
If I then close and reopen Mudlet without closing Mudbot then I ONLY get that second quote of GMCP WITHOUT the first big block.

Dunno if this information helps much. From my (admittedly completely untrained and completely newbie) impression this means that Mudbot is transmitting GMCP fine to Mudlet still but for whatever reason has stopped receiving GMCP from the actual server. Again this problem only persists in Mudlet

Now here's something really interesting:

If I ONLY use CMud and NEVER open Mudlet then GMCP is perfectly fine between sessions. It will continue working no matter how many times I close and open CMud without closing Mudbot. If however I log onto Mudlet in between CMud logins then GMCP will stop working even if I go back to CMud. For example:

Keeping Mudbot on all the time:
Log on CMud
Log off CMud
Log on CMud
Repeat to infinity
= GMCP works fine

Keeping Mudbot on all the time:
Log on CMud
Log off CMud
Log on Mudlet
Log off Mudlet
Log on either
= GMCP no longer works on either client

Keeping Mudbot on all the time:
Log on Mudlet
Log off Mudlet
Log on Cmud
= GMCP works fine

So basically if the first login is through Mudlet GMCP will still work despite logging off it. The problem child here is if you log into Mudlet and it's not your first login GMCP will stop working no matter what client you switch to.

Here's the source code for Mudbot: https://github.com/Xondk/Mudbot

To recap, the problem seems to be that the server stops sending GMCP while Mudbot still sends it fine (unsure of this part) if you login to Mudlet while Mudbot is keeping an existing character logged into the server (sure about this part).

I'll leave it to you people who actually know what you're talking about to isolate and identify what's happening here.

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 6:56 pm
by Golem
Unfortunately I can't seem to reproduce this problem (and I have tested this with the same Mudbot, Mudlet and mud :) )
The only other option is one of the modules you are using with mudbot, since I haven't activated any of them.

Re: Mudlet 2.1, Mudbot, and GMCP

Posted: Thu Feb 14, 2013 6:59 pm
by Curu
Golem wrote:Unfortunately I can't seem to reproduce this problem (and I have tested this with the same Mudbot, Mudlet and mud :) )
The only other option is one of the modules you are using with mudbot, since I haven't activated any of them.
I thought it was this too but I've tested it with no modules, with the mapper module, with the Citadel module, and with both modules. The problem persists through all those states.

EDIT: My test wasn't completely thorough with a new installation and all though. I just disabled the modules by renaming i_mapper.dll to something else and i_citadel.dll to something else. The other files accompanying those modules are still in my Mudbot folder, though I'm not sure that makes a difference. I'd test more with a clean installation and all but I've got a midterm in 5 hours and I've already wasted too much time on this :D .