ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/maps/perl/map-prefetch.ext
(Generate patch)

Comparing deliantra/maps/perl/map-prefetch.ext (file contents):
Revision 1.11 by root, Fri Aug 25 13:24:05 2006 UTC vs.
Revision 1.12 by root, Sun Aug 27 15:23:30 2006 UTC

111 my $exit = $MAP_EXITS{$map->path} ||= find_exits $map; 111 my $exit = $MAP_EXITS{$map->path} ||= find_exits $map;
112 prefetch map => $_ for @$exit; 112 prefetch map => $_ for @$exit;
113} 113}
114 114
115cf::attach_to_players prio => -900, 115cf::attach_to_players prio => -900,
116 on_enter => sub { 116 on_map_change => sub {
117 my ($pl) = @_; 117 my ($pl, $old, $new) = @_;
118 118
119 prefetch_map $pl->ob->map; 119 prefetch_map $new;
120 }, 120 },
121; 121;
122 122
123if (0) { #test# 123if (0) { #test#
124# prefetch a few players/second 124# prefetch a few players/second

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines