Advertisement
Guest User

quarry

a guest
Jul 29th, 2015
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.19 KB | None | 0 0
  1. -- 3 Land Marks, Quarry, Energy Tesseract
  2. -- Dump Enderchest, fuel Enderchest
  3.  
  4. function mFor()
  5.   turtle.detect()
  6.   if turtle.detect() == true then
  7.     turtle.select(16)
  8.     turtle.dig()
  9.     turtle.dropUp()
  10.     turtle.select(1)
  11.   end
  12.   turtle.forward()
  13. end
  14.  
  15. function quarryPlace()
  16.   turtle.select(2)
  17.   turtle.place()
  18.   turtle.select(3)
  19.   turtle.turnLeft()
  20.   turtle.forward()
  21.   turtle.turnRight()
  22.   turtle.place()
  23.   turtle.turnRight()
  24.   turtle.forward()
  25.   turtle.turnLeft()
  26.   turtle.up()
  27.   turtle.select(4)
  28.   turtle.place()
  29.   turtle.down()
  30.   turtle.select(5)
  31.   turtle.placeUp()
  32.   turtle.select(2)
  33.   turtle.suckUp(1)
  34.   turtle.refuel()
  35.   turtle.select(5)
  36.   turtle.digUp()
  37. end
  38.  
  39. turtle.select(1)
  40. turtle.place()
  41.  
  42. function forBack()
  43.  
  44. local dis = 0
  45.  
  46. while dis < 63 do
  47.   mFor()
  48.   dis = dis + 1
  49. end
  50. turtle.select(1)
  51. turtle.place()
  52.  
  53. turtle.turnLeft()
  54. turtle.turnLeft()
  55.  
  56. while dis > 0 do
  57.   mFor()
  58.   dis = dis - 1
  59. end
  60. end
  61.  
  62. function quarryBreak()
  63.   turtle.select(2)
  64.   turtle.dig()
  65.   turtle.forward()
  66.   turtle.turnLeft()
  67.   turtle.select(3)
  68.   turtle.dig()
  69.   turtle.select(4)
  70.   turtle.digUp()
  71.   turtle.turnLeft()
  72.   turtle.back()
  73. end
  74.  
  75.  
  76. -- Actual Running Program
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement