I’m working on a game similar to cart ride games, But the player is in a ball that’s in their character, And there’s a part that moves up and down the player needs to stand on, the only problem is, If the player is laggy they fall through the moving Part.
Im trying to make the player Weld to the part when they touch it, Heres my script,
local Part = script.Parent
local Weld = script.Parent.Weld
Part.Touched:Connect(function(Hit)
local Player = Hit.Parent
Weld.Part0.Parent = Player
end)
local Part = script.Parent
Part.Touched:Connect(function(v1)
if v1.Parent:FindFirstChild("Humanoid") ~= nil then
local weld = Instance.new("Weld")
Weld.Part0 = v1.Parent.Head
Weld.Part1 = Part
end
end)