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
virtuous
Wanderer


Joined: 08 Jan 2003
Posts: 60

PostPosted: Mon Mar 31, 2003 3:54 am   

Changing A Displayed Line
 
I capture some lines to one of my child windows. I want to insert a timestamp in front of each one. I can't find any command that will alter a line that is already displayed on the screen, except for #color.

I put this trigger in the child window.
#trigger {^} {#substitute {Testing:}}
But that locks up zMUD every time.

Any ideas? Is there a command to alter a line that is displayed in a window? I have considered doing something like
:OtherWindow:#say {Testing: %line}
but that's probably going to fail on special characters or something. Will this work?
:OtherWindow:#say {Testing: %expand(%line, 1)}
Or will something else work? I even looked for a COM solution, but I can't find any property/method/function to access the output lines.

(I just now tested. I did
#show {#show a; #show b}
and created an alias
#alias test {#show {Testing: %line}}
and used it, and it didn't mess up on the semicolon, so I'm assuming using %line like this does indeed work. I'd still like to know if there's a way to modify displayed lines, though. Certainly, if I wanted to change the last line on the screen, I could display %line with modifications and #gag -1, but #gag has a known bug that can destroy information, and what if the line I want to modify is more than two lines prior to the current line?)
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Mon Mar 31, 2003 4:38 am   
 
Just put :OtherWindow:#SAYPROMPT %time() ; before the command (#CAP, #WIN, etc) that sends the line to the OtherWindow.

If you don't actually need to know the EXACT time of EVERY line, you could probably get by with a one-minute alarm.
:OtherWindow:#ALA timestamp *1:00 {#SAY %time()}

That should be more than sufficient to tell when things happened.

LightBulb
Advanced Member
Reply with quote
virtuous
Wanderer


Joined: 08 Jan 2003
Posts: 60

PostPosted: Mon Mar 31, 2003 5:15 am   
 
Ack, I'm sorry, I did not even see that command. Thanks.
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