line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Bot::Cobalt::Plugin::Silly::BoneEasy; |
2
|
|
|
|
|
|
|
$Bot::Cobalt::Plugin::Silly::BoneEasy::VERSION = '0.031002'; |
3
|
1
|
|
|
1
|
|
942
|
use strictures 2; |
|
1
|
|
|
|
|
6
|
|
|
1
|
|
|
|
|
32
|
|
4
|
|
|
|
|
|
|
|
5
|
1
|
|
|
1
|
|
582
|
use Bot::Cobalt::Common; |
|
1
|
|
|
|
|
149196
|
|
|
1
|
|
|
|
|
5
|
|
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
5839
|
use Bone::Easy; |
|
1
|
|
|
|
|
4706
|
|
|
1
|
|
|
|
|
234
|
|
8
|
|
|
|
|
|
|
|
9
|
1
|
|
|
1
|
0
|
355
|
sub new { bless [], shift } |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub Cobalt_register { |
12
|
0
|
|
|
0
|
0
|
|
my ($self, $core) = splice @_, 0, 2; |
13
|
|
|
|
|
|
|
|
14
|
0
|
|
|
|
|
|
$core->plugin_register( $self, 'SERVER', |
15
|
|
|
|
|
|
|
'public_cmd_pickup' |
16
|
|
|
|
|
|
|
); |
17
|
|
|
|
|
|
|
|
18
|
0
|
|
|
|
|
|
$core->log->info("Loaded"); |
19
|
|
|
|
|
|
|
|
20
|
0
|
|
|
|
|
|
return PLUGIN_EAT_NONE |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub Cobalt_unregister { |
24
|
0
|
|
|
0
|
0
|
|
my ($self, $core) = splice @_, 0, 2; |
25
|
|
|
|
|
|
|
|
26
|
0
|
|
|
|
|
|
$core->log->info("Unloaded"); |
27
|
|
|
|
|
|
|
|
28
|
0
|
|
|
|
|
|
return PLUGIN_EAT_NONE |
29
|
|
|
|
|
|
|
} |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub Bot_public_cmd_pickup { |
32
|
0
|
|
|
0
|
0
|
|
my ($self, $core) = splice @_, 0, 2; |
33
|
|
|
|
|
|
|
|
34
|
0
|
|
|
|
|
|
my $msg = ${ $_[0] }; |
|
0
|
|
|
|
|
|
|
35
|
0
|
|
|
|
|
|
my $context = $msg->context; |
36
|
|
|
|
|
|
|
|
37
|
0
|
|
|
|
|
|
my $resp = pickup; |
38
|
|
|
|
|
|
|
|
39
|
0
|
|
|
|
|
|
my $channel = $msg->channel; |
40
|
|
|
|
|
|
|
|
41
|
0
|
0
|
|
|
|
|
$core->send_event( 'send_message', |
42
|
|
|
|
|
|
|
$context, |
43
|
|
|
|
|
|
|
$channel, |
44
|
|
|
|
|
|
|
$resp |
45
|
|
|
|
|
|
|
) if $resp; |
46
|
|
|
|
|
|
|
|
47
|
0
|
|
|
|
|
|
return PLUGIN_EAT_ALL |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
1; |
51
|
|
|
|
|
|
|
__END__ |