Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- use Irssi;
- use strict;
- use utf8;
- use vars qw($VERSION %IRSSI);
- $VERSION = "1.02";
- %IRSSI = (
- authors => 'GentilBoulet',
- name => 'houou',
- description => 'Simple *houhou* script',
- license => 'Public Domain',
- changed => 'Tue Mar 02 14:38:20 CEST 2012'
- );
- my %times=();
- sub is_houhou_speaking {
- my ($server, $msg, $nick, $address, $target) = @_;
- my $houhou="houhou";
- my $match = 0;
- while($msg=~/($houhou)/gi)
- {
- $match++;
- }
- if ($match>0)
- {
- if($target=~/ensiie|anidb|anidb-dev|arise/)
- {
- return 0;
- }
- {
- return houhou($server,$nick,$target);
- }
- }
- return 0;
- }
- sub houhou {
- my ($server, $nick, $target) = @_;
- my $output="*houhou*";
- $server->command('msg '.$target.' '.$output);
- return 0;
- }
- Irssi::signal_add("message public", "is_houhou_speaking");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement