Skip to content
Extraits de code Groupes Projets
Valider 0bea5cc0 rédigé par ElTata's avatar ElTata
Parcourir les fichiers

fix itemsum() import & removed example.pm

parent 4b386a07
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
package Irpg::Example;
=head1 NAME
Irpg/Example.pm - Example of commands implementation.
=head1 SYNOPSIS
use Irpg::Example;
=head1 DESCRIPTION
This module does not provide anything useful, it exists
solely for the sake of an explicit example.
=cut
use strict;
use warnings;
use Irpg::Irc qw(:interaction);
=head1 FUNCTION command_function_x
Take an input and sends back
"XXX $msg XXX" to the author
=cut
sub command_function_x {
my ($auth, $source, @msg) = @_;
privmsg("XXX ".join(' ', @msg)." XXX", $auth);
}
=head1 FUNCTION command_function_y
Take an input and sends back
"YYY $msg YYY" to the source (chan or author)
=cut
sub command_function_x {
my ($auth, $source, @msg) = @_;
privmsg("YYY ".join(' ', @msg)." YYY", $source);
}
our $commands = {
xxx => {
ref => \&command_function_x,
adm => 0,
prv => 1,
pub => 0
},
yyy => {
ref => \&command_function_y,
adm => 0,
prv => 0,
pub => 1
}
};
1;
......@@ -5,7 +5,7 @@ use warnings;
use Irpg::Utils qw(:text);
use Irpg::Irc qw(:interaction);
use Exporter qw(import);
our @EXPORT = qw(&challenge_opp &collision_fight &team_battle);
our @EXPORT = qw(&challenge_opp &collision_fight &team_battle &itemsum);
our @EXPORT_OK = qw(itemsum);
my $primnick_ref;
......
......@@ -4,6 +4,7 @@ use strict;
use warnings;
use Irpg::Utils qw(:data :text);
use Irpg::Irc qw(:interaction @queue);
use Irpg::Fight;
use Irpg::Main;
my $opts;
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter