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

What is the difference between toObjectSpace and pointToObjectSpace?

Asked by
52M 10
10 years ago
print(game.Workspace.Part.CFrame:pointToObjectSpace(game.Workspace.BasePlate.Position))
print(game.Workspace.Part.CFrame:toObjectSpace(game.Workspace.BasePlate.CFrame).p)
--These both print the same thing.

1 answer

Log in to vote
0
Answered by 10 years ago

Yes there is a difference, they will be the same thing because it's world coordinates, HOWEVER, one is Vector3 and one is CFrame, so their type is different.

More about them: http://wiki.roblox.com/index.php?title=CFrame#Methods

Please give me a reputation point if I answered your question,

0
The CFrame one preserves rotation/orientatio; the Vector3 one does not have any orientation information to preserve / report BlueTaslem 18071 — 10y
Ad

Answer this question