Beispiel #1
0
 private static void FillHandWithTiles(ref QueueOfTiles TileQueue, ref string PlayerTiles, int MaxHandSize)
 {
     while (PlayerTiles.Length <= MaxHandSize)
     {
         PlayerTiles = PlayerTiles + TileQueue.Remove();
         TileQueue.Add();
     }
 }
Beispiel #2
0
        private static string GetStartingHand(QueueOfTiles TileQueue, int StartHandSize)
        {
            string Hand = "";

            for (int Count = 0; Count < StartHandSize; Count++)
            {
                Hand = Hand + TileQueue.Remove();
                TileQueue.Add();
            }
            return(Hand);
        }
Beispiel #3
0
        private static void AddEndOfTurnTiles(ref QueueOfTiles TileQueue, ref string PlayerTiles, string NewTileChoice, string Choice)
        {
            int NoOfEndOfTurnTiles = 0;

            if (NewTileChoice == "1")
            {
                NoOfEndOfTurnTiles = Choice.Length;
            }
            else if (NewTileChoice == "2")
            {
                NoOfEndOfTurnTiles = 3;
            }
            else
            {
                NoOfEndOfTurnTiles = Choice.Length + 3;
            }
            for (int Count = 0; Count < NoOfEndOfTurnTiles; Count++)
            {
                PlayerTiles = PlayerTiles + TileQueue.Remove();
                TileQueue.Add();
            }
        }