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

Comparing deliantra/server/ext/map-scheduler.ext (file contents):
Revision 1.40 by root, Sat Jul 28 14:32:21 2007 UTC vs.
Revision 1.41 by root, Fri Aug 24 01:12:11 2007 UTC

76# delete $map->{active}; 76# delete $map->{active};
77# } 77# }
78 if ($map->should_reset) { 78 if ($map->should_reset) {
79 $map->reset; 79 $map->reset;
80 } elsif ($map->in_memory == cf::MAP_IN_MEMORY) { 80 } elsif ($map->in_memory == cf::MAP_IN_MEMORY) {
81 my $max_idle = cf::clamp +(cf::lerp $cf::LOADAVG, $SWAP_LOAD1, $SWAP_LOAD2, $SWAP_TIMEOUT, 0), 0, $SWAP_TIMEOUT; 81 my $max_idle = cf::clamp +(cf::lerp $cf::LOADAVG, $SWAP_LOAD1, $SWAP_LOAD2, $SWAP_TIMEOUT, $cf::TICK * 1.5),
82 $cf::TICK * 1.5, $SWAP_TIMEOUT;
82 83
83 if ($map->last_access + $max_idle <= $cf::RUNTIME && !$map->players) { 84 if ($map->last_access + $max_idle <= $cf::RUNTIME && !$map->players) {
84 $map->swap_out; 85 $map->swap_out;
85 } elsif ($map->{last_save} + $SAVE_TIMEOUT <= $cf::RUNTIME) { 86 } elsif ($map->{last_save} + $SAVE_TIMEOUT <= $cf::RUNTIME) {
86 $map->save; 87 $map->save;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines