Пример #1
0
 private void timer1_Tick(object sender, EventArgs e)
 {
     PongGame.DrawIt(Draw);                      //Draws paddles & ball
     PongGame.MoveBall(timer1);                  //Moves the ball
     PongGame.CheckScore();                      //Check if one player scored
     PongGame.CheckIfMoving();                   //Method that check if player is moving up or down the paddle
 }
Пример #2
0
 private void timer2_Tick(object sender, EventArgs e)
 {
     PongGame.IncreaseSpeed();
 }                                                                                      //Every 3 seconds, this timer will increase Overall speed