ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/lib/cf.pm
(Generate patch)

Comparing deliantra/server/lib/cf.pm (file contents):
Revision 1.513 by root, Mon Apr 12 05:22:38 2010 UTC vs.
Revision 1.514 by root, Mon Apr 12 17:13:36 2010 UTC

399} 399}
400 400
401=item cf::periodic $interval, $cb 401=item cf::periodic $interval, $cb
402 402
403Like EV::periodic, but randomly selects a starting point so that the actions 403Like EV::periodic, but randomly selects a starting point so that the actions
404get spread over timer. 404get spread over time.
405 405
406=cut 406=cut
407 407
408sub periodic($$) { 408sub periodic($$) {
409 my ($interval, $cb) = @_; 409 my ($interval, $cb) = @_;
587 reset_signals; 587 reset_signals;
588 &$cb 588 &$cb
589 }, @args; 589 }, @args;
590 590
591 wantarray ? @res : $res[-1] 591 wantarray ? @res : $res[-1]
592}
593
594sub objinfo {
595 (
596 "counter value" => cf::object::object_count,
597 "objects created" => cf::object::create_count,
598 "objects destroyed" => cf::object::destroy_count,
599 "freelist size" => cf::object::free_count,
600 "allocated objects" => cf::object::objects_size,
601 "active objects" => cf::object::actives_size,
602 )
592} 603}
593 604
594=item $coin = coin_from_name $name 605=item $coin = coin_from_name $name
595 606
596=cut 607=cut

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines