Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function checkFuel()
- if turtle.getFuelLevel() < 10 then
- turtle.select(15)
- turtle.refuel(1)
- end
- end
- local function placeChestAndStoreItems()
- turtle.select(16)
- turtle.placeUp()
- for slot = 1, 14 do
- turtle.select(slot)
- turtle.dropUp()
- end
- end
- local function breakChest()
- turtle.select(16)
- turtle.digUp()
- end
- local function mineTunnel()
- checkFuel()
- for height = 1, 5 do
- if height > 1 then
- turtle.up()
- end
- turtle.dig()
- end
- for height = 1, 4 do
- turtle.down()
- end
- turtle.forward()
- end
- -- Main mining loop
- while true do
- mineTunnel()
- if turtle.getItemCount(14) > 0 then
- placeChestAndStoreItems()
- breakChest()
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement