Advertisement
Burrito33

BIGFARMER

Dec 12th, 2022 (edited)
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.62 KB | None | 0 0
  1. local w = 28
  2. local r = 30
  3. local i = 1
  4. local success, data = turtle.inspectDown()
  5. x = 0
  6. print(x)
  7. repeat
  8.      x = x + 1
  9.     repeat
  10.         if success then
  11.                 if data.metadata == 7 then
  12.                     turtle.digDown()
  13.                     turtle.forward()
  14.                     else
  15.                 turtle.forward()
  16.                 end
  17.         end
  18.     i = i + 1
  19.     until i == w
  20.         if (x % 2 == 0) then
  21.                 turtle.turnLeft()
  22.             turtle.digDown()
  23.             turtle.forward()
  24.             turtle.turnLeft()
  25.             i = 1
  26.         else
  27.             turtle.turnRight()
  28.             turtle.digDown()
  29.             turtle.forward()
  30.             turtle.turnRight()
  31.             i = 1
  32.         end
  33. print(x)
  34. until x == r
  35. turtle.dropDown()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement