mlard811

Quarry Cover

Aug 13th, 2014
216
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.64 KB | None | 0 0
  1. local x = 1
  2. turtle.forward() -- Move into hole
  3. while(true)
  4. do
  5.    while (turtle.detectDown() == false)
  6.    do
  7.          if(turtle.getItemCount(x)==0)
  8.          then
  9.             x=x+1
  10.             if(x==10) then
  11.                   x = 1
  12.             end
  13.             turtle.select(x)
  14.          end
  15.          turtle.placeDown()
  16.          turtle.forward()
  17.          if(turtle.detect()) and (turtle.detectDown() == false)
  18.          then
  19.            turtle.turnLeft()
  20.          end
  21.    end
  22.    while (turtle.detectDown() == true) do
  23.     turtle.back()
  24.     turtle.turnLeft()
  25.     turtle.forward()
  26.    end
  27. --   turtle.back()
  28. --   turtle.turnLeft()
  29. end
Add Comment
Please, Sign In to add comment