Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to get the rotation aspect of a Cframe in numbers?

Asked by 6 years ago
Edited 6 years ago

Ok so I have a Cframe but I need to know the exact values of the XYZ rotations in the cframe in either degrees or radians.

camera = game.Workspace.CurrentCamera
local CameraCFrame = camera.CoordinateFrame
local PureRotation = CameraCFrame - Camera.CFrame.p
print(-- how would i get the XYZ rotation in degrees or radians from the the pure rotation CFrame??)

I also looked at the cframe properties and there isn't any kind of rotation property.

1 answer

Log in to vote
0
Answered by 6 years ago

To my knowledge CFrame doesn't have a rotation property. Though subtracting the position from the CFrame does work I'm sure.

a.CFrame - a.CFrame.p
0
i know this Wafflecow321 457 — 6y
0
But i need the rotation in numbers Wafflecow321 457 — 6y
Ad

Answer this question