CSharp examples for System:Math Number
Returns a random floating point number between 0 and 1 using the two seeds in a repeatable way.
using System.Text; using System.Linq; using System.Collections.Generic; using System;/*from ww w. j a v a 2s . c o m*/ public class Main{ public static float GetRandom(int xSeed, int ySeed) { Random r = new Random(xSeed ^ ySeed); return (float)r.NextDouble(); } }