remove sleep hack and add a smarter game speed limiter that takes the games performance into account
This commit is contained in:
parent
2d4841beda
commit
0e6d415f63
4 changed files with 34 additions and 12 deletions
|
@ -199,8 +199,8 @@ HRESULT __stdcall ddraw_surface_Blt(IDirectDrawSurfaceImpl *This, LPRECT lpDestR
|
|||
SwitchToThread();
|
||||
}
|
||||
|
||||
if (ddraw->sleep > 0)
|
||||
Sleep(ddraw->sleep);
|
||||
if (ddraw->ticklength > 0)
|
||||
LimitGameTicks();
|
||||
}
|
||||
|
||||
return DD_OK;
|
||||
|
@ -366,8 +366,8 @@ HRESULT __stdcall ddraw_surface_Flip(IDirectDrawSurfaceImpl *This, LPDIRECTDRAWS
|
|||
SwitchToThread();
|
||||
}
|
||||
|
||||
if (ddraw->sleep > 0)
|
||||
Sleep(ddraw->sleep);
|
||||
if (ddraw->ticklength > 0)
|
||||
LimitGameTicks();
|
||||
}
|
||||
|
||||
return DD_OK;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue