Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --API loader only. Adapted from CraftOS pastebin code. Can be easily adapted to load your API
- --just change the raw.php?i= code and "t" to your pastebin code and api filename.
- 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("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 from http://pastebin.com/u/MrTurtle." )
- return
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement