Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if turtle.getFuelLevel() == 0 then
- turtle.select(1)
- turtle.refuel(4)
- end
- local function DigLine(wl)
- local moved = 0
- for i=1, tonumber(wl) do
- if turtle.detectDown() then
- print("detect block")
- turtle.digDown()
- else
- print("no block")
- end
- turtle.forward()
- moved = moved + 1
- print("moved:"..tostring(moved))
- end
- for i=1, moved do
- turtle.back()
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment