Advertisement
Aha2Y

Irssi POTATO SCRIPT!

Apr 2nd, 2012
548
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 2.44 KB | None | 0 0
  1. use Irssi;
  2. use Irssi::Irc;
  3. use strict;
  4. use vars qw($VERSION %IRSSI);
  5. use IO::Socket;
  6. use warnings;
  7.  
  8. $VERSION = '3.0';
  9. %IRSSI = (
  10.     authors     => 'Aha2Y alias Shiny',
  11.     contact     => 'Aha2Y@Hush.com',
  12.     name        => 'Potato',
  13.     description => 'I heard you liek Potato!',
  14.     license     => 'Aha2Y',
  15. );
  16.  
  17. sub cmd_check {
  18.     my ($text) = @_;
  19.     my ($server, $data, $nick, $mask, $target, $channel, ) =@_;
  20.     if ($data=~ /potato/i){  
  21.        my $range = 13;
  22.        my $number = int(rand($range));
  23.        if ($number == 1) { $server->command("/MSG ".$target." Fuck yeah, Potato!"); }
  24.        if ($number == 2) { $server->command("/MSG ".$target." Potato! <3"); }    
  25.        if ($number == 3) { $server->command("/MSG ".$target." OMG POTATO, YOU SAID POTATO!!!"); }
  26.        if ($number == 4) { $server->command("/MSG ".$target." Potato, They are awesome.");  }    
  27.        if ($number == 5) { $server->command("/MSG ".$target." Potato, They are awesome.");  }    
  28.        if ($number == 6) { $server->command("/MSG ".$target." It is easy to halve the potato where there is love.");    }    
  29.        if ($number == 7) { $server->command("/MSG ".$target." My idea of heaven is a great big baked potato and someone to share it with.");    }    
  30.        if ($number == 8) { $server->command("/MSG ".$target." You may be an undigested bit of beef, a blot of mustard, a crumb of cheese, a fragment of underdone potato. There's more of gravy than of grave about you, whatever you are!");   }    
  31.        if ($number == 9) { $server->command("/MSG ".$target." I've a head like a concertina, I've a tongue like a button-stick, / I've a mouth like an old potato, and I'm more than a little sick.");  }    
  32.        if ($number == 10) { $server->command("/MSG ".$target." Usually I trundle about in trainers and baggy jeans, looking about as attractive as a potato."); }    
  33.        if ($number == 11) { $server->command("/MSG ".$target." How often when they find a sage, As sweet as Socrates or Plato; They hand him hemlock for his wage, Or bake him like a sweet potato! Donald R"); }    
  34.        if ($number == 12) { $server->command("/MSG ".$target." The man who has not anything to boast of but his illustrious ancestors is like a potato, the only good belonging to him is under ground");   }    
  35.        if ($number == 13) { $server->command("/MSG ".$target." Tossed around like a hot potato");   }    
  36.    }
  37. }
  38. Irssi::signal_add_last('message public', 'cmd_check');
  39. Irssi::print("Loaded $IRSSI{name} $VERSION by Aha2Y.");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement