… | |
… | |
41 | my ($ob, $arg) = @_; |
41 | my ($ob, $arg) = @_; |
42 | |
42 | |
43 | return unless $ob->may ("command_teleport"); |
43 | return unless $ob->may ("command_teleport"); |
44 | |
44 | |
45 | cf::async { |
45 | cf::async { |
|
|
46 | $Coro::current->{desc} = "teleport $arg"; |
|
|
47 | |
46 | my $other = cf::player::find $arg |
48 | my $other = cf::player::find $arg |
47 | or return $ob->reply (undef, "$arg: no such player."); |
49 | or return $ob->reply (undef, "$arg: no such player."); |
48 | |
50 | |
49 | $ob->goto ($other->maplevel, $other->ob->x, $other->ob->y); |
51 | $ob->goto ($other->maplevel, $other->ob->x, $other->ob->y); |
50 | }; |
52 | }; |
… | |
… | |
109 | |
111 | |
110 | my @pl = $map->players; |
112 | my @pl = $map->players; |
111 | $_->enter_link for @pl; |
113 | $_->enter_link for @pl; |
112 | cf::async { |
114 | cf::async { |
113 | my $name = $map->visible_name; |
115 | my $name = $map->visible_name; |
|
|
116 | $Coro::current->{desc} = "reset $name"; |
114 | |
117 | |
115 | $map->reset; |
118 | $map->reset; |
116 | $_->leave_link for @pl; |
119 | $_->leave_link for @pl; |
117 | |
120 | |
118 | $ob->reply (undef, "$name was reset."); |
121 | $ob->reply (undef, "$name was reset."); |