my $nickserv_password = "asdlkjfhalskdjfhlasd"; $add_ons .= "+nickserv.pl" if ($add_ons !~ /nickserv/); &tell("*\cbL\cb* nickserv.pl loaded, NickServ notices will be handled"); sub hook_nickserv_notice { if ($who eq 'NickServ' and $_[1] =~ /This nickname is registered/) { &msg('NickServ',"identify $nickserv_password"); return; } } &addhook("notice","nickserv_notice");