According to the wiki, CFrame*CFrame:ToObjectSpace(CFrame2) == CFrame2
and CFrame:ToObjectSpace(CFrame2) == CFrame:Inverse()*CFrame2
, and to me it works great…most of the cases. Now, I tried this with 2 normal parts of the workspace (I just put a Model in the workspace and put 2 parts there with a random position) and the re
sult is true. You can try this youself out:
local Model = workspace.TestModel
local CFrame1 = Model.Part1.CFrame
local CFrame2 = Model.Part2.CFrame
print(CFrame1*CFrame1:ToObjectSpace(CFrame2)==CFrame2)
But, when I try this out with some parts of my NPC, it says me false. I don’t understand why. And, if this isn’t confusing enough: If I try the other method, CFrame:Inverse()*CFrame2
, it says me true! But, both methods should give me the same result, why is this here different? I mean, both result looks really the same, if not some small number changes:
-64.7682877, 101.081512, 54.2975464, -8.75882193e-08, -5.30979316e-10, 1, -1.00049725e-10, 1, 5.30979316e-10, -1, -1.00049698e-10, -8.75882193e-08 --CFrame:ToObjectSpace(CFrame2) Result
-64.7682877, 101.081512, 54.2975464, -8.75882193e-08, -5.30979316e-10, 1, -1.00049725e-10, 1, 5.30979316e-10, -1, -1.00049698e-10, -8.75882193e-08 --CFrame:Inverse()*CFrame2 Result
This shouldn’t affect my code heavly, but I am wondering what is the true result? The result of the ToObjectSpace or the result of the alternative way? This is more a question as a problem