2 posts
Posted 31 December 2012 - 02:23 AM
Is it possible to open a .bat file from my turtle ? And how ?
I'm new to this mod and I just wanted to know if it was possible. Thank you.
278 posts
Posted 31 December 2012 - 02:47 AM
Well, you could write an interpreter… No default support. Sorry but you might just have to use Lua.
2088 posts
Location
South Africa
Posted 31 December 2012 - 02:57 AM
If your on windows then create a file called "toApis.bat" then in there put copy "PathToYourApi_ThisShouldBeFromYourAcctualComputerDrive" "PathToYourAPIFolder"
then to run that i think its either dofile "toApis.bat" or shell.run("toApis.bat"). PS. This may not work if computercraft doesn't support batch files any more
I have no idea what the hell you're smoking. ComputerCraft has never supported, and will never support, executing batch files. Especially not things that could touch files outside of the computer's directory itself.
2 posts
Posted 31 December 2012 - 03:21 AM
Can I do it using lua ? How ?
2005 posts
Posted 01 January 2013 - 12:10 AM
You can have a startup program, named startup, on your turtle. It will run whenever the turtle is turned on, unless you have a startup disk in a drive adjacent to the turtle.
If you're asking how to write a bat file interpreter…yeah, that's a bit trickier.