hi im tryng make an parto that move wethever theparts are
i am following this tutorial along Ski Lifts, Trains, Airplanes, Boats, Cars and more - Roblox Scripting Tutorial - YouTube
- when i run the game it only goes to 4 parts and the error say 19:32:36.395 ServerScriptService.Script:24: invalid argument #3 (Vector3 expected, got nil) - Server - Script:24
for i, folder in ipairs(workspace.Paths:GetChildren()) do
local positions = {}
for i, part in ipairs(folder:GetChildren()) do
positions[tonumber(part.Name)] = part.Position
--part:Destroy()
part.CanCollide = false
end
local target = Instance.new("Part")
target.Anchored = true
target.CanCollide = false
target.CanTouch = false
target.Position = positions[1]
target.Size = Vector3.new(4, 4, 4)
target.Parent = folder
spawn(function()
local i = 1
while true do
i += 1
if i > #positions then i = 1 end
target.Position = positions[i]
wait(2)
end
end)
end



