Exemplo n.º 1
0
        private void btnPlay_Click(object sender, RoutedEventArgs e)
        {
            if (CanPlay())
            {
                MoveRobot.Begin();

                robotSound.Stop();
                robotSound.Source = new System.Uri("sound26.wma", System.UriKind.Relative);

                System.Threading.Thread.Sleep(50);
                robotSound.Play();
            }
        }
Exemplo n.º 2
0
 public static void testMovingMoving(RobotOrientation orientation, int expectedX, int expectedY)
 {
     int[] expectedResult = { expectedX, expectedY };
     int[] actualResult   = MoveRobot.GetRobotDisplacement(orientation);
     Assert.Equal(expectedResult, actualResult);
 }