Advertisement
Guest User

startup

a guest
May 23rd, 2019
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.37 KB | None | 0 0
  1. print "qqq"
  2.  
  3. local function find_slot()
  4.     for i = 1, 16 do
  5.         if turtle.getItemSpace(i) > 0 then
  6.             turtle.select(i)
  7.             return
  8.         end
  9.     end
  10. end
  11.  
  12. while true do
  13.     local is_block, data = turtle.inspect()
  14.     if is_block then
  15.         if data.state and data.state.age == 7 then
  16.             find_slot()
  17.             turtle.dig()
  18.         end
  19.     else
  20.         turtle.place()
  21.     end
  22.  turtle.turnLeft()
  23.     sleep(1)
  24. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement