Mercurial > maze-src
view gs_logger.rb @ 0:1eef88068f9f tip
initial commit of maze game source
| author | ferencd |
|---|---|
| date | Sun, 15 Sep 2019 11:46:47 +0200 |
| parents | |
| children |
line wrap: on
line source
require 'singleton' require 'logger' class GsLogger include Singleton def initialize @logger = Logger.new File.new('gameserver.log', 'w') end def info(*args) @logger.info(*args) end def debug(*args) @logger.debug(*args) end def warn(*args) @logger.warn(*args) end def error(*args) @logger.error(*args) end def fatal(*args) @logger.fatal(*args) end end # This will be the one and only logger in the system $LOG = GsLogger.instance
