… | |
… | |
12 | "/pup_land/nurnberg/apartment/main" => [ 300, "nürnberg", "sauerkraut"], |
12 | "/pup_land/nurnberg/apartment/main" => [ 300, "nürnberg", "sauerkraut"], |
13 | "/pup_land/lone_town/apartment/groundfloor" => [50000, "lone town", "looney"], |
13 | "/pup_land/lone_town/apartment/groundfloor" => [50000, "lone town", "looney"], |
14 | "/brest/apartments/brest_town_house" => [30000, "brest", "brecht"], |
14 | "/brest/apartments/brest_town_house" => [30000, "brest", "brecht"], |
15 | ); |
15 | ); |
16 | |
16 | |
17 | sub teleport { |
|
|
18 | my ($pl, $map, $x, $y) = @_; |
|
|
19 | |
|
|
20 | my $portal = cf::object::new "exit"; |
|
|
21 | |
|
|
22 | $portal->slaying ($map); |
|
|
23 | $portal->stats->hp ($x); |
|
|
24 | $portal->stats->sp ($y); |
|
|
25 | $portal->apply ($pl->ob); |
|
|
26 | $portal->destroy; |
|
|
27 | } |
|
|
28 | |
|
|
29 | # we have to special case some special cases :) |
17 | # we have to special case some special cases :) |
30 | sub reject_entry { |
18 | sub reject_entry { |
31 | my ($pl) = @_; |
19 | my ($pl) = @_; |
32 | |
20 | |
33 | cf::override; |
21 | cf::override; |
34 | |
22 | |
35 | $pl->goto_map ("/world/world_105_115", 2, 34) |
23 | $pl->goto ("/world/world_105_115", 2, 34) |
36 | unless |
24 | unless |
37 | $pl->ob->map |
25 | $pl->ob->map |
38 | && !$pl->ob->map->{path}{user_rel}; |
26 | && !$pl->ob->map->{path}{user_rel}; |
39 | } |
27 | } |
40 | |
28 | |