dungeon_crawler

diff prototype/src/timer.cc @ 69:45172d087ebe

fixed some windows compatibility crap fixed a terrible stack overrun in psys (TODO: remember to fix in libpsys too)
author John Tsiombikas <nuclear@member.fsf.org>
date Sun, 07 Oct 2012 03:42:44 +0200
parents 862461b686f4
children
line diff
     1.1 --- a/prototype/src/timer.cc	Sun Oct 07 02:05:11 2012 +0300
     1.2 +++ b/prototype/src/timer.cc	Sun Oct 07 03:42:44 2012 +0200
     1.3 @@ -1,3 +1,4 @@
     1.4 +#ifndef _MSC_VER
     1.5  #include <chrono>
     1.6  #include "timer.h"
     1.7  
     1.8 @@ -16,3 +17,11 @@
     1.9  	auto dur = steady_clock::now() - start_time;
    1.10  	return duration_cast<milliseconds>(dur).count();
    1.11  }
    1.12 +#else
    1.13 +#include <Windows.h>
    1.14 +
    1.15 +unsigned long get_time_msec(void)
    1.16 +{
    1.17 +	return GetTickCount();
    1.18 +}
    1.19 +#endif
    1.20 \ No newline at end of file