예제 #1
0
        /// <summary>
        /// Initialise l'état des différents objets du jeu.
        /// </summary>
        public void Init()
        {
            this.Ball   = new Ball();
            this.Ground = new PlayGround();

            this.Winner = null;

            this.Scores             = new Scores();
            this.Scores.MatchEnded += (sender, args) => {
                this.Winner = new EndMatch(args.Winner);
            };

            this.LeftRacquet  = new Racquet(Racquet.RacquetSides.Left);
            this.RightRacquet = new Racquet(Racquet.RacquetSides.Right);
        }
예제 #2
0
        /// <summary>
        /// Initialise l'état des différents objets du jeu.
        /// </summary>
        public void Init()
        {
            this.Ball = new Ball();
            this.Ground = new PlayGround();

            this.Winner = null;

            this.Scores = new Scores();
            this.Scores.MatchEnded += (sender, args) => {
                this.Winner = new EndMatch(args.Winner);
            };

            this.LeftRacquet = new Racquet(Racquet.RacquetSides.Left);
            this.RightRacquet = new Racquet(Racquet.RacquetSides.Right);
        }