#####################################################
# Perl Whois for IRCOps
# sends a message to the user who /whois'ed you
#
# Thanks for DMS who helped me with this script
#####################################################

Xchat2::register("Whois"," 1.0");
Xchat2::print("Loaded Whois 1.0\n");
Xchat2::hook_server("NOTICE", "who_handler");

use warnings;
use strict;
use diagnostics;

sub who_handler {
return Xchat2::EAT_NONE if(!$_[0][8]);
my $perform = "/whois";
my $nick = $_[0][4];
my $command = $_[0][8];

if ($_[0][8] eq $perform){
Xchat2::command("notice $nick Danke for the /whois!");
Xchat2::command("notice $nick thanks for the /whois, now what do you need?");
return 0;
}
return 0;
}
