i'm having an error in my program which I can't track down.
Can anyone help me?
the error is:
turtle:22: expected number
and the code:
quarrylenght=10 conduit=1 quarry=2 enderchest=3 waste1=4 waste2=5 fuel=16 quarrytime=10 signal=15 function wastereduction() if turtle.getItemCount(waste1)>0 then turtle.select(waste1) turtle.dropUp() end if turtle.getItemCount(waste2)>0 then turtle.select(waste2) turtle.dropUp() end end function forward() -- getting in position turtle.select(enderchest) turtle.dig() turtle.forward() turtle.turnLeft() turtle.dig() turtle.forward() turtle.turnRight() turtle.turnRight() -- getting the complete front row local counter = quarrylenght-1 while counter>0 do counter=counter-1 turtle.select(enderchest) turtle.dig() turtle.select(quarry) turtle.digDown() turtle.forward() end -- getting in posiotion for the conduit row turtle.turnRight() turtle.forward() turtle.select(conduit) turtle.digDown() turtle.down() turtle.turnRight() -- getting the row of conduits local counter= quarrylenght-1 while counter>0 do counter=counter-1 turtle.dig() turtle.forward() end -- end of the cleanup, start of the placement turtle.turnRight() turtle.forward() turtle.select(waste1) turtle.dig() turtle.forward() turtle.turnRight() -- going to do the clearing of the next row and the placement of the ender chests. local counter = quarrylenght while counter>0 do counter=counter-1 repeat turtle.select(waste2) turtle.digUp() turtle.select(enderchest) turtle.placeUp() until turtle.compareUp(enderchest)==true wastereduction() -- the forward part, doesn't go of for the last time while counter>1 do turtle.select(wase1) turtle.dig() while turtle.forward()==false do sleep(4) turtle.select(waste1) turtle.dig() end end end -- getting in place for the placement of quarry's and conduits turtle.turnLeft() turtle.back() end forward()if it does some weird movement, it is an unfinished quarry turtle.
Edited by blipman17, 01 April 2014 - 11:44 AM.












