示例#1
0
        private int seed; //The seed for the generator

        #endregion Fields

        #region Constructors

        /// <summary>
        /// Constructor for the state, initialises the random number generator, creature list and drawer
        /// </summary>
        public InitialisationState()
        {
            seed = new Random().Next(1000000);
            r = new Random(seed);
            creatures = new List<Creature>();
            drawer = new SingleStringDrawer(this);
        }
示例#2
0
 /// <summary>
 /// Constructor for judging state, initialises all lists and checks to the correct values
 /// </summary>
 /// <param name="aliveCreatures">The list of alive creatures for rating</param>
 /// <param name="deadCreatures">The list of dead creatures for rating in the form of a stack</param>
 public JudgingState(List<Creature> aliveCreatures, Stack<Creature> deadCreatures)
 {
     drawer = new SingleStringDrawer(this);
     this.aliveCreatures = aliveCreatures;
     this.deadCreatures = deadCreatures;
     isJudged = false;
     isEliminated = false;
     isBred = false;
     numBred = 0;
     top = new List<Creature>();
     bottom = new List<Creature>();
     childList = new List<Creature>();
     status = "Judging Creatures...";
 }