This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
badcode9's profile picture

How to Add Files to Turtle Rom Folder CC [1.75]

Started by badcode9, 24 January 2016 - 06:50 PM
badcode9 #1
Posted 24 January 2016 - 07:50 PM
Hi, does anyone know how I can add files to the rom folder of turtles (and secondarily, computers) with CC 1.75 on a server? Specifically, I am trying to add the Robust Turtle API.

I have followed the instructions in the API page, checked the forums and overall, Google'd the mess out of this question, but everything is pointing me to the exact same place, and that is to add the file to: ../mods/computercraft.zip/lua/rom/apis/turtle.

However I do not have a computercraft.zip file, and when I create one along with the specified child directories, it does not seem to affect the game.

I have been able to find how to add files directly to an instance of a computer/turtle, which is handy. But I'm not sure that it will allow me to use the specified file as an API. Maybe that's a second question someone can help me answer :)/>

Thanks!
MKlegoman357 #2
Posted 24 January 2016 - 08:15 PM
If you only want the API to be available to a specific turtle or computer you can simply download that API to the turtle/computer, usually through pastebin. To load the api you would use 'os.loadAPI( path )' function:


--# the first argument is the path to the API file
os.loadAPI("example_api")

--# you can then use the API's provided functions like so:
example_api.foo()

Also, note that the Robust Turtle API is a very old API made for an older version of ComputerCraft. You can search for programs and APIs here on forums, specifically on the Programs sub-forum. Turtle programs. Various APIs.
valithor #3
Posted 24 January 2016 - 08:32 PM
If you wanted to add it to all computers, then you should make use of resourcepacks: http://www.computercraft.info/forums2/index.php?/topic/14049-how-to-make-and-install-lua-resource-packs/
badcode9 #4
Posted 24 January 2016 - 09:34 PM
Amazing. Thank you both very much!