forked from UNLOZE/sm-plugins
Update LagCompensation with CS:GO Windows release
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
#include <dhooks>
|
||||
#include <clientprefs>
|
||||
|
||||
#define PLUGIN_VERSION "1.0"
|
||||
#define PLUGIN_VERSION "1.0.1"
|
||||
|
||||
#define SetBit(%1,%2) ((%1)[(%2) >> 5] |= (1 << ((%2) & 31)))
|
||||
#define ClearBit(%1,%2) ((%1)[(%2) >> 5] &= ~(1 << ((%2) & 31)))
|
||||
@@ -366,9 +366,10 @@ public void OnMapStart()
|
||||
{
|
||||
if(IsClientInGame(client))
|
||||
{
|
||||
OnClientPutInServer(client);
|
||||
OnClientConnected(client);
|
||||
if(AreClientCookiesCached(client))
|
||||
OnClientCookiesCached(client);
|
||||
OnClientPutInServer(client);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -398,13 +399,8 @@ public void OnMapEnd()
|
||||
g_bCleaningUp = true;
|
||||
}
|
||||
|
||||
public void OnClientPutInServer(int client)
|
||||
public void OnClientConnected(int client)
|
||||
{
|
||||
if(g_iLerpTime == -1)
|
||||
{
|
||||
g_iLerpTime = FindDataMapInfo(client, "m_fLerpTime");
|
||||
}
|
||||
|
||||
g_bDisableLagComp[client] = false;
|
||||
g_iDisableLagComp[client] = 0;
|
||||
}
|
||||
@@ -419,6 +415,14 @@ public void OnClientCookiesCached(int client)
|
||||
g_bDisableLagComp[client] = false;
|
||||
}
|
||||
|
||||
public void OnClientPutInServer(int client)
|
||||
{
|
||||
if(g_iLerpTime == -1)
|
||||
{
|
||||
g_iLerpTime = FindDataMapInfo(client, "m_fLerpTime");
|
||||
}
|
||||
}
|
||||
|
||||
public void OnClientDisconnect(int client)
|
||||
{
|
||||
g_bDisableLagComp[client] = false;
|
||||
|
||||
Reference in New Issue
Block a user