This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
jakylorhide's profile picture

[Lua][Error] ')' expected?

Started by jakylorhide, 22 April 2013 - 11:39 AM
jakylorhide #1
Posted 22 April 2013 - 01:39 PM
applicable code
Spoiler

set = {}
set[1] = {xc = xg + 3 , yc = yg , zc = 253}
set[2] = {xc = xg - 3 , yc = yg , zc = 253}
set[3] = {xc = xg , yc = yg + 3 , zc = 250}
set[4] = {xc = xg , yc = yg - 3 , zc = 250}

fs.delete("disk/gps") --Removes previous gps file for last sat
todd = fs.open("disk/gps","w")
todd.write(shell.run("gps", "host",set[i]["xc"],set[i]["yc"]set[i]["zc"]) )
if not fs.exists("startup") then --checks to see if it has a startup file
sue = fs.open("disk/startup","w")
sue.write( fs.copy("disk/gps, /startup"))
turtle.select(4) --Returns the disk to inv
turtle.suckDown()
turtle.select(3) --returns drive to inv
turtle.digDown()
godown()
side()
sat = peripheral.wrap(side)
sat.turnOff()
sat.turnOn()
line that's giving me the error is
todd.write(shell.run("gps", "host",set[i]["xc"],set[i]["yc"]set[i]["zc"]) ) 
any help would be appreciated
Kingdaro #2
Posted 22 April 2013 - 02:09 PM
You're missing a comma a little ways in there:

todd.write(shell.run("gps", "host", set[i]["xc"], set[i]["yc"], set[i]["zc"]))
jakylorhide #3
Posted 24 April 2013 - 12:53 PM
thank you so much. feel like an idiot for missing that :D/>