Advertisement
Guest User

dig

a guest
Apr 8th, 2020
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.48 KB | None | 0 0
  1. --This simple script will dig a line
  2.  
  3.  
  4. for i=1,16 do
  5.   local count = 0
  6.   local fail = 0
  7.   while turtle.digDown() or fail <= 10 do
  8.     f = turtle.down()
  9.     if f == true then
  10.       count = count + 1
  11.       fail = 0
  12.     else
  13.       fail = fail + 1
  14.     end
  15.   end
  16.   for j=1,count do
  17.     turtle.up()
  18.   end
  19.   turtle.digUp()
  20.   turtle.placeUp()
  21.   for k=1,16 do
  22.     turtle.select(k)
  23.     turtle.dropUp(64)
  24.   end
  25.   turtle.digUp()
  26.   while turtle.dig() do end
  27.   turtle.forward()
  28. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement