Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print("How long to mine?")
- farest = tonumber(read())
- print("If i stop at HOME make sure i have fule in the first sloot")
- digLenth = 0
- function GoHome()
- turtle.turnLeft()
- turtle.turnLeft()
- while (digLenth) do
- turtle.forward()
- end
- end
- function Emty()
- for i = 2, 16, 1 do
- turtle.drop(turtle.getItemCount())
- end
- end
- for i = 1, farest, 1 do
- fullSlots = 0
- for j = 1, 16, 1 do
- turtle.select(j)
- if (turtle.getItemCount() >= 64) then
- fullSlots = fullSlots + 1
- end
- end
- if(fullSlots >= 15) then
- GoHome()
- Emty()
- end
- if (turtle.getFuelLevel() == 0) then
- for j = 1, 16, 1 do
- turtle.select(j)
- turtle.refuel()
- if (turtle.getFuelLevel() == 0) then
- break
- end
- end
- end
- turtle.dig()
- turtle.forward()
- turtle.digUp()
- digLenth = digLenth + 1
- end
- print("return home?")
- if (read() == "Yes") then
- GoHome()
- end
Add Comment
Please, Sign In to add comment