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
Grelf
Newbie


Joined: 05 Aug 2004
Posts: 3

PostPosted: Thu Aug 05, 2004 10:34 pm   

Strange problem with capturing text.
 
On Gemstone, I'm capturing logins and logoffs to another window, but everytime it captures, it's still producing a newline on the main window.

#TR {$%1 %2 joins the adventure.} {#gag;#cap Logging}

Any suggestions?
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Fri Aug 06, 2004 3:04 am   
 
Suggestion 1. Don't use numbered parameters (%1 - %99) in trigger patterns. They are intended for trigger values (where the commands go) and aliases. Use * in patterns, it has the advantage of being documented as a pattern wildcard.

Suggestion 2. Don't use multiline trigger patterns (ones that have $ anywhere except the end) with commands which act on an entire line, such as #GAG and #CAPTURE.

Suggestion 3. If you want to remove the previous line, use #GAG -1.
#TR {joins the adventure.} {#GAG;#CAP Logging;#GAG -1}
_________________
LightBulb
Senior member

Most scripts in this forum are written for Command Line entry.
Don't even open the Settings Editor unless its use is specified or obvious.
Reply with quote
Grelf
Newbie


Joined: 05 Aug 2004
Posts: 3

PostPosted: Fri Aug 06, 2004 3:27 am   
 
Well, I changed the parameter to %w
Removed the multiline trigger patterns
And added the #gag -1.

I'm still getting blank lines on my main window.
I removed the #gag -1, and it made no difference.
Reply with quote
Grelf
Newbie


Joined: 05 Aug 2004
Posts: 3

PostPosted: Sat Aug 07, 2004 12:45 am   
 
(Edited by author)

After lots of searching here, I found the problem. :>

Thanks Zuggy
Reply with quote
KurtDH
Beginner


Joined: 14 Sep 2004
Posts: 17

PostPosted: Tue Sep 14, 2004 7:24 pm   
 
I'm having a similar problem. When using gag -1, it's still scrolling the screen with a blank line. When using gag -2, it doesn't scroll the screen, but I find it is gagging text other than what I have it triggered to gag. For example, sometimes it will gag a shout, or somebody walking into my room, when I only want it to gag a yell. In addition, using gag -2 makes it almost impossible to read anything on your screen because it causes the screen to move up and down for a brief second when it gags the necessary text. What would be ideal, and what I'm trying to figure out is, if it's possible to gag the text from the screen, keep it from scrolling an extra line when the text is gagged, and keep the screen from "bouncing" when it does gag the text. Any help would be appreciated.
Reply with quote
geniusclown
Magician


Joined: 23 Apr 2003
Posts: 358
Location: USA

PostPosted: Wed Sep 15, 2004 2:10 am   
 
Use #GAG without any parameters to gag just the line triggering. #GAG -x gags the next x lines.

It would help use center on your problem is you show us what the unwanted text looks like (in context with other lines), and what trigger you're using that isn't working as desired.
_________________
.geniusclown
Reply with quote
Falan
Wanderer


Joined: 17 Aug 2004
Posts: 98
Location: OK, USA

PostPosted: Wed Sep 15, 2004 7:24 am   
 
Add a #COND to your trigger to match and #GAG the next blank line.

#TR {joins the adventure.} {#GAG; #CAP Logging}
#COND {^$} {#GAG}
_________________
zMUD 7.05a
Reply with quote
KurtDH
Beginner


Joined: 14 Sep 2004
Posts: 17

PostPosted: Mon Sep 20, 2004 6:55 pm   
 
Using a #cond trigger still isn't fixing the problem. My trigger looks like this:

#trigger {~[~(MM~)~]} {#gag;#cap logging}

Whenever that string shows up, it does capture it properly, but it still scrolls my screen one line. When I gag this line, I don't want my screen to scroll, I want it to look like it never appeared at all, and just have it logged to the other window.
Is there any way to do this?

I tried using this:

#trigger {~[~(MM~)~]} {#gag;#cap logging;#gag -1}

but it still scrolls the screen a line. I tried using this:

#trigger {~[~(MM~)~]} {#gag;#cap logging;#gag -2}

and this seems to work, except it seems to #gag lines I don't want gagged sometimes, and it also "jolts" the screen sometimes when the required text is gagged, causing it to be very difficult to read long descriptions.
Reply with quote
mr_kent
Enchanter


Joined: 10 Oct 2000
Posts: 698

PostPosted: Mon Sep 20, 2004 9:17 pm   
 
KurtDH - Try checking/unchecking the line EOR/GA in preferences.. I think that's what it is, I don't have zmud open to check atm.
Reply with quote
KurtDH
Beginner


Joined: 14 Sep 2004
Posts: 17

PostPosted: Mon Sep 20, 2004 11:13 pm   
 
It was checked. I tried unchecking it and trying everything I tried above, and it didn't fix the problem.
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Tue Sep 21, 2004 12:22 am   
 
For some reason your trigger looks like a prompt item. If it actually is and it is set to fire on prompt instead of newline then what happens is the prompt is received, the trigger fires and gags it, then when the newline is received you end up with a blank line. Assuming this is your situation make a seperate trigger for the gagging that will fire on newline.
_________________
The only good questions are the ones we have never answered before.
Search the Forums
Reply with quote
KurtDH
Beginner


Joined: 14 Sep 2004
Posts: 17

PostPosted: Tue Sep 21, 2004 3:28 am   
 
Vijilante wrote:
For some reason your trigger looks like a prompt item. If it actually is and it is set to fire on prompt instead of newline then what happens is the prompt is received, the trigger fires and gags it, then when the newline is received you end up with a blank line. Assuming this is your situation make a seperate trigger for the gagging that will fire on newline.


Can you explain what you mean by "prompt item"? I looked at the trigger I have, and it has the "newline" box checked. The "prompt" box is not checked. And, what seperate trigger should I make?
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Tue Sep 21, 2004 9:59 am   
 
By "prompt item" I meant something you would see in your prompt line. Since this doesn't seem to be the case I am out of guesses. Why don't you post a copy of the text from your mud with the trigger turned off. Then post a copy with it on, and finally post the entire trigger. Guessing just isn't fun.
_________________
The only good questions are the ones we have never answered before.
Search the Forums
Reply with quote
KurtDH
Beginner


Joined: 14 Sep 2004
Posts: 17

PostPosted: Tue Sep 21, 2004 9:14 pm   
 
I don't think posting text from the MUD will help. The problem I'm having is with scrolling, and that can't be construed with a capture from the MUD. I figured this would be a relatively easy question to answer because I thought the whole point of the GAG command was to get rid of unwanted text and unwanted scrolling. By using just #gag with no parameters, it gets rid of the text, but the unwanted scrolling is still present. Using #gag -2 gets rid of the text AND the scrolling, but it causes the screen to "bounce" for a brief second when the required text is gagged. I wouldn't have a problem with using this method except for two reasons. First, the "bouncing" effect makes it very difficult to read any long descriptions because you have to constantly find where you left off after the screen is finished "bouncing." Second, using #gag -2 sometimes gags text that I don't want gagged in the first place. For example, I'll see a string of text on my screen such as a shout, and then when the required text shows up and it is gagged, the shout text disappears from my screen. This is telling me that the trigger is also gagging lines I don't want it to gag. Does nobody know what I mean when I say the screen "bounces"? The screen is actually scrolling for a brief millisecond, but then the #gag -2 brings the screen immediately back to its original position, making it seem as if the screen is bouncing. I want to eliminate this, is it not possible?
Reply with quote
KurtDH
Beginner


Joined: 14 Sep 2004
Posts: 17

PostPosted: Tue Sep 21, 2004 9:16 pm   
 
Grelf, I'd appreciate it if we could get your input on how you ended up fixing your problem. You're having the same exact problem I'm having.
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Wed Sep 22, 2004 7:24 pm   
 
Quote:

I don't think posting text from the MUD will help.

If you knew the solution you wouldn't have to ask for help. If an expert trying to help you thinks it might be useful to see some text from the MUD, don't argue. It's not a difficult request.

#GAG -2 gags the previous two lines. Since the previous two lines have already been displayed on the screen, removing them alters the display. Sorry, but your screen is going to jump when you remove lines which have already been displayed. And sorry, but if there's information in the previous two lines which you wanted displayed it's going to be gagged anyway, since that's what you told zMUD to do!

I don't think your problem is identical to Grelf's and I doubt that his solution (which was probably the EOR/GA setting) will work for you. However, he didn't say what his solution was so I don't know for sure.

Easiest solution, totally ends screen-bounce and absolutely prevents gagging wrong text:
Remove the #GAG command from all your triggers. #CAPTURE can be used by itself.
_________________
LightBulb
Senior member

Most scripts in this forum are written for Command Line entry.
Don't even open the Settings Editor unless its use is specified or obvious.
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