Posted 03 January 2015 - 07:00 PM
So i got into turtle programming a few days ago and i cant figure out what is wrong with my code.
I want the code to harvest and replant crops for me in a 12*7 area.
The error message i am geting is: Bios:338: [string "harvestL"]:2: '=' expected.
now i know when you get that error message you should look at that line and the line above more carefully and i did for 30 minutes and i am clueless to what is wrong with it so please help.
this is my code :
I want the code to harvest and replant crops for me in a 12*7 area.
The error message i am geting is: Bios:338: [string "harvestL"]:2: '=' expected.
now i know when you get that error message you should look at that line and the line above more carefully and i did for 30 minutes and i am clueless to what is wrong with it so please help.
this is my code :
function = strip(length)
for i=1, length, 1 do
turtle.digDown()
turtle.suckDown()
turtle.placeDown()
turtle.forward()
end
end
function turnRight()
turtle.turnRight()
turtle.forward
turtle.digDown()
turtle.turnRight()
turtle.placeDown()
end
function turnLeft()
turtle.turnLeft()
turtle.forward
turtle.digDown()
turtle.turnLeft()
turtle.placeDown()
end
function resPos(length)
turtle.turnRight()
for i=1, length, 1 do
turtle.forward()
end
turtle.turnRight()
turtle.dropUp()
end strip(12)
turnRight()
strip(12)
turnLeft()
strip(12)
turnRight()
strip(12)
turnLeft()
strip(12)
turnRight()
strip(12)
turnLeft()
strip(12)
resPos(12)