TheKojent

flatRow

Jan 31st, 2013
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.38 KB | None | 0 0
  1. --Flattens a row of tArgs length (inputted in console)
  2. local tArgs = {...}
  3. a = tonumber(tArgs[1])
  4. b = 0
  5. turtle.select(1)
  6. while b < a do
  7.   while turtle.forward() == false do
  8.     turtle.dig()
  9.   end
  10.   b = b + 1
  11.   turtle.placeDown()
  12.   while turtle.detectUp() == true do
  13.     turtle.digUp()
  14.     turtle.up()
  15.   end
  16.   while turtle.detectDown() == false do
  17.     turtle.down()
  18.   end
  19. end
Advertisement
Add Comment
Please, Sign In to add comment