home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.madoka.org
/
2014.12.ftp.madoka.org.tar
/
ftp.madoka.org
/
pub
/
plum
/
1.x
/
plum11.lzh
/
plum11
/
noisybot.plm
< prev
next >
Wrap
Text File
|
1997-08-28
|
723b
|
26 lines
package noisybot;
$_ = 'noisybot';
sub ss_privmsg {
local($serverno, $prefix, $cmd, $chan, $msg) = @_;
local($org, $word, $string);
$org = &'euc($msg);
foreach $message (&'property($'userno[$serverno], 'noisybot')) {
($word, $string) = split(/\s+/, $message, 2);
$word = &'euc($word);
next unless index($org, $word) != -1;
if ($string) {
&'s_print($serverno, '', 'PRIVMSG', $chan, $string);
foreach $clientno (&'array($'clientlist)) {
next unless $'userno[$clientno] == $'userno[$serverno];
next unless $'avail[$clientno];
&'c_print($clientno, &'user($clientno), 'PRIVMSG', $chan, $string);
}
}
last;
}
return ($prefix, $cmd, $chan, $msg);
}