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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum
Larkin
Wizard


Joined: 25 Mar 2003
Posts: 1113
Location: USA

PostPosted: Wed Apr 05, 2006 12:26 am   

Colors and logs
 
Forgive me if this has been mentioned somewhere already, but I cannot find it here.

I like to use a lot of the non-ANSI colors by specifying HTML colornames with #CW and #COLOR, or by using MXP color commands. My logs do not show these colors as I see them on the screen, and I can certainly understand that this is a legacy issue. The colors were added after the logging module was built, and the HTML support is only through third party tools.

Will there be options for logging with full HTML colors and codes in CMUD? Can we hope to find improved options all around for logging things, maybe? Triggers that gag from the screen but not from the log, for example.
Reply with quote
Zugg
MASTER


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

PostPosted: Wed Apr 05, 2006 3:24 am   
 
Yes, there will be more log options. HTML logging is planned since the new editor module supports saving stuff as HTML or RTF. Not sure how much will be in the first beta, but HTML logging is definitely on the feature list before the public version.
Reply with quote
ZealousAnonymous
Wanderer


Joined: 06 Jan 2006
Posts: 70

PostPosted: Thu Apr 06, 2006 2:39 am   
 
Im with Larkin on this. Logging the trigger values too without actually echoing them would sooo rock.
Reply with quote
Seb
Wizard


Joined: 14 Aug 2004
Posts: 1269

PostPosted: Tue Apr 18, 2006 11:50 am   
 
On the subject of logs, JMC Mud Client includes a "RMA player" which attempts to provide a simulated real-time playback of logs. This was quite fashionable on my MUD a few years back, but this feature doesn't seem to be used so much now, partly because JMC logging is "messed up". This log was posted in RMA format: http://www.elvenrunes.com/cgi-bin/logs/mumps?rou=show&log=58916,18835 - you can click show without filters at the bottom of the page to get the raw RMA format - I chose this example as they are lots of comments on RMA in it.

Still, it's another selling point. I'm sure I would use it in CMUD. An important part, of course, is the log player, and that it works on the internet.
Reply with quote
Zugg
MASTER


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

PostPosted: Tue Apr 18, 2006 7:21 pm   
 
Is RMA an open spec that is defined somewhere? While I can see supporting an open log file spec if that's possible, I probably won't be spending a lot of my own time on a web-based log viewer. But if a standard already exists, I can probably support it, or maybe someone else wants to work on the web-based backend. Although I'd like to see something that doesn't require Java (JavaScript is ok, but I tend to keep Java and ActiveX turned off myself).
Reply with quote
Seb
Wizard


Joined: 14 Aug 2004
Posts: 1269

PostPosted: Sat Aug 02, 2008 5:06 pm   
 
2 years later... I tried at length to find the RMA spec at the time, or any information on how to format the RMA log files and only turned up what I could guess by reading the raw log files (and what I had already turned up above)... However, I've just had a second attempt and was more successful this time.

Resources wrote:
RMA Logging (download player Rma.exe and Rma_doc.txt here)
RMA gives you an ability to view MUD logs (battles, challenges etc) in full realism, with colors and pauses.

Relevant part of Rma_doc.txt:
Code:
  What is RMA? Basically, it is simple ANSI player with one new code added:
  [ESC]p:[millisecs]m  , where [ESC] is escape code
                               [millisecs] amount of time to pause

I found the source code for Jabba Mud Client and the part that appears to add the RMA stuff to log files is:
Code:
        // Add RMA ANSI command
        if ( bRMASupport ) {
            DWORD Currticker = GetTickCount();
            if ( Currticker - LastTicker ) {
                buff[0] = 0x1B;
                sprintf(buff+1 , "p:%dm" , Currticker - LastTicker);
            }
            LastTicker = Currticker;
        }

That code can be viewed here, or a newer version downloaded in the package here (which also includes HTML logging, but not at the same time, since RMA uses ANSI).

I know that a Java player has also been written for the web. Maybe other players are available. Would a JavaScript player actually work? I assume someone made a Java player instead of JavaScript, because they either assumed it wouldn't work (very well?) or didn't know enough JavaScript to make one. I know JavaScript does not have a sleep feature, but it should be possible with setTimeout, I think. It seems that accurate timing / sleeping / pausing in JavaScript is impossible (on some platforms _and_ if your browser is doing anything else).
Reply with quote
XonDK
Apprentice


Joined: 01 Dec 2006
Posts: 178

PostPosted: Fri Aug 08, 2008 3:51 pm   
 
I'd personally love to see zmud able to log in a method that would allow for RMA playback would make reviewing logs even more interested.
Reply with quote
Zugg
MASTER


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

PostPosted: Mon Aug 11, 2008 5:17 pm   
 
I'll add that to the wish list. If I only just need to add escape codes to indicate the time delays, then it should be pretty easy.

Too bad the person who came up with this spec really bastardized the way ANSI codes are handled though. Putting the "m" character at the end just confuses it with the ANSI color code and they don't even have the opening [ bracket that is usually used to start an ANSI sequence. Very weird syntax.
Reply with quote
Seb
Wizard


Joined: 14 Aug 2004
Posts: 1269

PostPosted: Mon Aug 11, 2008 11:05 pm   
 
Zugg wrote:
Putting the "m" character at the end just confuses it with the ANSI color code and they don't even have the opening [ bracket that is usually used to start an ANSI sequence.

Well, doesn't the absence of the opening [ bracket distinguish it from a real ANSI code? Seems to me like it makes a clearer distinction from real ANSI codes...
Reply with quote
Zugg
MASTER


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

PostPosted: Tue Aug 12, 2008 4:26 pm   
 
Well yes, I suppose it does. But then why bother with the "m" at the end? Also, without the "[", then some programs might confuse it with just a plain ESCp code. If I was the one implementing this code, I would understand that most ANSI parsers trigger off of the [ bracket (or a couple of other characters like ? for queries) for extended terminal options. And then I'd use a letter at the end that wasn't currently used (like the "z" code that I use for MXP). Most ANSI processors ignore codes that they don't recognize. It's pretty easy to look at the later extensions of VT100 like from VT4xx terminals to see how they extended VT100 so that new features didn't break on old terminals or interfere with other escape codes.

Doesn't really matter since this is just a made-up code for log files and not for live display. I just didn't seem like a lot of thought was put into it.
Reply with quote
Seb
Wizard


Joined: 14 Aug 2004
Posts: 1269

PostPosted: Tue Aug 12, 2008 8:09 pm   
 
Zugg wrote:
I just didn't seem like a lot of thought was put into it.

I suspect whoever came up with it didn't have the ANSI experience that you do! Wink One thing I can say for it though (and this isn't important enough that compatibility shouldn't have been better considered) is that I _was_ able to guess (as it happens, correctly) what it did by reading a log file before I found all that info. (p for pause, digits ... m for number of milliseconds: fairly guessable to someone with very little knowledge of ANSI.)
Reply with quote
Zugg
MASTER


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

PostPosted: Tue Aug 12, 2008 10:36 pm   
 
Oh..."m" for milliseconds is something I didn't think of. Is the time *always* in milliseconds with the "m" at the end, or does it sometimes use different time units?
Reply with quote
Seb
Wizard


Joined: 14 Aug 2004
Posts: 1269

PostPosted: Sat Oct 18, 2008 12:24 am   
 
Well, I've only ever seen the time units in milliseconds, and that is the only time unit described in the 'spec' I posted above.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum 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