I was trying to do a script where a player can drag another player using a rope, everything worked as intended except for one part, the player's physics. Is there a way to change the player's state in a way where the player can feel like a dead person but not necessary be dead. The best results that i got is by enabling the platformstand but even then it doesn't feel the way it should.
This is the local script(just in case):
local uis = game:GetService("UserInputService")
local grab = false
uis.InputEnded:Connect(function(i, gpe)
if i.KeyCode == Enum.KeyCode.Z and gpe == false then
if grab == false then
grab = true
return
end
if grab == true then
grab = false
return
end
end
end)
spawn(function()
script.Parent.Humanoid.Touched:Connect(function(hit)
if grab == true then
if hit.Parent:FindFirstChild("Humanoid") ~= nil then
print("got you")
game:GetService("ReplicatedStorage"):WaitForChild("just because"):FireServer(hit)
grab = false
return
end
if hit.Parent:FindFirstChild("Humanoid") == nil then
grab = false
print("Mission Failed, We Will Get Him Next Time")
return
end
end
end)
end)
This is the script(just in case):
local reps = game:GetService("ReplicatedStorage")
local jb = reps:WaitForChild("just because")
jb.OnServerEvent:Connect(function(player, hit)
hit.Parent.Humanoid:ChangeState(16)
hit.Parent.Humanoid.PlatformStand = true
local weld = Instance.new("RopeConstraint")
weld.Name = "GOTYOU"
weld.Parent = player.Character.RightHand
weld.Attachment0 = player.Character.RightHand.RightGripAttachment
weld.Attachment1 = hit.Parent.Head.NeckRigAttachment
weld.Length = 10
weld.Visible = true
end)

9 comments
Anchoring the HumanoidRootPart?
im not sure how to do it, but you can ragdoll the player
Good question. I would try adding a body velocity that goes upwards but isnt strong enough to carry the player. Then you could set the caught players walkspeed and jumppower to 0?
For my suggestion to work you would also have to create an animation which would be tedious
^
yeah best choice, you'd have to perfect that thouh
I'd think that best choice would be to ragdoll a player instead of an animation, then use a rope constraint and decrement the weld length over a period of time. (or don't decrement it, if you just want to walk around with them on a rope)
Oh also probably should disable the player's input if you have special moves or something because otherwise that might cause a lot of problems.
Rag dolling would work better as Steam said, I just don't know how to do it and I'm against taking things from the catalog.