home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.madoka.org
/
2014.12.ftp.madoka.org.tar
/
ftp.madoka.org
/
pub
/
plum
/
2.x
/
plum2_15_2.lzh
/
module
/
auto
/
answer.plm
next >
Wrap
Text File
|
1997-11-21
|
2KB
|
75 lines
# <!-- -*- perl -*-
# $Id: answer.plm,v 2.3 1997/11/22 02:59:50 hasegawa Exp $
# copyright (c)1997 pupu_j <hasegawa@agusa.nuie.nagoya-u.ac.jp>
package auto_answer;
$_ = 'auto_answer';
sub ss_privmsg {
local($serverno, $prefix, $cmd, $chan, $msg) = @_;
local($userno, $nick, $str, $answer);
$userno = $'userno[$serverno];
$nick = &'prefix($prefix);
foreach $reply (&'property($userno, 'reply')) {
($str, $answer) = split(/\s+/, $reply, 2);
next unless $str eq $msg;
if ($chan =~ /^[\#\&\+\-]/) {
&'s_print($serverno, '', 'PRIVMSG', $chan, $answer);
} else {
&'s_print($serverno, '', 'PRIVMSG', $nick, $answer);
}
foreach $cno (&'array($'clientlist)) {
next unless $'avail[$cno];
next unless $'userno[$cno] == $userno;
if ($chan =~ /^[\#\&\+\-]/) {
&'c_print($cno, &'user($cno), 'PRIVMSG', $chan, $answer);
} else {
&'c_print($cno, &'user($cno), 'PRIVMSG', $nick, $answer);
}
}
last;
}
return ($prefix, $cmd, $chan, $msg);
}
__END__
--><!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<HTML><HEAD><TITLE> auto/answer.plm </TITLE></HEAD><BODY>
$B%*%s%i%$%s%I%-%e%a%s%H(B
<HR><H3> $BL>A0(B </H3>
auto/answer.plm - $BFCDj$NH/8@$KH?1~$7$FBP1~$9$kH/8@$r$9$k(B
<HR><H3> $B@bL@(B </H3>
$BFCDj$N%a%C%;!<%8$,H/8@$5$l$k$H!"$=$l$KBP1~$9$k%a%C%;!<%8$rH/8@$7$^$9!#(B
$B$9$Y$F$N%a%C%;!<%8$KH?1~$9$k$?$a!"F1$8H/8@$r2?EY$b7+$jJV$92DG=@-$,$"$j$^$9!#(B
<HR><H3> $B%W%m%Q%F%#(B </H3>
<DL>
<DT> auto.answer.reply* $B%a%C%;!<%8(B $B%a%C%;!<%8(B
<DD> $BH/8@$H$=$l$KBP$9$kJV;v$r;XDj$7$^$9!#(B
$BH?1~$9$kH/8@$K$O6uGr$r4^$a$k$3$H$O$G$-$^$;$s!#(B
</DL>
<HR><H3> $B@_DjNc(B </H3>
<PRE>
+ auto/answer.plm
auto.answer.reply: $B$3$s$K$A$O(B $B$3$s$K$A$O!A!y(B
auto.answer.reply: $B$3$s$P$s$O(B $B$3$s$P$s$O!A!y(B
</PRE>
$B!V$3$s$K$A$O!W!"!V$3$s$P$s$O!W$H$$$&H/8@$,$"$C$?$H$-$K!"(B
$B$=$l$>$l!V$3$s$K$A$O!A!y!W!"!V$3$s$P$s$O!A!y!W$HH/8@$7$^$9!#(B
</BODY></HTML>