mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-26 06:45:08 +00:00
engine: client: implement HL25's cl_fixmodelinterpolationartifacts cvar
This commit is contained in:
parent
a29f1899d3
commit
18136e5320
@ -1228,7 +1228,13 @@ void CL_LinkPacketEntities( frame_t *frame )
|
|||||||
#else
|
#else
|
||||||
if( ent->lastmove >= cl.time )
|
if( ent->lastmove >= cl.time )
|
||||||
{
|
{
|
||||||
|
float at = ent->curstate.animtime;
|
||||||
|
|
||||||
CL_ResetLatchedVars( ent, true );
|
CL_ResetLatchedVars( ent, true );
|
||||||
|
|
||||||
|
if( cl_fixmodelinterpolationartifacts.value )
|
||||||
|
ent->latched.prevanimtime = ent->curstate.animtime = at;
|
||||||
|
|
||||||
VectorCopy( ent->curstate.origin, ent->latched.prevorigin );
|
VectorCopy( ent->curstate.origin, ent->latched.prevorigin );
|
||||||
VectorCopy( ent->curstate.angles, ent->latched.prevangles );
|
VectorCopy( ent->curstate.angles, ent->latched.prevangles );
|
||||||
|
|
||||||
|
@ -78,6 +78,8 @@ CVAR_DEFINE_AUTO( cl_trace_events, "0", FCVAR_ARCHIVE|FCVAR_CHEAT, "enable event
|
|||||||
static CVAR_DEFINE_AUTO( cl_nat, "0", 0, "show servers running under NAT" );
|
static CVAR_DEFINE_AUTO( cl_nat, "0", 0, "show servers running under NAT" );
|
||||||
CVAR_DEFINE_AUTO( hud_utf8, "0", FCVAR_ARCHIVE, "Use utf-8 encoding for hud text" );
|
CVAR_DEFINE_AUTO( hud_utf8, "0", FCVAR_ARCHIVE, "Use utf-8 encoding for hud text" );
|
||||||
CVAR_DEFINE_AUTO( ui_renderworld, "0", FCVAR_ARCHIVE, "render world when UI is visible" );
|
CVAR_DEFINE_AUTO( ui_renderworld, "0", FCVAR_ARCHIVE, "render world when UI is visible" );
|
||||||
|
static CVAR_DEFINE_AUTO( cl_maxframetime, "0", 0, "set deadline timer for client rendering to catch freezes" );
|
||||||
|
CVAR_DEFINE_AUTO( cl_fixmodelinterpolationartifacts, "1", 0, "try to fix up models interpolation on a moving platforms (monsters on trains for example)" );
|
||||||
|
|
||||||
//
|
//
|
||||||
// userinfo
|
// userinfo
|
||||||
@ -87,7 +89,6 @@ static CVAR_DEFINE_AUTO( model, "", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABL
|
|||||||
static CVAR_DEFINE_AUTO( topcolor, "0", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABLE, "player top color" );
|
static CVAR_DEFINE_AUTO( topcolor, "0", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABLE, "player top color" );
|
||||||
static CVAR_DEFINE_AUTO( bottomcolor, "0", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABLE, "player bottom color" );
|
static CVAR_DEFINE_AUTO( bottomcolor, "0", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABLE, "player bottom color" );
|
||||||
CVAR_DEFINE_AUTO( rate, "3500", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABLE, "player network rate" );
|
CVAR_DEFINE_AUTO( rate, "3500", FCVAR_USERINFO|FCVAR_ARCHIVE|FCVAR_FILTERABLE, "player network rate" );
|
||||||
static CVAR_DEFINE_AUTO( cl_maxframetime, "0", 0, "set deadline timer for client rendering to catch freezes" );
|
|
||||||
|
|
||||||
client_t cl;
|
client_t cl;
|
||||||
client_static_t cls;
|
client_static_t cls;
|
||||||
@ -2919,6 +2920,7 @@ void CL_InitLocal( void )
|
|||||||
Cvar_Get( "lastdemo", "", FCVAR_ARCHIVE, "last played demo" );
|
Cvar_Get( "lastdemo", "", FCVAR_ARCHIVE, "last played demo" );
|
||||||
Cvar_RegisterVariable( &ui_renderworld );
|
Cvar_RegisterVariable( &ui_renderworld );
|
||||||
Cvar_RegisterVariable( &cl_maxframetime );
|
Cvar_RegisterVariable( &cl_maxframetime );
|
||||||
|
Cvar_RegisterVariable( &cl_fixmodelinterpolationartifacts );
|
||||||
|
|
||||||
// these two added to shut up CS 1.5 about 'unknown' commands
|
// these two added to shut up CS 1.5 about 'unknown' commands
|
||||||
Cvar_Get( "lightgamma", "1", FCVAR_ARCHIVE, "ambient lighting level (legacy, unused)" );
|
Cvar_Get( "lightgamma", "1", FCVAR_ARCHIVE, "ambient lighting level (legacy, unused)" );
|
||||||
|
@ -700,6 +700,7 @@ extern convar_t rate;
|
|||||||
extern convar_t m_ignore;
|
extern convar_t m_ignore;
|
||||||
extern convar_t r_showtree;
|
extern convar_t r_showtree;
|
||||||
extern convar_t ui_renderworld;
|
extern convar_t ui_renderworld;
|
||||||
|
extern convar_t cl_fixmodelinterpolationartifacts;
|
||||||
|
|
||||||
//=============================================================================
|
//=============================================================================
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user