Exemple #1
0
float Lapidem_Math::RandomFloat( float flLow, float flHigh )
{
	if( idum == 0 )
		SeedRandomNumberGenerator( 0 );

	float fl = fran1( );
	return ( fl * ( flHigh - flLow ) ) + flLow;
}
Exemple #2
0
float Com_RandomFloat( float flLow, float flHigh )
{
	float	fl;

	if( idum == 0 ) Com_SetRandomSeed(0);

	fl = fran1(); // float in [0, 1)
	return (fl * (flHigh - flLow)) + flLow; // float in [low, high)
}
Exemple #3
0
float Com_RandomFloat( float flLow, float flHigh )
{
	float	fl;

	if( idum == 0 ) SeedRandomNumberGenerator(0);

	fl = fran1(); // float in [0, 1)
	return (fl * (flHigh - flLow)) + flLow; // float in [low, high)
}
HLDS_DLLEXPORT float    RandomFloat(float arg_0_low, float arg_4_high) {

   return((fran1() * (arg_4_high - arg_0_low)) + arg_0_low);
}