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(1) local response = http.get("http://pastebin.com/raw.php?i= e0UksEtT") if response then print("Great Success.") local data = response.readAll() response.close() local file = fs.open("t", "w") file.write(data) 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 --room clearer function layer(l,w) local alternate = "right" for i =1, w do t.forward(l) if alternate == "right" and i~=w then t.right() t.forward() t.right() alternate = "left" elseif alternate == "left" and i~=w then t.left() t.forward() t.left() alternate = "right" elseif alternate == "left" and i==w then t.right() t.forward(w-1) t.right() elseif alternate == "right" and i==w then t.strafeLeft(w-1) t.back(l) end end end term.clear() term.setCursorPos(1,1) print("Room Clearer Turtle. ") print("length?") local length = (t.readNum()-1) print("width?") local width = t.readNum() print("height of room?") local height = t.readNum() t.forward() t.strafeLeft(width/2) for i=1, height do layer(length,width) --does not move up after digging last layer if i ~= height then t.up() end end t.sDown(height-1) t.sStrafeRight(width/2)