Page 1 of 1

Trigger for Tells received. (But exclude NPC Tells)

Posted: Thu Feb 05, 2015 7:32 pm
by Settun
I'm trying to adapt viewtopic.php?f=7&t=80 (the But NOT comparison)

to create a trigger that will work when a Player sends a tell, (SoAndSo tells you, )
but at the same time exclude occurences whereby
<NPC Tells shouldn't fire the trigger>
(a guild banker tells you, )
or (Parcel Delivery Liason tells you, )
or (a personal banker tells you, )
or (General Supply Merchant tells you, )
or (Teleportation Assistant tells you, )

{S1}(?!{Teleportation Assistant|Parcel Delivery Liaison|a personal banker|a guild banker|General Supply Merchant|Teleportation Assistant}) tells you, '

Unfortunately the above trigger match doesn't seem to exclude the ones I have in the list. Anyone have an idea how I can solve this?

Thanks
Settun

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Sat Feb 07, 2015 2:00 pm
by Sirene
^((?!Teleportation Assistant|Parcel Delivery Liaison|a personal banker|a guild banker|General Supply Merchant).)*tells you, '

This trigger works but it's a pretty expensive operation to exclude specific NPCs.

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Sat Feb 07, 2015 6:01 pm
by Settun
Thank you very very much Sirene.

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Fri Mar 06, 2015 8:36 pm
by Sirene
I figured out a more efficient way of doing this -

Search Text:

^((?<!\s).)*tells you, '

This will do a negative lookbehind for \s (a space) and exclude tells from anyone or anything with a space in it's name (NPCs with more than one word in their name)

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Fri Jul 24, 2015 2:52 pm
by adetia
i was previously using a {s} so that when i was tabbed out or in another window, it would flash an tell me who was sending a tell.
i wonder if there is a way to combine that with this, so that it wouldnt trigger off of npcs with spaces in their name, but would tell me who was sending the tell.
anybody know?

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Sun Jul 26, 2015 2:18 am
by Sirene
Search Text: ^(?<char>\w+)((?<!\s).)*tells you, '
Display Text: ${char}

Fancier:

Search Text: ^(?<char>\w+)((?<!\s).)*tells you, '{s}'
Display Text: ${char} tells {c}: {s}

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Wed Jul 29, 2015 4:00 pm
by adetia
awesome, thank you!

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Fri Jul 31, 2015 2:59 pm
by Quuq
Sirene wrote:Search Text: ^(?<char>\w+)((?<!\s).)*tells you, '
Display Text: ${char}

Fancier:

Search Text: ^(?<char>\w+)((?<!\s).)*tells you, '{s}'
Display Text: ${char} tells {c}: {s}
Since you're using ^ and \w+, you don't need the negative lookbehind for whitespace.

Here's the tell trigger I use:

Search Text:

Code: Select all

^(?!PETNAME1|PETNAME2)((?:\w+\.)?\w+) (?:tells|told) you, '
It also works for cross server tells and intra-server tells sent via the chat server. If you play classes with custom-named pets, you can put their names in the lookahead to keep them from setting off your tell trigger. Otherwise, just delete the (?!PETNAME1|PETNAME2) stuff to make the trigger more efficient. The name of the person sending you the tell is captured in group one (i.e., use ${1} in your output).

If you'd like to capture the message or name the group that captures the name of the sender as well, you can modify it as Sirene has done in the fancier version.

Unfortunately, there are still a few NPCs who make it through filters like this. The Rank II spell NPC in Feerrott: The Dream is one example that comes to mind.

Re: Trigger for Tells received. (But exclude NPC Tells)

Posted: Tue Aug 11, 2015 9:49 pm
by Xata Takushi
If you are a mage and don't want triggers to fire from tells from your pet in response to commands, I added some additional filtering. Hopefully, unless I messed it up, it still filters out tells from 2 name NPCs as well.

Not sure what kind of performance impact this would have.

^((?<!\s)[^\n\v\f\r])*tells you, (?!'Attacking |'I am unable |'By your command, master.')