#Character got pull by the carried dummy

1 messages · Page 1 of 1 (latest)

torpid thistle
#

The character seems get bouncy while carrying the dummy please help me fix it so the player doesn't effect by the dummy

dummy's script

local Humanoid = script.Parent:WaitForChild("Humanoid")
local RS = game:GetService("ReplicatedStorage")
local remoteEvent = RS.RemoteEvent.RobotHitEvent
local function weldPlayers(origin,carry)
    local ro, rc=origin.HumanoidRootPart,carry.HumanoidRootPart
    carry.Humanoid:ChangeState(Enum.HumanoidStateType.GettingUp)
    carry.Humanoid.PlatformStand = true
    local w=Instance.new("WeldConstraint")
    w.Name = "carryweld"
    w.Part0 = ro
    w.Part1 = rc
    w.Parent = rc
    for _,v in pairs(carry:GetChildren()) do
        if v:IsA("BasePart") then
            v.Massless = true
        end
    end
end
remoteEvent.OnServerEvent:Connect(function(player, hit)
    if hit == script.Parent then
        for _, part in pairs(script.Parent:GetDescendants()) do
            if part:IsA("BasePart") then
                part.Massless = true
            end
        end
        for index,joint in pairs(script.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:Destroy()
            end
        end
        weldPlayers(player.Character, script.Parent)
    end
end)
civic steppeBOT
#

studio** You are now Level 3! **studio

jolly venture
#

you want the full script?

#

try this