mirror of
https://github.com/nillerusr/source-engine.git
synced 2025-04-05 08:05:10 +00:00
game: More More More max()->MAX() and min()->MIN()
This commit is contained in:
parent
d330813654
commit
a6d7b5d63b
@ -124,8 +124,8 @@ void CHudDemomanChargeMeter::OnTick( void )
|
||||
|
||||
if ( flChargeBeginTime > 0 )
|
||||
{
|
||||
float flTimeCharged = max( 0, gpGlobals->curtime - flChargeBeginTime );
|
||||
float flPercentCharged = min( 1.0, flTimeCharged / flChargeMaxTime );
|
||||
float flTimeCharged = MAX( 0, gpGlobals->curtime - flChargeBeginTime );
|
||||
float flPercentCharged = MIN( 1.0, flTimeCharged / flChargeMaxTime );
|
||||
|
||||
m_pChargeMeter->SetProgress( flPercentCharged );
|
||||
}
|
||||
@ -135,4 +135,4 @@ void CHudDemomanChargeMeter::OnTick( void )
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -948,7 +948,7 @@ void CTFFlameEntity::OnCollide( CBaseEntity *pOther )
|
||||
flMultiplier = RemapValClamped( flDistance, tf_flamethrower_maxdamagedist.GetFloat()/2, tf_flamethrower_maxdamagedist.GetFloat(), 1.0, 0.25 );
|
||||
}
|
||||
float flDamage = m_flDmgAmount * flMultiplier;
|
||||
flDamage = max( flDamage, 1.0 );
|
||||
flDamage = MAX( flDamage, 1.0 );
|
||||
if ( tf_debug_flamethrower.GetInt() )
|
||||
{
|
||||
Msg( "Flame touch dmg: %.1f\n", flDamage );
|
||||
|
Loading…
Reference in New Issue
Block a user