Glare.Box4i.Random C# (CSharp) Method

Random() public method

Get a random position within the box.
public Random ( Random rng, Vector4i &result ) : void
rng System.Random
result Vector4i
return void
        public void Random(Random rng , out Vector4i result)
        {
            result.X = (Int32)(rng.NextDouble() * (Max.X - Min.X) + Min.X);
                                    result.Y = (Int32)(rng.NextDouble() * (Max.Y - Min.Y) + Min.Y);
                                    result.Z = (Int32)(rng.NextDouble() * (Max.Z - Min.Z) + Min.Z);
                                    result.W = (Int32)(rng.NextDouble() * (Max.W - Min.W) + Min.W);
                                return;
        }

Same methods

Box4i::Random ( Random rng ) : Vector4i