mirror of
https://github.com/rehlds/rehlds.git
synced 2024-12-27 23:25:45 +03:00
HLDS Lanucher: make sure the timer is high precision (Fixes #799)
This commit is contained in:
parent
2f2be916c2
commit
3fc9ee2f55
@ -60,10 +60,16 @@ CSys::CSys()
|
||||
WORD version = MAKEWORD(2, 0);
|
||||
WSADATA wsaData;
|
||||
WSAStartup(version, &wsaData);
|
||||
|
||||
// Request 1ms resolution for windows timer
|
||||
timeBeginPeriod(1);
|
||||
}
|
||||
|
||||
CSys::~CSys()
|
||||
{
|
||||
// Clear previously set timer resolution
|
||||
timeEndPeriod(1);
|
||||
|
||||
WSACleanup();
|
||||
sys = nullptr;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user