Advertisement
Guest User

Untitled

a guest
Jan 17th, 2020
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.27 KB | None | 0 0
  1. turtle.select(1)
  2. turtle.refuel(1)
  3. local counter = 0
  4. local counter2 = 0
  5. local counter3 = 0
  6. local counter4 = 0
  7.  
  8.  
  9. while counter3 ~= 9 do
  10. local seedAmount = turtle.getItemCount(2)
  11. local fuelAmount = turtle.getFuelLevel()
  12.  
  13. if seedAmount > 0 then
  14. turtle.select(2)
  15. else
  16. turtle.select(3)
  17. end
  18.  
  19. if fuelAmount < 20 then
  20. turtle.select(1)
  21. turtle.refuel(1)
  22. end
  23.  
  24.  
  25. turtle.digDown()
  26. turtle.placeDown()
  27. turtle.forward();
  28. counter = counter + 1
  29.  
  30. if counter == 8 then
  31. if counter2 == 0 then
  32. if seedAmount > 0 then
  33. turtle.select(2)
  34. else
  35. turtle.select(3)
  36. end
  37.  
  38. if counter3 ~= 8 then
  39. turtle.turnLeft()
  40. turtle.digDown()
  41. turtle.placeDown()
  42. turtle.forward()
  43. turtle.turnLeft()
  44. counter2 = 1
  45. else
  46. turtle.digDown()
  47. turtle.placeDown()
  48. turtle.turnLeft()
  49. turtle.turnLeft()
  50. counter4 = 1
  51. end
  52.  
  53.  
  54. elseif counter2 == 1 then
  55. if seedAmount > 0 then
  56. turtle.select(2)
  57. else
  58. turtle.select(3)
  59. end
  60.  
  61. turtle.turnRight()
  62. turtle.digDown()
  63. turtle.placeDown()
  64. turtle.forward()
  65. turtle.turnRight()
  66. counter2 = 0
  67. end
  68. counter3 = counter3 + 1
  69. counter = 0
  70. end
  71. end
  72.  
  73. while counter4 == 1 do
  74. local idString = turtle.inspectDown()
  75. print(idString)
  76. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement