Browse Source

Merge branch 'master' into bshift

bshift
Andrey Akhmichin 4 years ago
parent
commit
c99a220be2
  1. 16
      cl_dll/ev_hldm.cpp
  2. 8
      cl_dll/hl/hl_weapons.cpp
  3. 2
      dlls/monsterstate.cpp
  4. 2
      dlls/weapons.cpp

16
cl_dll/ev_hldm.cpp

@ -948,13 +948,13 @@ void EV_FireGauss( event_args_t *args )
0.1f, 0.1f,
m_fPrimaryFire ? 1.0f : 2.5f, m_fPrimaryFire ? 1.0f : 2.5f,
0.0f, 0.0f,
m_fPrimaryFire ? 128.0f : flDamage, (m_fPrimaryFire ? 128.0f : flDamage) / 255.0f,
0, 0,
0, 0,
0, 0,
m_fPrimaryFire ? 255 : 255, (m_fPrimaryFire ? 255 : 255) / 255.0f,
m_fPrimaryFire ? 128 : 255, (m_fPrimaryFire ? 128 : 255) / 255.0f,
m_fPrimaryFire ? 0 : 255 (m_fPrimaryFire ? 0 : 255) / 255.0f
); );
} }
else else
@ -965,13 +965,13 @@ void EV_FireGauss( event_args_t *args )
0.1f, 0.1f,
m_fPrimaryFire ? 1.0f : 2.5f, m_fPrimaryFire ? 1.0f : 2.5f,
0.0f, 0.0f,
m_fPrimaryFire ? 128.0f : flDamage, (m_fPrimaryFire ? 128.0f : flDamage) / 255.0f,
0, 0,
0, 0,
0, 0,
m_fPrimaryFire ? 255 : 255, (m_fPrimaryFire ? 255 : 255) / 255.0f,
m_fPrimaryFire ? 128 : 255, (m_fPrimaryFire ? 128 : 255) / 255.0f,
m_fPrimaryFire ? 0 : 255 (m_fPrimaryFire ? 0 : 255) / 255.0f
); );
} }

8
cl_dll/hl/hl_weapons.cpp

@ -325,9 +325,13 @@ void CBasePlayerWeapon::ItemPostFrame( void )
{ {
if( ( m_fInReload ) && ( m_pPlayer->m_flNextAttack <= 0.0f ) ) if( ( m_fInReload ) && ( m_pPlayer->m_flNextAttack <= 0.0f ) )
{ {
#if 0 // FIXME, need ammo on client to make this work right #if 1
// complete the reload. // complete the reload.
int j = min( iMaxClip() - m_iClip, m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] ); ItemInfo itemInfo;
memset( &itemInfo, 0, sizeof( itemInfo ) );
GetItemInfo( &itemInfo );
int j = Q_min( itemInfo.iMaxClip - m_iClip, m_pPlayer->m_rgAmmo[m_iPrimaryAmmoType] );
// Add them to the clip // Add them to the clip
m_iClip += j; m_iClip += j;

2
dlls/monsterstate.cpp

@ -66,7 +66,7 @@ void CBaseMonster::RunAI( void )
// IDLE sound permitted in ALERT state is because monsters were silent in ALERT state. Only play IDLE sound in IDLE state // IDLE sound permitted in ALERT state is because monsters were silent in ALERT state. Only play IDLE sound in IDLE state
// once we have sounds for that state. // once we have sounds for that state.
if( ( m_MonsterState == MONSTERSTATE_IDLE || m_MonsterState == MONSTERSTATE_ALERT ) && RANDOM_LONG( 0, 99 ) == 0 && !( pev->flags & SF_MONSTER_GAG ) ) if( ( m_MonsterState == MONSTERSTATE_IDLE || m_MonsterState == MONSTERSTATE_ALERT ) && RANDOM_LONG( 0, 99 ) == 0 && !( pev->spawnflags & SF_MONSTER_GAG ) )
{ {
IdleSound(); IdleSound();
} }

2
dlls/weapons.cpp

@ -598,7 +598,7 @@ BOOL CanAttack( float attack_time, float curtime, BOOL isPredicted )
} }
else else
{ {
return ( attack_time <= 0.0f ) ? TRUE : FALSE; return ( (static_cast<int>(::floor(attack_time * 1000.0f)) * 1000.0f) <= 0.0f) ? TRUE : FALSE;
} }
} }

Loading…
Cancel
Save