6 posts
Posted 29 August 2012 - 02:02 AM
I'm just getting my feet wet in LUA, and I'm finding remarkably hard to run something as simple as a batch file.
shell.setDir(ccSensors)
shell.run(monitor top dash_reactor)
The ingame help was unhelpful, and I read through the wiki. My plan was to eventually make this into a startup file so that I have a simple reactor readout.
1111 posts
Location
Portland OR
Posted 29 August 2012 - 02:18 AM
CC can only run Lua scripts not batch files. You would have to put together a translator to get the batch files to work(there might already be one in the programs section if I remember properly).
6 posts
Posted 29 August 2012 - 07:16 AM
CC can only run Lua scripts not batch files. You would have to put together a translator to get the batch files to work(there might already be one in the programs section if I remember properly).
Well, I wrote a two-line lua script that should change to the correct directory and then run the program with the arguments I gave.
1111 posts
Location
Portland OR
Posted 29 August 2012 - 07:30 AM
If the program is in Lua all you have to do to run it is use shell.run(). It uses absolute paths so..
shell.run("monitor", "top", "ccSensors/dash_reactor")
Make sure you're using the double quotes and comma's.
6 posts
Posted 30 August 2012 - 04:52 AM
If the program is in Lua all you have to do to run it is use shell.run(). It uses absolute paths so..
shell.run("monitor", "top", "ccSensors/dash_reactor")
Make sure you're using the double quotes and comma's.
Thanks, that worked.