From aa421a2d56c5bdfb467eddaba478e5aef04bbce4 Mon Sep 17 00:00:00 2001 From: William Heimbigner Date: Tue, 26 Apr 2011 17:42:42 +0000 Subject: Lots of added stuff. Don't know whatall. --- modules/services.pl | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'modules/services.pl') diff --git a/modules/services.pl b/modules/services.pl index 3ec9436..0a0c3d5 100644 --- a/modules/services.pl +++ b/modules/services.pl @@ -11,6 +11,7 @@ sub new sub doServices { my ($self, $conn, $event) = @_; + my $i = 5; if ($event->{from} eq 'NickServ!NickServ@services.') { print "NickServ: $event->{args}->[0]\n"; @@ -20,7 +21,10 @@ sub doServices { } elsif ( $event->{args}->[0] =~ /^You are now identified/ ) { - $conn->join($_) foreach ( @{$::settings->{autojoins}} ); + foreach my $x ( @{$::settings->{autojoins}} ) { + $conn->schedule($i, sub { $conn->join($x); }); + $i = $i + 6; + } } elsif ($event->{args}->[0] =~ /has been killed$/ ) { @@ -42,6 +46,10 @@ sub doServices { { $conn->join($1); } + elsif ( $event->{args}->[0] =~ /You are not authorized to perform this operation/ ) + { + $::oq->clean(); + } } } -- cgit v1.2.3