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

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  General
. . -> [Subject]  WHO trigger...
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

WHO trigger...

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


Posted by Farawaymandy   (1 post)  [Biography] bio
Date Mon 08 Aug 2005 10:02 AM (UTC)
Message
Ok.
I have absolutely no idea what I'm doing... basically, I want to write a trigger so that when I type 'who' to get a connected players list for my MUSH, it won't write the list to my logs.

My who list, for clarification, looks as follows:

Player Name On For Idle Doing
Sofika 01:42 0s
1 Player logged in, 22 record, no maximum.

Any help would be greatly appreciated!
[Go to top] top

Posted by Poromenos   Greece  (1,037 posts)  [Biography] bio
Date Reply #1 on Mon 08 Aug 2005 11:39 AM (UTC)
Message
You can create a multiline trigger and set it to "omit from log file", but I haven't messed with multiline much and I can't help you more there.

Vidi, Vici, Veni.
http://porocrom.poromenos.org/ Read it!
[Go to top] top

Posted by Scotty   Australia  (13 posts)  [Biography] bio
Date Reply #2 on Tue 09 Aug 2005 11:31 AM (UTC)
Message
Can you post a sample of the output WHO gives you on your particular mu*?
[Go to top] top

Posted by Scotty   Australia  (13 posts)  [Biography] bio
Date Reply #3 on Tue 09 Aug 2005 12:24 PM (UTC)
Message
Heh - that'll teach me to read forums when I'm half asleep.

I don't line multiline triggers over more than a couple of lines, so I go with this kind of approach:

To me the logical approach SEEMS to be that you would have a trigger which fires on the first line:

Player Name On For Idle Doing

get THAT trigger to enable another trigger which matches any line: ie *

and then have a 3rd trigger which matches

* Player logged in, * record, no maximum.

which disables the 2nd trigger. Have all set to omit from logfile and it's covered.

eg:

The first trigger:

<triggers>
<trigger
enabled="y"
match="^Player Name On For Idle Doing$"
omit_from_log="y"
regexp="y"
send_to="12"
sequence="100"
>
<send>world.EnableTriggerGroup "whogag", 1</send>
</trigger>
</triggers>

The second trigger:

<triggers>
<trigger
enabled="y"
match="^(.*)$"
name="whogag"
omit_from_log="y"
regexp="y"
sequence="100"
>
</trigger>
</triggers>


The third trigger:
<triggers>
<trigger
enabled="y"
match="^(.*?) Players logged in\, (.*?) record\, no maximum\.$"
omit_from_log="y"
regexp="y"
send_to="12"
sequence="100"
>
<send>world.EnableTriggerGroup "whogag", 0</send>
</trigger>
</triggers>


A quick test worked for me
[Go to top] top

Posted by Poromenos   Greece  (1,037 posts)  [Biography] bio
Date Reply #4 on Tue 09 Aug 2005 08:50 PM (UTC)
Message
Yeah, that's the alternative, and I prefer it to multiline 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.


5,513 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 FutureQuest]