Reset flLastInterpolationAmountOnTick if client has switched to fix
This commit is contained in:
parent
4cf14a0939
commit
9bd766a1de
2 changed files with 10 additions and 8 deletions
|
@ -3176,6 +3176,7 @@ void _Host_RunFrame (float time)
|
||||||
if (!cl_interpolation_amount_fix.GetBool())
|
if (!cl_interpolation_amount_fix.GetBool())
|
||||||
{
|
{
|
||||||
g_ClientGlobalVariables.interpolation_amount = flInterpAmount;
|
g_ClientGlobalVariables.interpolation_amount = flInterpAmount;
|
||||||
|
flLastInterpolationAmountOnTick = 0.0f;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3263,6 +3264,9 @@ void _Host_RunFrame (float time)
|
||||||
cl.m_tickRemainder = host_remainder;
|
cl.m_tickRemainder = host_remainder;
|
||||||
g_ServerGlobalVariables.simTicksThisFrame = 1;
|
g_ServerGlobalVariables.simTicksThisFrame = 1;
|
||||||
cl.SetFrameTime(host_frametime);
|
cl.SetFrameTime(host_frametime);
|
||||||
|
#ifndef SWDS
|
||||||
|
CalcInterpolationAmount();
|
||||||
|
#endif
|
||||||
for ( int tick = 0; tick < numticks; tick++ )
|
for ( int tick = 0; tick < numticks; tick++ )
|
||||||
{
|
{
|
||||||
g_ServerGlobalVariables.currenttick = tick;
|
g_ServerGlobalVariables.currenttick = tick;
|
||||||
|
@ -3388,8 +3392,6 @@ void _Host_RunFrame (float time)
|
||||||
// This causes cl.gettime() to return the true clock being used for rendering (tickcount * rate + remainder)
|
// This causes cl.gettime() to return the true clock being used for rendering (tickcount * rate + remainder)
|
||||||
Host_SetClientInSimulation(false);
|
Host_SetClientInSimulation(false);
|
||||||
|
|
||||||
CalcInterpolationAmount();
|
|
||||||
|
|
||||||
#if defined(REPLAY_ENABLED)
|
#if defined(REPLAY_ENABLED)
|
||||||
// Update client-side replay history manager - called here
|
// Update client-side replay history manager - called here
|
||||||
// since interpolation_amount is set
|
// since interpolation_amount is set
|
||||||
|
@ -3449,6 +3451,8 @@ void _Host_RunFrame (float time)
|
||||||
g_ServerGlobalVariables.simTicksThisFrame = serverticks;
|
g_ServerGlobalVariables.simTicksThisFrame = serverticks;
|
||||||
g_ServerGlobalVariables.tickcount = sv.m_nTickCount;
|
g_ServerGlobalVariables.tickcount = sv.m_nTickCount;
|
||||||
|
|
||||||
|
CalcInterpolationAmount();
|
||||||
|
|
||||||
// THREADED: Run Client
|
// THREADED: Run Client
|
||||||
// -------------------
|
// -------------------
|
||||||
for ( int tick = 0; tick < clientticks; tick++ )
|
for ( int tick = 0; tick < clientticks; tick++ )
|
||||||
|
@ -3494,8 +3498,6 @@ void _Host_RunFrame (float time)
|
||||||
// This causes cl.gettime() to return the true clock being used for rendering (tickcount * rate + remainder)
|
// This causes cl.gettime() to return the true clock being used for rendering (tickcount * rate + remainder)
|
||||||
Host_SetClientInSimulation( false );
|
Host_SetClientInSimulation( false );
|
||||||
|
|
||||||
CalcInterpolationAmount();
|
|
||||||
|
|
||||||
//-------------------
|
//-------------------
|
||||||
// Run prediction if it hasn't been run yet
|
// Run prediction if it hasn't been run yet
|
||||||
//-------------------
|
//-------------------
|
||||||
|
|
4
wscript
4
wscript
|
@ -266,8 +266,8 @@ def define_platform(conf):
|
||||||
'_DLL_EXT=.so'
|
'_DLL_EXT=.so'
|
||||||
])
|
])
|
||||||
|
|
||||||
conf.define('NO_MEMOVERRIDE_NEW_DELETE', 1)
|
#conf.define('NO_MEMOVERRIDE_NEW_DELETE', 1)
|
||||||
conf.define('NO_MALLOC_OVERRIDE', 1)
|
#conf.define('NO_MALLOC_OVERRIDE', 1)
|
||||||
|
|
||||||
conf.define('MEMALLOC_SUPPORTS_ALIGNED_ALLOCATIONS', 1)
|
conf.define('MEMALLOC_SUPPORTS_ALIGNED_ALLOCATIONS', 1)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue