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

programmer turtle

Started by tribal1511, 07 October 2012 - 01:48 AM
tribal1511 #1
Posted 07 October 2012 - 03:48 AM
ok so i have looked and looked and maybe im missing it but i cant find an example anywhere
so here goes basically i have a password protected door now i dont want players breaking the computer but if they do i have a turtle next to it to place another computer the problem is copying the startup program from the turtle back onto the computer so it has the password program again
any help would be great thanks
savior67 #2
Posted 07 October 2012 - 04:44 AM
Alright, I had an issue similar to this yesterday as I attempted to figure out how to install a gps program on computers through turtles. What I discovered was that files can't be transferred directly from the turtle to the computer, however the turtle can recognize the computer as a peripheral and perform some commands such as shutdown and reboot (http://computercraft.info/wiki/index.php?title=Peripheral_(API)). Instead I had the turtle place a disk drive, drop the floppy in, go next to the computer, turn it on, grab the disk back out, break the disk drive and then continue on its way. If you choose to use this method, don't forget to include an fs.copy(thisFile,thatFile) to save your program from the floppy to the computer on startup.