mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 03:24:56 +08:00
engine: platform: sdl: set requested timer delay in units of 100ns according to the documentation
This commit is contained in:
@@ -79,11 +79,13 @@ void Win32_Shutdown( void )
|
||||
|
||||
qboolean Win32_NanoSleep( int nsec )
|
||||
{
|
||||
const LARGE_INTEGER ts = { -nsec };
|
||||
LARGE_INTEGER ts;
|
||||
|
||||
if( !g_waitable_timer )
|
||||
return false;
|
||||
|
||||
ts.QuadPart = { -nsec / 100 };
|
||||
|
||||
if( !SetWaitableTimer( g_waitable_timer, &ts, 0, NULL, NULL, FALSE ))
|
||||
{
|
||||
CloseHandle( g_waitable_timer );
|
||||
|
||||
Reference in New Issue
Block a user