Amudeash
|
  |
| Joined: 22 Jan 2011 |
| Total Posts: 842 |
|
|
| 23 Mar 2015 04:05 PM |
| How do I make the DesiredAngle rotate by the Y axis? |
|
|
| Report Abuse |
|
|
| 23 Mar 2015 04:05 PM |
| Rotate the axes of C0 and C1. |
|
|
| Report Abuse |
|
|
| 23 Mar 2015 04:12 PM |
I should have explained better. By default, the axis of rotation goes straight down the Z axis. Thus, to get it to go straight down the Y axis, you need to rotate it 90 degrees around the X axis. Whether this angle should be positive or negative depends on the direction you want it to spin.
Weld.C0 = CFrame.new() * CFrame.Angles(math.pi/2, 0, 0) --Will cause it to spin clockwise if you look down from the origin. If this is the wrong way, do -math.pi/2 instead.
Apply the same angle to C1. |
|
|
| Report Abuse |
|