[Home] [Downloads] [Search] [Help/forum]

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  General
. . -> [Subject]  gagging multiple line triggers
Home  |  Users  |  Search  |  FAQ
Register forum user name
Forgotten password?

gagging multiple line triggers

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Posted by Jimbob   (4 posts)  [Biography] bio
Date Mon 23 Feb 2009 01:21 PM (UTC)
If I have a multiline trigger like the following

Is it possible to gat both line1 and line2?
[Go to top] top

Posted by Worstje   Netherlands  (899 posts)  [Biography] bio
Date Reply #1 on Mon 23 Feb 2009 02:42 PM (UTC)

Amended on Mon 23 Feb 2009 07:03 PM (UTC) by Worstje

Yes it is possible. Although I am not sure what you mean 'get both line1 and line2.'

If you mean you want them captured as %1 and %2, make it a regular expression like... ^(Line1)\n(Line2)\z

If the problem is getting the trigger to work, you may just need to turn multi-line on, and set lines to match to 2.

Edit: oi, I need to read better. I totally didn't read (or realize the contents of) the subject line. :(
[Go to top] top

Posted by WillFa   USA  (525 posts)  [Biography] bio
Date Reply #2 on Mon 23 Feb 2009 06:02 PM (UTC)
Gagging them isn't as straight forward as just the check box "Omit from Output".

You could script out a call to "DeleteLines" and remove the last 2 lines on match with the one mutliline trigger.

Alternatively, 2 triggers would probably be easier.
omit_from_output = 'y'
<send> EnableTrigger "GagLine2" </send>


<send>EnableTrigger ("GagLine2", false) </send>
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum

[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at FutureQuest]