示例#1
0
        public bool GetNext()
        {
            if (resultsBeforeNextTrue <= 0)
            {
                resultsBeforeNextTrue = MinMax.RandomValue();
                return(true);
            }

            resultsBeforeNextTrue--;
            return(false);
        }
示例#2
0
 public RandomChance(int min, int max)
 {
     MinMax = new BoundedInteger(min, max);
     resultsBeforeNextTrue = MinMax.RandomValue();
 }