Exemplo n.º 1
0
 private void Draw(Canvas canvas)
 {
     foreach (var brick in _bricks)
     {
         brick.Draw(canvas);
     }
     _ball.Draw(canvas);
     Stand.Draw(canvas);
 }
Exemplo n.º 2
0
        public Game(Graphics g, Label label)
        {
            _label  = label;
            this._g = g;
            float width = 1024;

            _height    = 720;
            _bricks    = CreateBricks();
            _ball      = new Ball(width / 2, 500, 5, new Random().Next(180));
            Stand      = new Stand(width / 2, 575);
            IsGameOver = false;
            IsWin      = false;
        }
Exemplo n.º 3
0
 private void Move()
 {
     _ball.Move();
     Stand.Move();
 }