Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function fuelCheck()
- print(turtle.getFuelLevel())
- if turtle.getFuelLevel() < 50 then
- turtle.select(16)
- turtle.refuel()
- print(turtle.getFuelLevel())
- end
- end
- local function startpos()
- while (not rs.getInput("bottom")) do
- while not turtle.down() do turtle.digDown() end
- end
- end
- local function replant()
- turtle.select(1)
- turtle.dig()
- turtle.place()
- end
- local function cut()
- while (not rs.getInput("top")) do
- turtle.dig()
- while not turtle.up() do turtle.digUp() end
- end
- end
- local function checktree()
- while (turtle.up() and turtle.up()) do
- startpos()
- sleep(120)
- end
- end
- while true do
- fuelCheck()
- startpos()
- checktree()
- cut()
- startpos()
- replant()
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement