* Move GetTickCount() hacks to porting.h and replace by a real call to SDL_GetTicks().
[matthijs/ABM2.git] / ABM2 / porting.h
index 02d7c33238569604ba45baaa28a82c8242cee9a5..6ee3006e2ceaf96d45cd1c2a57b49c5641311689 100644 (file)
@@ -1,3 +1,6 @@
+#if !defined(AFX_PORTING_H__90C3FE42_3400_4978_8BC5_7D905F3C8E63__INCLUDED_)
+#define AFX_PORTING_H__90C3FE42_3400_4978_8BC5_7D905F3C8E63__INCLUDED_
+
 #ifndef WIN32
        #define vsprintf_s vsnprintf
        #define sprintf_s snprintf
@@ -7,3 +10,10 @@
        #define BYTE unsigned char
        #define DWORD unsigned int
 #endif // !WIN32
+
+#ifdef WITH_SDL
+       #include <SDL/SDL.h>
+       #define GetTickCount SDL_GetTicks
+#endif // WITH_SDL
+
+#endif // !defined(AFX_PORTING_H__90C3FE42_3400_4978_8BC5_7D905F3C8E63__INCLUDED_)