xFlyDr

Advanced Trees

May 23rd, 2019
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.35 KB | None | 0 0
  1. local rows =29
  2. t=turtle
  3.  
  4.  
  5. t.select(16)
  6.  
  7. for i=1, rows do
  8. t.turnLeft()
  9. t.place()
  10. t.turnRight()
  11. t.turnRight()
  12. t.place()
  13. t.turnLeft()
  14. if i<=rows-1 then
  15. t.forward()
  16. end
  17. end
  18.  
  19.  
  20. t.turnLeft()
  21. t.turnLeft()
  22.  
  23. for i=1, rows-1 do
  24. t.forward()
  25. end
  26.  
  27. t.turnLeft()
  28. t.turnLeft()
  29.  
  30. t.up()
  31.  
  32. while 1==1 do
  33.  
  34. os.sleep(60)
  35. t.select(15)
  36. t.refuel(20)
  37. print(turtle.getFuelLevel())
  38. t.select(16)
  39. for i=1, rows do
  40. t.turnLeft()
  41.  
  42. if turtle.detect() then
  43. t.select(15)
  44. t.down()
  45. t.dig()
  46. t.forward()
  47. h=1
  48. while turtle.detectUp() do--
  49. h=h+1
  50. t.digUp()
  51. t.up()
  52. end --close while
  53. for i=1, h do--
  54. t.down()
  55. end --close for
  56. t.back()
  57. end
  58. t.select(16)
  59. t.place()
  60. t.turnRight()
  61. t.turnRight()
  62. t.up()
  63. if turtle.detect() then
  64. t.select(15)
  65. t.down()
  66. t.dig()
  67. t.forward()
  68. h=1
  69. while turtle.detectUp() do--
  70. h=h+1
  71. t.digUp()
  72. t.up()
  73. end--close whilke
  74. for i=1, h do--
  75. t.down()
  76. end--close ofr
  77. t.back()
  78. end
  79.  
  80. t.select(16)
  81. t.place()
  82. t.up()
  83. t.turnLeft()
  84.  
  85. if i<=rows-1 then
  86. t.forward()
  87. elseif i==rows then
  88. t.turnLeft()
  89. t.turnLeft()
  90.  
  91. for i=1, rows-1 do
  92. t.forward()
  93. end
  94. t.turnLeft()
  95. t.turnLeft()
  96. end
  97. end
  98. end
Add Comment
Please, Sign In to add comment