Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print( "Mettre des barrels/chests dans le Slot 1..." )
- print( "...un stack de sappling dans le Slot 2" )
- print( "...du Bonemeal dans le slot 3")
- print( "Appuyer une touche pour continuer..." )
- os.pullEvent("char")
- lvl = 1
- turtle.digDown()
- turtle.select(1)
- turtle.placeDown()
- local function ascend()
- turtle.up()
- lvl = lvl + 1
- end
- local function descend()
- turtle.down()
- lvl = lvl - 1
- end
- local function grow()
- turtle.select(2)
- turtle.place()
- turtle.select(3)
- turtle.place()
- -- ascend()
- end
- local function chop()
- turtle.select(4)
- turtle.dig()
- turtle.forward()
- while turtle.detectUp() == true do
- print("lvl"..lvl)
- -- read()
- turtle.digUp()
- ascend()
- end
- print("lvl "..lvl.." max")
- while lvl > 1 do
- while turtle.detectDown() == true do
- print("detect down")
- turtle.digDown()
- end
- while turtle.detectDown() == false do
- descend()
- end
- end
- turtle.back()
- end
- local function unload()
- for i = 4, 16 do
- turtle.select(i)
- turtle.dropDown()
- end
- end
- for t = 1, 64 do
- grow()
- chop()
- unload()
- end
Advertisement
Add Comment
Please, Sign In to add comment