Advertisement
McKillopBK

EnderMineRight

Dec 30th, 2017
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.24 KB | None | 0 0
  1. local times = 0
  2. local j = 0
  3.  
  4. function Mine()
  5. while turtle.detect() == true do
  6. turtle.dig()
  7. sleep(0.50)
  8. end
  9. turtle.forward()
  10. sleep(0.50)
  11. while turtle.detectUp() == true do
  12. turtle.digUp()
  13. sleep(0.50)
  14. end
  15. turtle.digDown()
  16. end
  17.  
  18. function Place(SlotNum)
  19. turtle.select(SlotNum)
  20. turtle.back()
  21. turtle.placeUp()
  22. turtle.forward()
  23. end
  24.  
  25. function PlaceChest(SlotNum)
  26. turtle.select(SlotNum)
  27. turtle.back()
  28. turtle.placeDown()
  29. for I=1, 14 do
  30. turtle.select(I)
  31. turtle.dropDown()
  32. end
  33. turtle.forward()
  34. end
  35.  
  36. term.write("How long? ")
  37. times = read()
  38.  
  39. function Digger()
  40. for i=1, times do
  41. j = j+1
  42. Mine()
  43. if j == 9 then
  44. Place(16)
  45. j = 0
  46. end
  47. end
  48. end
  49.  
  50. function MoveLeft()
  51. turtle.turnLeft()
  52. Mine()
  53. Mine()
  54. Place(16)
  55. PlaceChest(15)
  56. term.write("Sleeping for 20 Seconds")
  57. sleep(20)
  58. turtle.select(15)
  59. turtle.digDown()
  60. Mine()
  61. Mine()
  62. turtle.turnLeft()
  63. end
  64.  
  65. function MoveRight()
  66. turtle.turnRight()
  67. Mine()
  68. Mine()
  69. Place(16)
  70. Mine()
  71. turtle.turnRight()
  72. end
  73.  
  74. term.write("How many double shafts? ")
  75. duration = read()
  76. for i=1, duration do
  77. Digger()
  78. MoveRight()
  79. Digger()
  80. MoveLeft()
  81. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement