Beispiel #1
0
 public Pitcher(Ball ball)
 {
     ball.BallInPlay += new EventHandler(ball_BallInPlay);
 }
Beispiel #2
0
        static void Main(string[] args)
        {
            Ball ball = new Ball();
            Pitcher pitcher = new Pitcher(ball);

            BallEventArgs ballEventArgs = new BallEventArgs(59, 94);

            ball.OnBallInPlay(ballEventArgs);
        }
Beispiel #3
0
        static void Main(string[] args)
        {
            Console.WriteLine("Hello world!");

            Ball ball = new Ball();

            Pitcher pitcher = new Pitcher(ball);

            ball.playBall_Click();
        }