Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --LightningVoltrix
- --------------------------------------------------------------------------------------------------
- -- ___ ___ __ ____________ __ ___ ___ __ --
- -- |:| /:/ /::\ |::::::::::| /::\ |::\ /::| /::\ --
- -- |:| /:/ /::::\ |::/¨¨¨¨¨¨¨¨ /::::\ |:::\ /:::| /::::\ --
- -- |:| /:/ /::/\::\ |::| /::/\::\ |::::\/::::| /::/\::\ --
- -- |:|/:/ /::/__\::\ |::\________ /::/__\::\ |::|\::/|::| /::/__\::\ --
- -- |:|\:\ /::/::::\::\ |::::::::::| /::/::::\::\ |::| \/ |::| /::/::::\::\ --
- -- |:| \:\ /::/¨¨¨¨¨¨\::\ ¨¨¨¨¨¨¨¨\::| /::/¨¨¨¨¨¨\::\ |::| |::| /::/¨¨¨¨¨¨\::\ --
- -- |:| \:\ /::/ \::\ /::| /::/ \::\ |::| |::| /::/ \::\ --
- -- |:| \:\ /::/ \::\ |::::::::::| /::/ \::\ |::| |::| /::/ \::\ --
- -- ¨¨¨ ¨¨¨ ¨¨¨ ¨¨¨ ¨¨¨¨¨¨¨¨¨¨¨¨ ¨¨¨ ¨¨¨ ¨¨¨¨ ¨¨¨¨ ¨¨¨ ¨¨¨ --
- ----------------------------------------------------------------------------------------Scripts---
- ------------------------------------------Lumberjack Turtle---------------------------------------
- --------------------------------------------------------------------------------------------------
- function Move(where)
- if turtle.getFuelLevel() == 0 then
- print("Please put some fuel in the last slot")
- repeat
- turtle.select(16)
- turtle.refuel()
- sleep(2)
- until turtle.getFuelLevel() ~= 0
- else
- if where == "f" then
- turtle.forward()
- elseif where == "b" then
- turtle.back()
- elseif where == "u" then
- turtle.up()
- elseif where == "d" then
- turtle.down()
- end
- end
- end
- function Chest()
- turtle.select(4)
- turtle.turnLeft()
- turtle.drop()
- turtle.suck()
- turtle.turnRight()
- for i=1,3 do
- turtle.select(i)
- turtle.dropDown()
- end
- turtle.select(1)
- end
- function Check()
- turtle.digUp()
- Move("u")
- if turtle.detect() then
- Move("d")
- return true
- else
- Move("d")
- return false
- end
- end
- function Cut()
- turtle.dig()
- Move("f")
- repeat
- t = turtle.digUp()
- Move("u")
- until t == false
- repeat
- Move("d")
- until turtle.detectDown()
- Move("b")
- turtle.select(4)
- turtle.place()
- turtle.select(1)
- end
- while true do
- if Check() then
- Cut()
- Chest()
- end
- sleep(30)
- end
Advertisement
Add Comment
Please, Sign In to add comment