Last active
December 18, 2015 01:48
-
-
Save hintss/2886633 to your computer and use it in GitHub Desktop.
lol
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use IO::Socket; | |
$nick = "hintssomatic"; | |
$password = "<redacted>"; | |
$c = "#channel-goes-here"; | |
$sock = new IO::Socket::INET(PeerAddr=>"irc.network.net",PeerPort=>6667,Proto=>'tcp'); | |
die "phail $!:$@" unless $sock; | |
print $sock "USER hontss zack zack :Hintss-o-matic: jercogs' creation\n"; | |
print $sock "NICK hintssomatic\n"; | |
print $sock "NICKSERV identify $password\n"; | |
print $sock "MODE $nick +B\n"; | |
print $sock "JOIN $c\n"; | |
while(<$sock>){ | |
print; | |
if(s/^PING/PONG/){print $sock $_."\n"} | |
if(s/^:([^!]+)!.*PRIVMSG $c :(\x02{0,4})//){print;next unless rand(10)>6 or length($2)==4;my$n=$1;$n=~s/thatbluetextguy/blue/;print $sock int(rand(1.2))?"PRIVMSG $c :$1: lol\n":"PRIVMSG $c :lol, $n\n"} | |
if(/KICK/){print $sock "JOIN $c\n"} | |
if(/^:[^ ]* 433/){$nick.="_";print $sock "NICK $nick\n"} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment