Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
Delphi03
Novice


Joined: 20 Aug 2004
Posts: 37
Location: Illinois

PostPosted: Fri Apr 02, 2010 6:08 pm   

Escape Triggers
 
I'm trying to make a trigger against some output that's sent to show ailments/buffs.

This is usually sent in the format of:

Code:
(esc)(letter)   (ailment/buff message)


where (esc) is the actual escape character and (letter) is just a single letter.

The problem I'm encountering right now is...it appears that cmud is eating/destroying/hiding these in some way. That is, where I would expect the following:

Code:
(esc)P   Poisoned!


I see

Code:
   Poisoned!


How can I get these to show up/come through to cmud? And once I get there, how do I trigger against the escape character itself?
Reply with quote
Delphi03
Novice


Joined: 20 Aug 2004
Posts: 37
Location: Illinois

PostPosted: Thu Apr 08, 2010 3:15 am   
 
Anyone?
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Thu Apr 08, 2010 3:42 am   
 
Unless this protocol happens to be tripping the ANSI emulator, I don't think the %e wildcard would be available to you. Without more detailed information about the protocol, it's probably the case that you simply can't process on it.
_________________
EDIT: I didn't like my old signature
Reply with quote
Delphi03
Novice


Joined: 20 Aug 2004
Posts: 37
Location: Illinois

PostPosted: Thu Apr 08, 2010 4:18 am   
 
There's no fancy protocol at all, it's just sent raw from the server; however, I can't even see that in the cmud window as incoming text. Neither the (esc) character nor the P character show up at all. The rest of the line does.
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Thu Apr 08, 2010 4:54 pm   
 
Well, I wouldn't expect a telnet display (which is essentially what the Cmud window is) to show an escape-P, or any other escaped character. Escaped characters are usually some kind of control mechanism, and doesn't display the literal character. If your mud is literally sending an escape-P, I would expect nearly every mud client in the world to display nothing.

Does this mud have its own customized client? If so, this probably _is_ a special protocol to communicate with that specific client. No other client will work with it. Is there a setting you can change on the mud to tell it you aren't using the customized client?
Reply with quote
Delphi03
Novice


Joined: 20 Aug 2004
Posts: 37
Location: Illinois

PostPosted: Thu Apr 08, 2010 8:09 pm   
 
Yes, it has an "enhanced" client.

I was just looking to mimic some of the "enhanced" features for convenience.

It is a shame there's no way to create triggers against the incoming/raw text before it gets pushed onto the terminal window. That would seem an ideal way to handle specific things like that.
Reply with quote
Zugg
MASTER


Joined: 25 Sep 2000
Posts: 23379
Location: Colorado, USA

PostPosted: Fri Apr 09, 2010 3:32 am   
 
The problem with "raw" triggers is that the network can break the data packet at any point and dealing with that in triggers is nearly impossible. The only way to do it would be if CMUD buffered the entire raw data, but it doesn't...it gets sent to the screen and parsed for ANSI, VT100, MXP as soon as it is received for performance reasons. When your trigger runs, it is pulling the text from the screen and any non-supported control codes have already been stripped at that point.

Using something like ESC-P in the text definitely interferes with normal ANSI and VT100 emulation done by most Telnet/MUD clients. That MUD should really explore how to handle there features in a *standard* way that other clients could support rather than inventing their own conflicting protocols.

About all you could do is write some sort of "proxy" program that intercepts this kind of data and turns it into something else CMUD could trigger on.
Reply with quote
Delphi03
Novice


Joined: 20 Aug 2004
Posts: 37
Location: Illinois

PostPosted: Fri Apr 09, 2010 3:45 am   
 
All right.

Thanks for all the help. I'll explore other options if possible, but it sounds like I'll just have to deal with it not working as well as expected.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net