heres the code:
ewx,ewy,ewz = 1.5,6.5,34
ewx2,ewy2,ewz2 = 7,6.5,28.5
ewx3,ewy3,ewz3 = 0.5,6.5,25
erx,ery,erz = 1.5,11.5,29.5
egx,egy,egz = 1.5,1.5,29.5
time = 0.1
ev1 = workspace.elevatorwall
ev2 = workspace.elevatorwall2
ev3 = workspace.elevatorwall3
er = workspace.elevatorroof
eg = workspace.elevatorground
function elevator()
repeat
ev1.CFrame = CFrame.new(ewx,ewy,ewz)
ewy = ewy + 1
ev2.CFrame = CFrame.new(ewx2,ewy2,ewz2)
ewy2 = ewy2 + 1
ev3.CFrame = CFrame.new(ewx3,ewy3,ewz3)
ewy3 = ewy3 + 1
er.CFrame = CFrame.new(erx,ery,erz)
ery = ery + 1
eg.CFrame = CFrame.new(egx,egy,egz)
egy = egy + 1
wait(time)
until workspace.elevatorground.CFrame == (1.5,60.5,29.5)
end
script.Parent.MouseButton1Click:connect(elevator)
heres the error
01:27:58.614 - Workspace.screen.SurfaceGui.leviosa.Script:30: ')' expected near ','

2 comments
Have you taken a look as using a PrismaticConstraint as it will be good for this task.
also it would be even simpler to make it by adapting the script from the video on YT by Roblox called "how to make a moving platform" as it would require very little scripting