Advertisement
GopherAtl

liner - line-following cc miner bot

Apr 15th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.49 KB | None | 0 0
  1. while true do
  2.   turtle.digDown()
  3.   while not turtle.forward() do turtle.dig() end
  4.   if not turtle.compareDown() then
  5.     turtle.back()
  6.     turtle.turnRight()
  7.     while not turtle.forward() do turtle.dig() end
  8.     if not turtle.compareDown() then
  9.       turtle.turnLeft()
  10.       turtle.turnLeft()
  11.       turtle.forward()
  12.       while not turtle.forward() do turtle.dig() end
  13.       if not turtle.compareDown() then
  14.         print("line ended!")
  15.         return
  16.       end
  17.     end
  18.   end
  19. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement