|
Hrmm Newbie
Joined: 30 Sep 2002 Posts: 2
|
Posted: Mon Sep 30, 2002 8:37 pm
triggers, wild cards |
This is more then likely a easily answered stupid question.. But...
v6.16
How can you set up a trigger so that i'll recognize (even paste to file, which i can get that to work. ;)) the entire line. with spaces, punctuation and all
say...
Ex:
Blah blah blah 5:
Hrmm, spaces and punctuation, my trigger dunna wanna werk.
#trigger {blah blah blah (%d):$(This part)
Would like the second line to werk. seeing as how there could or could not be ,'s and the number of ,'s varies.
would rather not have 3 dozen conflicting triggers that all fight for being annoying. ;)
Thankeys. |
|
|
|
Darker GURU
Joined: 24 Sep 2000 Posts: 1237 Location: USA
|
Posted: Mon Sep 30, 2002 10:01 pm |
You can use the (undocumented?) %* wildcard that'll match anything - including special zMUD characters like # and ; - but be warned, it gets easy for someone to send you "the value is ;drop all;quit; 127 gold" and really mess with your charater. Tightly restrict use of this wildcard.
zMUD 6 Online Help: All the power you'll ever need. |
|
|
|
Hrmm Newbie
Joined: 30 Sep 2002 Posts: 2
|
Posted: Thu Oct 03, 2002 1:27 pm |
Well i tried the %* but it seems to only half werk fer me. :
it worked on chars, numbers, punct. but it didn't like spaces
any other ideas? |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Thu Oct 03, 2002 10:16 pm |
Spaces and punctuation should be no problem with a trigger of either
#TR {Blah blah blah (%d):$(*)$}
or
#TR {Blah blah blah (%d):$(%*)$}
Again, the %* captures special characters as well and can have many undesirable effects unless handled properly. |
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Thu Oct 03, 2002 10:25 pm |
quote:
Well i tried the %* but it seems to only half werk fer me. :
it worked on chars, numbers, punct. but it didn't like spaces
any other ideas?
I can attest that %* does indeed capture spaces, but since it's not apparently working for you perhaps you can provide an example?
li'l shmoe of Dragon's Gate MUD |
|
|
|
Evangelist Adept
Joined: 10 Oct 2000 Posts: 224 Location: USA
|
Posted: Thu Oct 03, 2002 10:56 pm |
Pattern; $
Command: #CAP Other
or maybe use #WINDOW Other
Either way, I think that will capture every line from the mud output, but I don't see why you would want to do that, unless I am missing something. If you want to capture all the lines, why not just use the #LOG command?
Evangelist/Pernius
www.phidar.com/phidar.html |
|
|
|
|
|