Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print("Loading Robust Turtle API...")
- local load = os.loadAPI("t")
- if load then
- print("Robust Turtle API loaded.")
- else
- print("Robust Turtle API not found in the root directory with filename t")
- print("Attempting to download as t from pastebin...")
- os.sleep(2)
- local response = http.get("http://pastebin.com/raw.php?i= e0UksEtT")
- if response then
- print( "Success." )
- local sResponse = response.readAll()
- response.close()
- local file = fs.open( "t", "w" )
- file.write( sResponse )
- file.close()
- print( "Downloaded as t")
- load = os.loadAPI("t")
- if load then
- print("Robust Turtle API installed & loaded.")
- end
- else
- print( "Download Failed. Please Install Manually." )
- return
- end
- end
- --Mineshaft Digging Turtle. Places Torches every 6 blocks.
- --Places Cobblestone when it does not detect blocks beneath it,
- --creating bridges through caverns. Use any frequently occurring
- --block. Cobblestone not required, just a block that doesn't fall
- --that your turtle will be mining plenty of.
- print("place torches in slot 1 and cobblestone in slot 2")
- print("dig down how far?")
- local dist = t.readNum()
- print("turtle fuel level is "..turtle.getFuelLevel()..", ok?")
- read()
- local torch =0
- for i=1, dist do
- t.forward()
- t.digUp()
- t.down()
- if not turtle.detectDown() then
- t.placeDown(2)
- end
- torch = torch+1
- if torch == 6 then
- t.right()
- if not turtle.detect() then
- turtle.place(2)
- end
- turtle.up()
- t.place(1)
- t.left()
- t.down()
- torch = 0
- end
- end
- turtle.down()
- for i=1, dist do
- turtle.back()
- t.up()
- end
- turtle.back()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement