示例#1
0
        static void Main(string[] args)
        {
            Robot robot = new Robot();
            Grid grid = new Grid(5, 5, robot);
            BaseView view = new ConsoleGridView(grid);

            //Can use one of these controllers
           // BaseRemoteControl remote = new ConsoleKeyboardController(view);
            BaseRemoteControl remote = new ConsoleCommandController(view);

            remote.OnError += step_OnError;
            remote.TurnOn();

        }
 public void InitialiseTestBed()
 {
     robot = new Robot();
     grid = new Grid(5, 5, robot);
     view = new ConsoleGridView(grid);
     controller = new ConsoleCommandController(view);
        // controller.TurnOn();
 }