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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Yourmom
Beginner


Joined: 06 Jan 2003
Posts: 10

PostPosted: Tue May 06, 2003 7:56 pm   

Capturing stuff with Timestamps
 
So Zmud help says to capture tells to a seperate window, I should use this trigger:
#TRIGGER {tells you} {#CAP tell;#GAG}

However, I would like to insert a time stamp on the same line as the tell in the other window so it would look like this:
15:43:23 - ABC tells you blah blah blah
or somesuch...

Any ideas?
Reply with quote
Kaishaku
Beginner


Joined: 01 May 2003
Posts: 20

PostPosted: Tue May 06, 2003 8:13 pm   
 


#tr {(%w) tells you (*)} {#win Tells ({%time (t)- %1 tells you: %2};#gag}

Should do it. Check the }'s and )'s. for I r teh suq, when it comes to closing commands.
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Tue May 06, 2003 8:29 pm   
 
Just insert the timestamp ahead of the capture.
#TR {tells you} {:tell:#SAYP %time(hh:nn:ss) - ;#CAP tell;#GAG}

LightBulb
Advanced Member
Reply with quote
Yourmom
Beginner


Joined: 06 Jan 2003
Posts: 10

PostPosted: Tue May 06, 2003 9:55 pm   
 
Thanks for the incredibly fast response guys! Worked like a charm...

I do have another question though.

I used Kaishaku's syntax for the most part (I decided NOT to gag it from my main window though, so I removed the #gag part), and I'm wondering how I can recolor the lines in the capture window. At the moment, the whole line shows up as cyan colored. Say I wanted the timestamp to be cyan, the teller to be in bright red and the tell itself to be in bright green, what would I have to add?

I've played around with pcolor, but it changes the color in the main window, not the captured, and I don't know how to tell it where to stop recoloring either. The syntax in the help file says to use XStart and XEnd as arguments, but I don't understand what should go in those arguments, or how to format them.
Reply with quote
Death
Apprentice


Joined: 25 Jun 2002
Posts: 109
Location: USA

PostPosted: Wed May 07, 2003 2:51 am   
 
You could use #win instead of #cap.

#TR {(%w) tells you (*)} {#WIN tell {%ansi(cyan,bright)%time(hh:nn:ss) %ansi(black,bright)- %ansi(green,bright)%1 %ansi(default)tells you %ansi(red,bright)%2}}

I've used both and still continue to do with my channel/info capture script. Hope that helps.

-Death

-=Realms of the Forgotten=-
site: www.rotf.net
connect: rotf.net:5000
Reply with quote
Yourmom
Beginner


Joined: 06 Jan 2003
Posts: 10

PostPosted: Wed May 07, 2003 3:32 am   
 
Worked great. Thanks a bunch!
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Wed May 07, 2003 4:10 am   
 
I included #GAG because you had it in your own example.

#WINDOW is best when you want to assign your own choice of colors. #CAPTURE is best when you want to preserve the original colors from the MUD.

LightBulb
Advanced Member
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD 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