Im looking for a script that will display a certain message in a channel on command, however i only want it to work on 1 channel, and no other channels the bot is in.
anyone got something like that?
Code: Select all
# set here the single channel name for output (or a space delimited string of channel names)
set vMsgChannels "#whatever"
# set here the command to output a message
set vMsgCommand !msg
# set here the message to output
set vMsgText "this is what I want to output on command"
bind PUB - $vMsgCommand pMsgProc
proc pMsgProc {nick uhost hand channel txt} {
global vMsgChannels vMsgText
if {[lsearch -exact [split [string tolower $vMsgChannels]] [string tolower $channel]] != -1} {
putserv "PRIVMSG $channel :$vMsgText"
}
return 0
}