Page 1 of 1

Logging to a file in Windows

Posted: 30 Sep 2008 11:48
by Zutty
Hi all,

Is it possible to send all the NoAI logging output to a file in Windows. I have tried "> log.txt", "2>> log.txt", and "> log.txt 2>&1" and nothing seems to work.

I'm using Vista Home Premium x64.

I ask because I never seem to have enough space to scroll-back in any of the logging windows, and it would be nice to be able to debug easily without having to spend ages trying to recreate bugs just to see the output.

Thanks very much,
George

Re: Logging to a file in Windows

Posted: 02 Oct 2008 14:27
by glx
You need to convert OpenTTD to a console app first.
You can do this using http://devs.openttd.org/~glx/convert.zip.

Re: Logging to a file in Windows

Posted: 02 Oct 2008 15:43
by Zutty
Oh fantastic! That worked perfectly. For reference, after converting the EXE I used the following...

Code: Select all

openttd.exe -g -d ai=5 2>> ai_log.txt
Thanks very much glx. :bow: