diff options
| author | 2012-02-08 04:48:46 +0000 | |
|---|---|---|
| committer | 2012-02-08 04:48:46 +0000 | |
| commit | bb894285dae60d829bbb470643d0c0e9a3c4b50d (patch) | |
| tree | ccb6d0324d1505a1e296cb16d127e49a34fe131f /modules/log.pl | |
| parent | 6ba39c3f02bdb37ab9b168e76265ad45b9c7a68c (diff) | |
added DCC chat capabilities, plus sigalarm to self-die. DCC chat is still very broken
Diffstat (limited to 'modules/log.pl')
| -rw-r--r-- | modules/log.pl | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/modules/log.pl b/modules/log.pl index 7bd69a1..581f70b 100644 --- a/modules/log.pl +++ b/modules/log.pl @@ -43,11 +43,20 @@ sub logg $_ = "-$event->{nick}- $event->{args}->[0]" if $event->{type} eq 'notice'; $_ = "*** $event->{nick} sets mode: " . join(" ",@{$event->{args}}) if $event->{type} eq 'mode'; $_ = "*** $event->{nick} changes topic to \"$event->{args}->[0]\"" if $event->{type} eq 'topic'; + my $nostamp = $_; $_ = strftime($cfg->{timefmt}, @time) . $_ . "\n"; my $line = $_; open(FH, $path) or die "Can't open $path: $!"; print FH $line; close(FH); + if (defined($::spy{$chan})) { + my $spy = $::spy{$chan}; + print $spy $chan .": " . $nostamp . "\n"; + } + if (defined($::spy{lc $event->{nick}})) { + my $spy = $::spy{lc $event->{nick}}; + print $spy $chan .": " . $nostamp . "\n"; + } # $_ >> io($path); } } |
