Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --1x3 Meter Mine Shaft
- --Total number of meters the turtle will crawl
- print("How long of a tunnel would you like sir?")
- print("")
- term.write("Shaft Length: ")
- x = math.abs(tonumber(io.read()))
- while x>0 do
- --Detect & Mine for Gravel/Sand falling
- turtle.detect()
- if turtle.detect() == true then
- repeat
- turtle.dig()
- sleep(0.55)
- until turtle.detect() == false
- end
- --Move forward, dig up and down, completes row.
- turtle.forward()
- turtle.digUp()
- turtle.digDown()
- --Reduce Row Count
- x = x-1
- print(x.." Meters Left Sir!")
- end
- print("Done sir!")
- Fuel = turtle.getFuelLevel()
- print("Fuel Remaining: "..Fuel)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement