|
Scarn Apprentice
Joined: 24 Jul 2005 Posts: 137
|
Posted: Mon Jul 23, 2012 7:34 pm
#IF firing on multiple things. |
How can I get an #IF to fire on multiple words, in my example I have a trigger to remove 'tells' from the game window by a #GAG and paste them into the communications window. However the shopkeepers in the game also use the tell command, so to stop spam I don't want it to fire on those... this is what I have already:
Code: |
<?xml version="1.0" encoding="ISO-8859-1" ?>
<cmud>
<trigger priority="34621" regex="true" copy="yes">
<pattern>(.+) tells you:</pattern>
<value>#IF %1=(Eamon|Laryn|Alexa|Alazif|Zaban\Samir) {} {#VAR Reply %1;#CAPTURE TellHist;#GAG}</value>
</trigger>
</cmud>
|
I know I am doing something right because the trigger doesn't fire when Eamon sends me a tell (The first in the list), I think I just need to study my special characters, but I can't find any documents about them. |
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4690 Location: Pensacola, FL, USA
|
Posted: Mon Jul 23, 2012 8:58 pm |
you want %ismember for that
#IF (%ismember(%1, "Eamon|Laryn|Alexa|Alazif|Zaban|Samir")) {} {#VAR Reply %1;#CAPTURE TellHist;#GAG} |
|
_________________ Discord: Shalimarwildcat |
|
|
|
Scarn Apprentice
Joined: 24 Jul 2005 Posts: 137
|
Posted: Mon Jul 23, 2012 9:12 pm |
Perfect, thanks!
|
|
|
|
|
|