I want to know a way to add offset distance to an 2d point.

Let say if i have point = new Vector2(1,2)

So how i can add 50 to it. So i will get the new proper position.

Thanks

I want to know a way to add offset distance to an 2d point.

Let say if i have point = new Vector2(1,2)

So how i can add 50 to it. So i will get the new proper position.

Thanks

This only works if you define a direction for this distance. Otherwise you can only use Vector2.addScalar() which just adds 50 to both vector components.

Thanks for responding.

I have one more questionâ€¦

Let say if i have an shape that consist of five points and in each point if i will add the offset like the way you told so i am expecting an bigger figure of same shape. But i am getting a figure , same shape but not bigger why and also the position is not proper.