Isssue with cframing part to humanoidrootpart

when cframing a part to the humanoidrootpart while the player is using shiftlock, the humanoidrootpart’s cframe does not seem to match its visuals. i have also tested this in non studio and its the same. i have noticed that using the “PreSimulation” event causess the position to be slightly delayed, andd the post simulation event along with other events does not have this issue with position. so the problem is mainly with the rotation. are there any solutions?
to clarify the opaque part that is the same size as the humanoidrootpart is NOT the humanoidrootpart its a part copying the humanoidrootpart’s cframe.


1 Like

Would you please describe more about how this part is getting set up and CFramed?
I wasn’t able to reproduce the issue. All I did was CFrame a part to the HumanoidRootPart on PostSimulation and it works fine.

I did it all on the client here. Is yours different?

local RunService = game:GetService("RunService")

local character = script.Parent
local humanoid = character:WaitForChild("Humanoid") :: Humanoid
local rootPart = humanoid.RootPart or humanoid:GetPropertyChangedSignal("RootPart"):Wait()

local part = Instance.new("Part")
part.Anchored = true
part.CanCollide = false
part.Size = rootPart.Size
part.Parent = character

local connection = RunService.PostSimulation:Connect(function()
	part.CFrame = rootPart.CFrame
end)

humanoid.Died:Once(function()
	part:Destroy()
	connection:Disconnect()
end)
1 Like

its when rotating quickly

this was for welding rigs to other rigs, and i just realized u can use motor6ds (or welds but i havnt tested welds maybe there is some weird quirk)
then disable EvaluateStateMachine on the humanoid of the rig that doesnt need to move. this prevents the characters from killing eachother when one reaches zero health. when one reaches zero health you can disable the weld or motor6d connecting the two rigs then enable EvaluateStateMachine. which will cause whoever reached zero health to die without killing the other rig. (EvaluateStateMachine being disabled will of course disable the death state :P)

1 Like

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