Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- use Irssi;
- use Irssi::Irc;
- use strict;
- use vars qw($VERSION %IRSSI);
- use IO::Socket;
- use warnings;
- $VERSION = '3.0';
- %IRSSI = (
- authors => 'Aha2Y alias Shiny',
- contact => 'Aha2Y@Hush.com',
- name => 'EliteBNC',
- description => 'EliteBNC Module for IRSSI.',
- license => 'Aha2Y',
- changes => "v3.0 - Fixed critical freeze bug."
- );
- sub cmd_check {
- my ($text) = @_;
- my ($server, $data, $nick, $mask, $target, $channel, ) =@_;
- if ($data=~/^!test/){
- my ($alpha) = IO::Socket::INET(PeerAddr=>'alpha.elitebnc.net',PeerPort=>'1337',Proto=>'tcp');
- my ($alphacheck) = 'status';
- if($alpha)
- {
- my ($alphacheck) = 'online';
- }
- else
- {
- my ($alphacheck) = 'offline';
- }
- $server->command("/MSG ".$target." Alpha: ".$alphacheck."");
- }
- }
- Irssi::signal_add_last('message public', 'cmd_check');
- Irssi::print("Loaded $IRSSI{name} $VERSION by Aha2Y.");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement