Browse Source

Remove unneeded checks.

visitors
Night Owl 7 years ago
parent
commit
6b646e952a
  1. 8
      cl_dll/ammo.cpp
  2. 2
      dlls/healthkit.cpp
  3. 4
      dlls/items.cpp

8
cl_dll/ammo.cpp

@ -425,11 +425,11 @@ void WeaponsResource::SelectSlot( int iSlot, int fAdvance, int iDirection ) @@ -425,11 +425,11 @@ void WeaponsResource::SelectSlot( int iSlot, int fAdvance, int iDirection )
if( gHUD.m_fPlayerDead || gHUD.m_iHideHUDDisplay & ( HIDEHUD_WEAPONS | HIDEHUD_ALL ) )
return;
if ( !( gHUD.m_iWeaponBits & ( 1 << ( WEAPON_SUIT ) ) ) )
/*if ( !( gHUD.m_iWeaponBits & ( 1 << ( WEAPON_SUIT ) ) ) )
return;
if( ! ( gHUD.m_iWeaponBits & ~( 1 << ( WEAPON_SUIT ) ) ) )
return;
return;*/
WEAPON *p = NULL;
bool fastSwitch = CVAR_GET_FLOAT( "hud_fastswitch" ) != 0;
@ -833,8 +833,8 @@ int CHudAmmo::Draw( float flTime ) @@ -833,8 +833,8 @@ int CHudAmmo::Draw( float flTime )
int a, x, y, r, g, b;
int AmmoWidth;
if( !( gHUD.m_iWeaponBits & ( 1 << ( WEAPON_SUIT ) ) ) )
return 1;
// if( !( gHUD.m_iWeaponBits & ( 1 << ( WEAPON_SUIT ) ) ) )
// return 1;
if( ( gHUD.m_iHideHUDDisplay & ( HIDEHUD_WEAPONS | HIDEHUD_ALL ) ) )
return 1;

2
dlls/healthkit.cpp

@ -187,7 +187,7 @@ void CWallHealth::Use( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE u @@ -187,7 +187,7 @@ void CWallHealth::Use( CBaseEntity *pActivator, CBaseEntity *pCaller, USE_TYPE u
}
// if the player doesn't have the suit, or there is no juice left, make the deny noise
if( ( m_iJuice <= 0 ) || ( !( pActivator->pev->weapons & ( 1 << WEAPON_SUIT ) ) ) )
if( m_iJuice <= 0 )
{
if( m_flSoundTime <= gpGlobals->time )
{

4
dlls/items.cpp

@ -279,7 +279,7 @@ class CItemLongJump : public CItem @@ -279,7 +279,7 @@ class CItemLongJump : public CItem
return FALSE;
}
if( ( pPlayer->pev->weapons & ( 1 << WEAPON_SUIT ) ) )
// if( ( pPlayer->pev->weapons & ( 1 << WEAPON_SUIT ) ) )
{
pPlayer->m_fLongJump = TRUE;// player now has longjump module
@ -292,7 +292,7 @@ class CItemLongJump : public CItem @@ -292,7 +292,7 @@ class CItemLongJump : public CItem
EMIT_SOUND_SUIT( pPlayer->edict(), "!HEV_A1" ); // Play the longjump sound UNDONE: Kelly? correct sound?
return TRUE;
}
return FALSE;
// return FALSE;
}
};

Loading…
Cancel
Save