* Use nick() for initial NICK.

* Parse Numeric:433.
* Added %botnick for storing the bot's nick.
* Renamed mode() to cmode() in API::IRC's @EXPORT_OK
This commit is contained in:
Elijah Perrault committed 2011-01-20 20:59:50 -07:00
1 parent ccc66f5a4e
commit 43bcb86d90
4 files changed
+18 -6

No files matched your search

+13 -2
View File
@@ -7,15 +7,16 @@ package Parser::IRC;
use strict;
use warnings;
use API::Std qw(conf_get);
use API::IRC qw(cjoin);
use API::IRC qw(cjoin nick);
# Raw parsing hash.
our %RAWC = (
'001' => \&num001,
'433' => \&num433,
);
# Variables for various functions.
our (%got_001);
our (%got_001, %botnick);
# Parse raw data.
sub _parse
@@ -68,4 +69,14 @@ sub num001
}
}
# Parse: Numeric:433
sub num433
{
my ($svr, undef) = @_;
if (defined $botnick{$svr}) {
nick($svr, $botnick{$svr}."_");
}
}
1;