#!/usr/bin/perl package Help; use strict; use warnings; use OpenBSD::Pledge; use OpenBSD::Unveil; my %conf = %main::conf; my $chans = $conf{chans}; my $teamchans = $conf{teamchans}; my @teamchans = split /[,\s]+/m, $teamchans; my $staff = $conf{staff}; my $terms = $conf{terms}; my $time = "600"; main::cbind("pub", "-", "help", \&help); main::cbind("msg", "-", "help", \&help); main::cbind("pub", "-", "request", \&help); sub init { } sub help { my ($bot, $nick, $host, $hand, @args) = @_; my ($chan, $text); my $msg = <<"EOF"; $terms To request a free bouncer, type !bnc . For example, !bnc john john\@example.com. To request a free shell account, type !shell . For example, !shell john john\@example.com. EOF #To request a free email account, type !email . For example, !email john john\@example.com. #To request a free VPN account, type !vpn . For example, !vpn john john\@example.com. if (main::isstaff($bot, $nick)) { $msg .= <<"EOF"; To delete a bouncer, type !bnc delete To verify a captcha, type !bnc captcha To recreate cloneuser, type !bnc cloneuser To get a list of usernames that match IPs, type !regex ips To get a list of IPs that match usernames, type !regex users To regex search znc.log and output to the terminal, type !regex To delete a shell account, type !shell delete To verify a captcha, type !shell captcha EOF #To get a list of usernames that match IPs, type !shell regex ips #To get a list of IPs that match usernames, type !shell regex users #To regex search znc.log and output to the terminal, type !shell regex } if (@args == 2) { ($chan, $text) = ($args[0], $args[1]); if ($chans =~ $chan) { main::putserv($bot, "PRIVMSG $chan :$nick: Please see private message."); } } else { $text = $args[0]; } main::putserv($bot, "PRIVMSG $nick :$msg"); foreach my $chan (@teamchans) { main::putservlocalnet($bot, "PRIVMSG $chan :Help *$nick* on ".$bot->{name}); } } 1; # MUST BE LAST STATEMENT IN FILE