--- deliantra/server/ext/town_portal.ext 2008/04/30 13:44:41 1.3 +++ deliantra/server/ext/town_portal.ext 2009/11/29 17:41:07 1.6 @@ -24,7 +24,7 @@ or return cf::override 0; } - my $portal = $spell->other_arch->instantiate; + my $portal = $spell->other_arch->instance; $portal->name ("Magic Portal to nearest Town"); $portal->slaying ($map); @@ -45,7 +45,7 @@ on_apply => sub { my ($self, $who) = @_; - $who->{town_portal} = ["$who->map", $who->x, $who->y, $self->uuid]; + $who->{town_portal} = [$who->map->as_string, $who->x, $who->y, $self->uuid]; }, ; @@ -59,6 +59,8 @@ $who->goto ($map, $x, $y, sub { my ($map) = @_; + $map->load; # make sure the map is loaded + if (grep $_->uuid eq $uuid, $map->at ($x, $y)) { $who->reply (undef, "The town portal weaves its magic... and after a short moment, you return to the magic portal.", cf::NDI_NAVY);