… | |
… | |
75 | # this handler notifies the player of new mail |
75 | # this handler notifies the player of new mail |
76 | cf::player->attach ( |
76 | cf::player->attach ( |
77 | on_login => sub { |
77 | on_login => sub { |
78 | my ($pl) = @_; |
78 | my ($pl) = @_; |
79 | |
79 | |
80 | my $cnt = @{ $pl->{ip_mails} }; |
80 | my $cnt = @{ $pl->{ipo_mails} }; |
81 | |
81 | |
82 | if ($cnt == 1) { |
82 | if ($cnt == 1) { |
83 | $pl->ob->message ("You got one mail."); |
83 | $pl->ob->message ("You got one mail."); |
84 | } elsif ($cnt > 1) { |
84 | } elsif ($cnt > 1) { |
85 | $pl->ob->message ("You got $cnt mails."); |
85 | $pl->ob->message ("You got $cnt mails."); |
… | |
… | |
224 | cf::async { |
224 | cf::async { |
225 | $Coro::current->{desc} = "ipo send"; |
225 | $Coro::current->{desc} = "ipo send"; |
226 | |
226 | |
227 | my $storage = cf::map::find ("/planes/IPO_storage"); |
227 | my $storage = cf::map::find ("/planes/IPO_storage"); |
228 | unless ($storage) { |
228 | unless ($storage) { |
229 | $who->reply ($npc, "Sorry, our package delivery service is currently in strike. Please come back later."); |
229 | $who->reply ($npc, "Sorry, our package delivery service is currently on strike. Please come back later."); |
230 | return 1; |
230 | return 1; |
231 | } |
231 | } |
232 | $storage->load; |
232 | $storage->load; |
233 | |
233 | |
234 | my $cnt; |
234 | my $cnt; |