System.Random.NextFloat()

Here are the examples of the csharp api System.Random.NextFloat() taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

6 Examples 7

19 Source : Rand.cs
with MIT License
from ChevyRay

public static float Float()
        {
            lock (randLock)
                return rand.NextFloat();
        }

19 Source : TerraConfig.cs
with Apache License 2.0
from CyanCode

public static float NextFloat(this Random random, float min, float max) {
            return random.NextFloat() * (max - min) + min;
        }

19 Source : Rand.cs
with MIT License
from NoelFB

public static float NextFloat(this Random random, float max)
        {
            return random.NextFloat() * max;
        }

19 Source : Rand.cs
with MIT License
from NoelFB

public static float NextFloat(this Random random, float min, float max)
        {
            return min + random.NextFloat() * (max - min);
        }

19 Source : RandomExtension.cs
with MIT License
from stride3d

public static Vector3 NextVector3(this Random random)
        {
            return new Vector3(random.NextFloat(), random.NextFloat(), random.NextFloat());
        }

19 Source : RandomExtension.cs
with MIT License
from stride3d

public static Thickness NextThickness(this Random random, float leftFactor, float topFactor, float backFactor, float rightFactor, float bottomFactor, float frontFactor)
        {
            return new Thickness(
                random.NextFloat() * leftFactor, random.NextFloat() * topFactor, random.NextFloat() * backFactor,
                random.NextFloat() * rightFactor, random.NextFloat() * bottomFactor, random.NextFloat() * frontFactor);
        }