Sayomie550

Untitled

Jul 15th, 2012
34
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. local standby = 0
  2. local tree = 0
  3. local drop = 0
  4.  
  5. while turtle.detectDown() do
  6.  
  7. while redstone.getInput("back", true) do
  8. standby = 0
  9. tree = tree + 1
  10. drop = drop + 1
  11.  
  12. print( "Chopping Tree Number "..tree )
  13.  
  14. while turtle.detect() do
  15. turtle.dig()
  16. turtle.forward()
  17. end
  18.  
  19. while turtle.detectUp() do
  20. turtle.digUp()
  21. turtle.up()
  22. end
  23.  
  24. while not turtle.detectUp() and not turtle.detectDown() do
  25. turtle.down()
  26. end
  27.  
  28. redstone.setOutput("left", false)
  29.  
  30. turtle.back()
  31. turtle.select(1)
  32. turtle.place(1)
  33.  
  34. redstone.setOutput("left", true)
  35.  
  36. if drop == 5 then
  37. print( "Depositing Lumber to Obby Pipe" )
  38.  
  39. turtle.turnRight()
  40.  
  41. turtle.select(2)
  42. turtle.drop()
  43.  
  44. turtle.turnLeft()
  45.  
  46. drop = 0
  47. end
  48.  
  49. end
  50.  
  51. while not redstone.getInput("back", true) do
  52.  
  53. if standby == 0 then
  54. print( "Standby Mode" )
  55. standby = standby + 1
  56. tree = 0
  57. end
  58.  
  59. end
  60.  
  61. end
Advertisement
Add Comment
Please, Sign In to add comment