CFrame's orientation is not being set properly

When i try to make CFrame of a HumanoidRootPart inside of a character be the exact same as a part inside of other character the orientation is always completely off

Part of a script that sets the CFrame:

local monsterRoot = monster:FindFirstChild("HumanoidRootPart")
	local monsterHumanoid = monster:FindFirstChild("Humanoid")
	local bodyRootPart = deadBody:FindFirstChild("HumanoidRootPart")
	local bodyHumanoid = deadBody:FindFirstChild("Humanoid")

	
	local DMWposition = monsterRoot.Parent:FindFirstChild("DMWposition")
	

	bodyRootPart.Anchored = true
	wait(1)
	bodyRootPart.CFrame = DMWposition.CFrame

	monsterHumanoid.WalkSpeed = 0


half transparent gray part is DMWposition

local monsterRoot = monster:FindFirstChild("HumanoidRootPart")
	local monsterHumanoid = monster:FindFirstChild("Humanoid")
	local bodyRootPart = deadBody:FindFirstChild("HumanoidRootPart")
	local bodyHumanoid = deadBody:FindFirstChild("Humanoid")

	
	local DMWposition = monsterRoot.Parent:FindFirstChild("DMWposition")
	

	bodyRootPart.Anchored = true
	wait(1))
	bodyRootPart.CFrame = DMWposition.CFrame * CFrame.Angles(DMWposition.CFrame)

	monsterHumanoid.WalkSpeed = 0

argument 3 missing or nil
also, the positioning works fine, it’s just the orientation that’s weird

used pivotto instead of cframe changing

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.