示例#1
0
 static void Control(int port)
 {
     var client = new Level2Client();
     client.SensorDataReceived += sensorData => form.ShowMap(sensorData.Map);
     client.Configurate(port, true, RoboMoviesBots.Stand);
     client.Rotate(-90);
     client.Move(100);
     client.Rotate(90);
     client.Move(110);
     for (int i = 0; i < 10; i++)
     {
         client.Rotate(10);
     }
     client.Exit();
 }
示例#2
0
 public Nothing(Level2Client client)
 {
     Action = () =>
     {
         client.Move(0);
         client.Exit();
         return null;
     };
 }
示例#3
0
 public Forward(double distance, Level2Client client)
 {
     this.distance = distance;
     Action = () => client.Move(distance);
 }