X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=sys_sdl.c;h=9c7571671333698f9a4ea910f1e529bb9b809e41;hp=bb2364946286aba5870f15f0f0d63e16409f2d87;hb=93ed14242647c8f0ca1ed8d5e3f3238e70671f07;hpb=e120cda4dbc83afd8dd92dba66e55f96a640e234 diff --git a/sys_sdl.c b/sys_sdl.c index bb236494..9c757167 100644 --- a/sys_sdl.c +++ b/sys_sdl.c @@ -195,13 +195,11 @@ char *Sys_ConsoleInput(void) return NULL; } -void Sys_Sleep(void) +void Sys_Sleep(int milliseconds) { -#ifdef WIN32 - Sleep (1); -#else - usleep(1); -#endif + if (milliseconds < 1) + milliseconds = 1; + SDL_Delay(milliseconds); } int SDL_main (int argc, char *argv[])