mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-01-19 03:57:14 +01:00
Fix the 64bit build on windows by making sure the _WIN32_WINNT macro has the proper value to include GetTickCount64() and also default to regular GetTickCount() on 32bit as the 64bit placeholder.
This commit is contained in:
parent
099c388b00
commit
d1ae2fd7e8
@ -10,6 +10,13 @@
|
||||
|
||||
// ------------------------------------------------------------------------------------------------
|
||||
#ifdef SQMOD_OS_WINDOWS
|
||||
|
||||
#if defined(_SQ64) && (_WIN32_WINNT < 0x0600)
|
||||
// We need this for the GetTickCount64() function
|
||||
#undef _WIN32_WINNT
|
||||
#define _WIN32_WINNT 0x0600
|
||||
#endif // _SQ64
|
||||
|
||||
#include <windows.h>
|
||||
#else
|
||||
#include <time.h>
|
||||
@ -83,7 +90,7 @@ Int64 Chrono::GetEpochTimeMicro()
|
||||
#ifndef _SQ64
|
||||
Int64 GetTickCount64()
|
||||
{
|
||||
return 0ULL; // Should we fallback to 32 bit?
|
||||
return static_cast< Int64 >(GetTickCount()); // Fall-back to 32 bit?
|
||||
}
|
||||
#endif // _SQ64
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user