Exemplo n.º 1
0
        public DieFace[] GetCurrentSet()
        {
            var set = new DieFace[ListOfDie.Count];
            int pos = 0;

            foreach (Die d in ListOfDie) {
                DieFace f = d.Face;
                if (f.FaceCharacter.CompareTo("Q") == 0) {
                    QInSet = true;
                }
                set.SetValue(f, pos++);
            }

            // Now mix the die so they change position.
            // This moves them around the board otherwise the
            // same die is in the same array position.
            Die.Roll(set);
            return set;
        }
Exemplo n.º 2
0
        public DieFace[] GetCurrentSet()
        {
            var set = new DieFace[ListOfDie.Count];
            int pos = 0;

            foreach (Die d in ListOfDie)
            {
                DieFace f = d.Face;
                if (f.FaceCharacter.CompareTo("Q") == 0)
                {
                    QInSet = true;
                }
                set.SetValue(f, pos++);
            }

            // Now mix the die so they change position.
            // This moves them around the board otherwise the
            // same die is in the same array position.
            Die.Roll(set);
            return(set);
        }
Exemplo n.º 3
0
 public void TestDieFaceConstruction()
 {
     var die = new DieFace("Qu");
     String dieFace = die.FaceCharacter;
     Assert.AreEqual("Qu", dieFace);
 }