Advertisement
appleguy1999

treeFarm

Jul 18th, 2014
235
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. function main()
  2. turtle.select(1)
  3. if turtle.compare() then
  4. turtle.dig()
  5. turtle.forward()
  6. while turtle.detectUp() do
  7. turtle.digUp()
  8. turtle.up()
  9. end
  10. while turtle.down() do
  11. turtle.down()
  12. end
  13. turtle.back()
  14. turtle.select(2)
  15. turtle.place()
  16.  
  17. turtle.turnLeft()
  18. turtle.turnLeft()
  19.  
  20. turtle.select(1)
  21. a = turtle.getItemCount(1) - 1
  22. if a == -1 then
  23. a = 0
  24. end
  25. if a == 0 then
  26. a = 0
  27. end
  28. turtle.drop(a)
  29.  
  30. turtle.select(2)
  31. b = turtle.getItemCount(2) - 1
  32. if b == -1 then
  33. b = 0
  34. end
  35. if b == 0 then
  36. b = 0
  37. end
  38. turtle.drop(b)
  39.  
  40. turtle.select(3)
  41. turtle.drop()
  42.  
  43. turtle.turnLeft()
  44. turtle.turnLeft()
  45.  
  46. end
  47. sleep(120)
  48. turtle.suckUp()
  49. main()
  50. end
  51.  
  52. main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement