Exemple #1
0
 static void Main(string[] args)
 {
     var tileFactory = new TileFactory();
     var tile = tileFactory.GetTile();
     bool isActive = true;
     printMenu();
     while (isActive)
     {
         printTile(tile);
         var input = Console.ReadLine();
         if (input.ToUpper() == "Q")
         {
             isActive = false;
             break;
         }
         
         try{
             Direction direction = stringConverter[input.ToUpper()];
             tile.Rotate(direction);
         }
         catch{
             Console.WriteLine("unidentified input");
         }
     }
 }
Exemple #2
0
 public HandFactory(TileFactory tileFactory)
 {
     this.tileFactory = tileFactory;
 }