'argument 3 missing or nil' error with tween script

I’m trying to make a tween script that will tween the car to each of the waypoints.

Script:

local Car = script.Parent
local Humanoid = Car.Humanoid
local waypoints = workspace.Folder:GetChildren()
local ts = game:GetService('TweenService')
local primary = script.Parent.Brain

for i, p in pairs(Car:GetChildren()) do
 if p:IsA('BasePart') and (p ~= primary) then
  local weld = Instance.new('WeldConstraint',p)
   weld.Part0 = p
   weld.Part1 = primary
 end
end

for i, waypoint in pairs(waypoints) do
 local tweencreate = ts:Create(primary, TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,1000000000,false,0,{CFrame = primary.CFrame * waypoint.CFrame}))
 tweencreate:Play()
end

You put the 3rd argument of TweenService:Create() into the TweenInfo object. Move the end parentheses before the property/value dictionary.

local tweencreate = ts:Create(primary, TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,1000000000,false,0,{CFrame = primary.CFrame * waypoint.CFrame}))

You placed a ) at the wrong place. Here’s the fixed line.

local tweencreate = ts:Create(primary, TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,-1,false,0),{CFrame = primary.CFrame * waypoint.CFrame})