E
eldinhelja
Guest
Hello, I've had a long day. My brain is not working.
I have created this :
I have 8 objects called P1, P2, P3...
I Want to rotate every point at once for some angle "degRotate"
So eg. if I rotate it by 30 deg. I need to get this :
I am really tired.
EDIT :
Forgot to mention : p[0] = instance_create(x1,y1,x2,y2) //Should look like thise
Just need a formula, not code
I have created this :
I have 8 objects called P1, P2, P3...
I Want to rotate every point at once for some angle "degRotate"
Code:
//Variables
degRotate=240
//Find Center
CenterX = (x1+x2)/2
CenterY = (y1+y2)/2
//Get Radius
radius = point_distance(x1, y1, CenterX, CenterY)
//Create points after rotation
p[0] = instance_create(....) //p[0] is P1 (Point 1)
I am really tired.
EDIT :
Forgot to mention : p[0] = instance_create(x1,y1,x2,y2) //Should look like thise
Just need a formula, not code
Last edited by a moderator: