user3103552
user3103552

Reputation: 1

How to CHANGE the location of a rectangle?

How do I change the location of where a rectangle is?

    private void Reset()
    {
        rndLocation();
        face1.Height = 30.0F;
        face1.Width = 25.0F;           
        lost = false;
        //change rectangle location
    }

Upvotes: 0

Views: 3736

Answers (1)

shree.pat18
shree.pat18

Reputation: 21757

Use the Rectangle.Location property e.g.

face1.Location.X = new_X;
face1.Location.Y = new_Y;

Upvotes: 1

Related Questions