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


Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  General
. . -> [Subject]  Trigger help

Trigger help

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


Posted by Supermanjnk   (1 post)  [Biography] bio
Date Thu 09 Oct 2003 02:35 AM (UTC)
Message
Alright, I'm trying to set up a trigger to mass message people with tells. Right now i haev the trigger set up as

* Race *

first astrik is level, second star is name. I have it send the command to the mud
tell %2 (message)
This is where it gets messed up. It includes their title with this line, so say i wanted to message all Elves. I would type who elf and it would give me a list and send a tell to all elves with my message. and it would look like this.
You tell Mistle 'The wandering elf test'
you tell Caytiera 'the dark suductress test'

I want to have it say
You tell Mistle 'test'
you tell Caytiera 'test'

Is there anyway i can keep the second astrik from including the rest of the title.

Thanks.
[Go to top] top

Posted by Flannel   USA  (1,230 posts)  [Biography] bio
Date Reply #1 on Thu 09 Oct 2003 02:59 AM (UTC)

Amended on Thu 09 Oct 2003 03:00 AM (UTC) by Flannel

Message
You need to update your trigger, or do some scripting, either way, you need to make it so what youre sending is only the first word of their name, and not their title.

Easiest way would probably be:
Assuming Race is literal "race" and not the race itself, although, itd be easily modifiable.
^(\d+) race (\w+)( .*)?$

Thats assuming the title is optional, if it isnt... you can do this:
^(\d+) race (\w+) (.*)$

This would replace your old trigger, You just need to check "regular expression" on the trigger menu

~Flannel

Messiah of Rose
Eternity's Trials.

Clones are people two.
[Go to top] top

Posted by Poromenos   Greece  (1,037 posts)  [Biography] bio
Date Reply #2 on Thu 09 Oct 2003 12:03 PM (UTC)
Message
Or you could do ^(.*?) Race ([A-Za-z]+) (.*?)$, should work too

Vidi, Vici, Veni.
http://porocrom.poromenos.org/ Read it!
[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.


8,831 views.

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.

[Home]


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 HostDash]