Description: just like MSGM, except it's triggered by things said
on a channel instead of things /msg'd to the bot. The mask is
matched against the channel name followed by the text and can
contain wildcards. Also, if a line triggers a PUB bind, it will not
trigger a PUBM bind.
Module: irc
A suggestion when creating more complex patterns, use the % wildcard to match any channel instead of *.
The reason for this is that * matches 0 or more characters, including whitespaces, while % will match 1 word. The advantage of this usage becomes apparent when dealing with more complex patterns such as this:
#We try to catch anything that starts with !hello world
bind pub "* !hello world*" pubm:hello
#Looks good eh? until we realize it will also trigger on "Blah !hello world", which we did not want!
bind pub "% !hello world*" pubm:hello
#Now, this works as intended. It'll only trigger when the text starts with "!hello world", not whenever it's anywhere in the text.
This could also be extended to only trigger in local channels (&channel) by using "&% !hello world*", and so on...