main.rb
rbmud-0.2/main.rb · 397 B
From the archive RbMUD-0.2.tar.bz2
Download the archive « Back to the archive contents
#!/usr/bin/env ruby
# $Revision: 1.13 $
# $Date: 2003/12/04 22:18:34 $
# $Author: jefus $
require "lib/system"
System.start
while true
sleep 60
connections = $system.server.connections.size
if connections == 0
Logger.log("No connections.")
elsif connections == 1
Logger.log("One connection: #{$system.server.connections[0]}")
else
Logger.log("#{connections} connections.")
end
end