mirror of
https://github.com/alliedmodders/hl2sdk.git
synced 2025-09-19 20:16:10 +08:00
Fixed conflict between min/max macros and std::min/max when using GCC >= 4.2.
This commit is contained in:
@ -2641,7 +2641,7 @@ int CBaseCombatCharacter::GiveAmmo( int iCount, int iAmmoIndex, bool bSuppressSo
|
||||
return 0;
|
||||
|
||||
int iMax = GetAmmoDef()->MaxCarry(iAmmoIndex);
|
||||
int iAdd = min( iCount, iMax - m_iAmmo[iAmmoIndex] );
|
||||
int iAdd = MIN( iCount, iMax - m_iAmmo[iAmmoIndex] );
|
||||
if ( iAdd < 1 )
|
||||
return 0;
|
||||
|
||||
@ -2854,7 +2854,7 @@ void RadiusDamage( const CTakeDamageInfo &info, const Vector &vecSrc, float flRa
|
||||
{
|
||||
// Even the tiniest explosion gets attention. Don't let the radius
|
||||
// be less than 128 units.
|
||||
float soundRadius = max( 128.0f, flRadius * 1.5 );
|
||||
float soundRadius = MAX( 128.0f, flRadius * 1.5 );
|
||||
|
||||
CSoundEnt::InsertSound( SOUND_COMBAT | SOUND_CONTEXT_EXPLOSION, vecSrc, static_cast<int>(soundRadius), 0.25, info.GetInflictor() );
|
||||
}
|
||||
|
Reference in New Issue
Block a user