I am having trouble making this script activate on touch and after a certain of amount time disable it. What is this script supposed to do? I am trying to activate this script on touch after the player has touched a certain part (thats not the model) the model will move and after a certain amount of seconds the script will be disabled and the model will stop moving. I tried breaking but I am not sure if I even used it correctly. help plz
script.Parent.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
workspace.TWO.PrimaryPart = workspace.TWO.HumanoidRootPart
while true do
for i = 1,100 do
wait()
workspace.TWO:SetPrimaryPartCFrame(CFrame.new(workspace.TWO.PrimaryPart.Position + Vector3.new(0,0,1)))
wait(4)
break
end
end
end
end)

1 comment
well did it work when you broke it?