Trigger on everything except...

Posted by ErockMahan on Tue 27 Nov 2007 11:37 PM — 4 posts, 19,893 views.

#0
I have a very basic trigger that will trigger on the following line:

* tells you *

and appends this to a notepad:

%1 told you %2


But there is one person (and only one person) that sends me tells that I do NOT want to append. Is there any way it can be omitted or squelched or whatever?
USA #1
Sure, just do an ifcheck on %1 against the player name you don't want the tell from.
Australia Forum Administrator #2
You can also do it with a regular expression. See:

http://www.mushclient.com/regexp

Scroll down to the part about "negative lookbehind assertions".
#3
For those of you who want to know how I did it:

<triggers>
<trigger
enabled="y"
keep_evaluating="y"
match="(.+)(?&lt;!asper) tells you (.*?)$"
name="stuff"
regexp="y"
send_to="12"
sequence="100"
>
<send>AppendToNotepad "stuff", vbcrlf
AppendToNotepad "stuff", "%1 tells you %2"
AppendToNotepad "stuff", vbcrlf</send>
</trigger>
</triggers>

Now Jasper will not activate the trigger.