I have checked multiple forum posts and none of them cover my issue.
For some reason, when the ragdoll is dropped or even just falls it starts to bounce or spasm making it go insane, sometimes it would just fly super fast and give my game “Gameplay paused” message
Images:
Script:
local Phy = script.physics:Clone()
Phy.Parent = hit.Parent
Phy.Enabled = true
local value = Instance.new("BoolValue")
value.Name = "RAGDOLLED"
value.Value = true
value.Parent = hit.Parent
hit.Parent.Humanoid.AutoRotate = false
for index,joint in pairs(hit.Parent:GetDescendants()) do
if joint:IsA("Motor6D") then
local socket = Instance.new("BallSocketConstraint")
local a1 = Instance.new("Attachment")
local a2 = Instance.new("Attachment")
a1.Parent = joint.Part0
a2.Parent = joint.Part1
socket.Parent = joint.Parent
socket.Attachment0 = a1
socket.Attachment1 = a2
a1.CFrame = joint.C0
a2.CFrame = joint.C1
socket.LimitsEnabled = true
socket.TwistLimitsEnabled = true
joint.Enabled = false
end
end
wait(3.3)
value:Destroy()
hit.Parent.Humanoid.AutoRotate = true
for index,joint in pairs(hit.Parent:GetDescendants()) do
if joint:IsA("Motor6D") then
local getup = script.gettingup:Clone()
getup.Parent = hit.Parent
getup.Enabled = true
joint.Enabled = true
end
end
wait (1)
end
end
Please help as ragdoll is a extremely important feature for the game i am currently making