ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/ext/schmorp-irc.ext
(Generate patch)

Comparing deliantra/server/ext/schmorp-irc.ext (file contents):
Revision 1.6 by root, Wed Apr 25 23:53:50 2007 UTC vs.
Revision 1.7 by root, Fri Apr 27 00:49:58 2007 UTC

19 undef $CON; 19 undef $CON;
20} 20}
21 21
22sub do_notice { 22sub do_notice {
23 my ($msg) = @_; 23 my ($msg) = @_;
24
25 utf8::encode $msg;
24 $CON->send_chan ($BOTCHAN, NOTICE => $msg, $BOTCHAN) 26 $CON->send_chan ($BOTCHAN, NOTICE => $msg, $BOTCHAN)
25 if $CON; 27 if $CON;
26} 28}
27 29
28sub users { 30sub users {
32} 34}
33 35
34sub handle_fcmd { 36sub handle_fcmd {
35 my ($name, $me, $msg) = @_; 37 my ($name, $me, $msg) = @_;
36 38
39 utf8::decode $msg;
40
37 if ($msg eq "!who") { 41 if ($msg eq "!who") {
38 $CON->send_chan ($BOTCHAN, NOTICE => $_, $BOTCHAN) 42 do_notice $_
39 for ext::commands::who_listing (); 43 for ext::commands::who_listing ();
40 44
41 } elsif ($msg =~ /^\!tell/) { 45 } elsif ($msg =~ /^\!tell/) {
42 my (undef, $target, $tmsg) = split / /, $msg, 3; 46 my (undef, $target, $tmsg) = split / /, $msg, 3;
43 47
53 57
54 $other->ob->message ("$name/$me tells you: $tmsg"); 58 $other->ob->message ("$name/$me tells you: $tmsg");
55 $other->ob->{ext_last_tell} = "$name/$me"; 59 $other->ob->{ext_last_tell} = "$name/$me";
56 } 60 }
57 } else { 61 } else {
58 $CON->send_chan ($BOTCHAN, NOTICE => "$me: What do you want to tell $target?", cf::NDI_UNIQUE); 62 do_notice "$me: What do you want to tell $target?";
59 } 63 }
60 64
61 } 65 }
62 } 66 }
63} 67}

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines