Page 1 of 1

game.log(data [, for_player])

Posted: Sun Mar 25, 2018 11:34 pm
by betrok
I want to add some custom stuff into factorio log.
Sure, it's possible to use write_file, but
  • there will be two separate contexts
  • no way to obtain real timestamp(whole factorio output is redirecting to system journal in my case, so there is current time)
  • file will be reopened every write

Re: game.log(data [, for_player])

Posted: Mon Mar 26, 2018 12:54 am
by Rseding91
You can already do that with "log(...)"

Re: game.log(data [, for_player])

Posted: Mon Mar 26, 2018 2:09 pm
by betrok
Oh, thanks, that works.
But as far i can see there is no mentions in api documentation.