velmarin wrote:In Linux Robocide compiles fine, how Marek said.
My experience with Linux is very little, and try if I am able to cross compile.
Looking forward to see how works the engine by Daniel White.
To compile on Windows with Intel Compiler, I had to add the "strtok_r" and "getline", relocate any statement, ect.
The problem comes with "GetTimeMS"
I've added an implementation of strtok_r and removed the usage of getline, these should no longer be a problem. Fixing GetTimeMS (which is now GetTimeUS as it happens) is a bit more tricky. I haven't spent much time looking but so far I've struggled to find a suitably precise Windows replacement to gettimeofday - without man pages its hard to find direct and precise answers (and answers which aren't for C++...). Perhaps I'll take a look at how other engines do it.
I have also fixed the bug in ucioption.c, thank you Tony for pointing it out.
Daniel White wrote:I've struggled to find a suitably precise Windows replacement to gettimeofday - without man pages its hard to find direct and precise answers (and answers which aren't for C++...). Perhaps I'll take a look at how other engines do it.
Daniel
For precise timing on Windows you can use
QueryPerformanceCounter()
and
QueryPerformanceFrequency()