|
|
|
@ -71,10 +71,13 @@ sub on_msg {
|
|
|
|
|
|
|
|
|
|
if ($nick ne $mynick && ($text =~ /pudding/ || $text =~ /brums/)) {
|
|
|
|
|
print Dumper($event);
|
|
|
|
|
sleep(rand(30));
|
|
|
|
|
print "=> $conn->{channel}\n";
|
|
|
|
|
$conn->privmsg($conn->{channel}, "$nick: " . pudding);
|
|
|
|
|
$conn->{lastpudding} = time();
|
|
|
|
|
my $wait = 300;
|
|
|
|
|
if (time() > $conn->{lastpudding} + $wait) {
|
|
|
|
|
sleep(rand(30));
|
|
|
|
|
print "=> $conn->{channel}\n";
|
|
|
|
|
$conn->privmsg($conn->{channel}, "$nick: " . pudding);
|
|
|
|
|
$conn->{lastpudding} = time();
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
my $wait = 24 * 3600 * (0.5 + 0.5*rand());
|
|
|
|
|
my (undef, undef, undef, undef, undef, undef, $wday) = localtime(time());
|
|
|
|
|