mirror of
https://github.com/YGGverse/hlsdk-portable.git
synced 2025-02-03 02:24:28 +00:00
Merge 8903b33ef3
This commit is contained in:
parent
cabb03ad45
commit
7113204d51
@ -220,8 +220,14 @@ int CCrowbar::Swing( int fFirst )
|
|||||||
CBaseEntity *pEntity = CBaseEntity::Instance( tr.pHit );
|
CBaseEntity *pEntity = CBaseEntity::Instance( tr.pHit );
|
||||||
|
|
||||||
ClearMultiDamage();
|
ClearMultiDamage();
|
||||||
|
// If building with the clientside weapon prediction system,
|
||||||
|
// UTIL_WeaponTimeBase() is always 0 and m_flNextPrimaryAttack is >= -1.0f, thus making
|
||||||
|
// m_flNextPrimaryAttack + 1 < UTIL_WeaponTimeBase() always evaluate to false.
|
||||||
|
#ifdef CLIENT_WEAPONS
|
||||||
|
if( ( m_flNextPrimaryAttack + 1 == UTIL_WeaponTimeBase() ) || g_pGameRules->IsMultiplayer() )
|
||||||
|
#else
|
||||||
if( ( m_flNextPrimaryAttack + 1 < UTIL_WeaponTimeBase() ) || g_pGameRules->IsMultiplayer() )
|
if( ( m_flNextPrimaryAttack + 1 < UTIL_WeaponTimeBase() ) || g_pGameRules->IsMultiplayer() )
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
// first swing does full damage
|
// first swing does full damage
|
||||||
pEntity->TraceAttack( m_pPlayer->pev, gSkillData.plrDmgCrowbar, gpGlobals->v_forward, &tr, DMG_CLUB );
|
pEntity->TraceAttack( m_pPlayer->pev, gSkillData.plrDmgCrowbar, gpGlobals->v_forward, &tr, DMG_CLUB );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user