Exemplo n.º 1
0
        private void Level1_Paint(object sender, PaintEventArgs e)
        {
            Brush b   = new SolidBrush(Color.Blue);
            Pen   pen = new Pen(Color.FromArgb(255, 0, 0, 0));

            pen.Width = 5;

            e.Graphics.DrawLines(pen, gameDoc.points);
            gameDoc.DrawBalls(e.Graphics);
            gameDoc.square.Draw(e.Graphics);
        }
Exemplo n.º 2
0
        private void Level1_Paint(object sender, PaintEventArgs e)
        {
            Brush b   = new SolidBrush(Color.Blue);
            Pen   pen = new Pen(Color.FromArgb(255, 0, 0, 0));

            pen.Width            = 5;
            toolStripLabel1.Text = "X: " + gameDoc.square.X + ", Y: " + gameDoc.square.Y;
            e.Graphics.DrawLines(pen, gameDoc.points);
            gameDoc.DrawBalls(e.Graphics);
            Time.Text = (TimerCount / 1000).ToString() + ":" + (TimerCount % 1000).ToString() + "s";
            gameDoc.DrawSquare(e.Graphics);
        }