Skip to content

Commit 2e7cc6e

Browse files
committed
1 parent 05f1e1b commit 2e7cc6e

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

src/game/client/tf/vgui/tf_playermodelpanel.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@
3434

3535
DECLARE_BUILD_FACTORY( CTFPlayerModelPanel );
3636

37+
#ifdef BDSBASE
38+
#define SCENE_LERP_TIME 0.1f
39+
#endif
40+
3741
char g_szSceneTmpName[256];
3842

3943
static bool IsTauntItem( GameItemDefinition_t *pItemDef, const int iTeam, const int iClass, const char **ppSequence = NULL, const char **ppRequiredItem = NULL, const char **ppScene = NULL )
@@ -466,7 +470,11 @@ CChoreoScene *LoadSceneForModel( const char *filename, IChoreoEventCallback *pCa
466470

467471
if ( bSetEndTime )
468472
{
473+
#ifdef BDSBASE
474+
*flSceneEndTime += SCENE_LERP_TIME; // give time for lerp to idle pose
475+
#else
469476
*flSceneEndTime += 0.1f; // give time for lerp to idle pose
477+
#endif
470478
}
471479
}
472480

@@ -2295,10 +2303,17 @@ void CTFPlayerModelPanel::SetupFlexWeights( void )
22952303
// Advance time
22962304
if ( m_flLastTickTime < FLT_EPSILON )
22972305
{
2306+
#ifdef BDSBASE
2307+
m_flLastTickTime = m_RootMDL.m_MDL.m_flTime - SCENE_LERP_TIME;
2308+
#else
22982309
m_flLastTickTime = m_RootMDL.m_MDL.m_flTime - 0.1;
2310+
#endif
22992311
}
23002312

23012313
m_flSceneTime += (m_RootMDL.m_MDL.m_flTime - m_flLastTickTime);
2314+
#ifdef BDSBASE
2315+
m_flSceneTime = Max(m_flSceneTime, -SCENE_LERP_TIME);
2316+
#endif
23022317
m_flLastTickTime = m_RootMDL.m_MDL.m_flTime;
23032318

23042319
if ( m_flSceneEndTime > FLT_EPSILON && m_flSceneTime > m_flSceneEndTime )

0 commit comments

Comments
 (0)