while true do path = game:GetService("PathfindingService") :ComputeRawPathAsync(workspace.Start. Position, workspace.Finish. Position, 200)
Points = path:GetPoint:PointCoordinates() game.Workspace.Points:ClearAllChildren() for p = 1, #points do part = Instance.new("Part") part.FormFactor = Enum.FormFactor.Symmetric part.CanCollide = false part.Size = Vecter3.new(1.1.1) part.Position = points[p] part.Anchord = true part.BrickColor = BrickColor.Gray() Part.Parent = game.Workspace.Points end
wait(0.1) end
Change:
Points = path:GetPoint:PointCoordinates()
to:
Points = path:GetPointCoordinates()
Change part.BrickColor = BrickColor.Gray() to part.BrickColor = BrickColor.New("Dark stone grey") because if you say just "Grey" the script doesn't recognise that as a BrickColor.