Наследование: System.EventArgs
Пример #1
0
 private void ball_Scored(object sender, ScoreEventArgs e)
 {
     if (e.Side == Paddle.Side.Left)
     {
         ScoreLeft += 1;
     }
     else if (e.Side == Paddle.Side.Right)
     {
         ScoreRight += 1;
     }
     OnScored(e.Side, e.Ball);
     DispatcherHelper.CheckBeginInvokeOnUI(() =>
     {
         Balls.Remove(e.Ball);
         AddBall();
     });
 }
Пример #2
0
 private void PongGame_Scored(object sender, ScoreEventArgs e)
 {
     RaisePropertyChanged("PongGame");
 }
Пример #3
0
 private void ball_Scored(object sender, ScoreEventArgs e)
 {
     if (e.Side == Paddle.Side.Left)
     {
         ScoreLeft += 1;
     }
     else if (e.Side == Paddle.Side.Right)
     {
         ScoreRight += 1;
     }
     OnScored(e.Side, e.Ball);
     DispatcherHelper.CheckBeginInvokeOnUI(() =>
                                               {
                                                   Balls.Remove(e.Ball);
                                                   AddBall();
                                               });
 }