Hello I am currently trying to make a script that spawns an infinite track. It works well except that it spawns tons and tons of models when it is touched. How do I pause the script momentarily to prevent this?
local function clone()
local cloned = road:Clone()
cloned.Parent = game.Workspace
--cloned:SetPrimaryPartCFrame(CFrame.new(0, 0, 130.588))--(0, 0, 130.588)
--cloned:SetPrimaryPartCFrame(PreviousPart.PrimaryPart.CFrame * CFrame.new(0, 0, 130.588))--(0, 0, 130.588)
cloned:SetPrimaryPartCFrame(road.PrimaryPart.CFrame * CFrame.new(0,0,-130.588))
print("road has spawned")
end
--EVENT
touch.Touched:Connect(clone)
Thanks in advance :)
