Posted 31 May 2013 - 05:59 PM
Hi, everyone!
The name is a bit of a lie…this program doesn't run files, it runs folders. First of all, this doesn't change anything you would normally use, so you don't have to worry about changing too much of the internals of your program. What is does is organise and deal with all the files in the folder, by using their extensions.
The extensions:
.lua : This will load a function into the environment that you can call like [programname]( )
.prc : This returns a function that resumes the coroutine of the file with the args input i.e [programname]( event, p1, p2, p3…. )
.bgp : This adds a process that will constantly run in the background, you can disable it from drawing to the screen, and stop it and of course vice versa
.txt : This will give a table called [filename] containing all the lines inside of the file
.img : This returns a function that will draw the image at the coords given i.e [programname]( 1, 1 ) would draw [programname] at 1, 1
.api : This loads the API like os.loadAPI( ) but only into the programs environment
.info : This will make a screen that draws the author name, program name, and program description ( not added yet )
.dwl : This will auto download from pastebin, and delete itself
.tmp : This will load like a lua file but delete itself, for example a firstrun program for a login system
.odr : This will change the order files are loaded in of a certain extension, for example you have 3 .api files, you would edit api.odr to rearange the order the API's are loaded in
The main code is in the file "code" and the program that runs it all can be called anything, although giving it an extension might mess some things up
Just call [foldername]/start if you download it as [foldername]/start and it will run "code" with all the things above done too.
This is useful because it means you don't have to clog up the start of your code with loading variables, because this does it for you, and more. I have made some more programs to go with this as well, one being a self extracting package maker and the other, a simple GUI for this that may help you create your programs.
It definitely helps organising your code and splitting it into multiple files
Screenshots will come if anyone makes a program with this, it isn't anything graphical apart from the GUI which is below:
The folder runner: http://pastebin.com/9r6gugyA
The package maker: http://pastebin.com/VDbNNz8V
The GUI: http://pastebin.com/BYxynS16
If you need any help with this, just ask, and I will make some sort of tutorial
The name is a bit of a lie…this program doesn't run files, it runs folders. First of all, this doesn't change anything you would normally use, so you don't have to worry about changing too much of the internals of your program. What is does is organise and deal with all the files in the folder, by using their extensions.
The extensions:
.lua : This will load a function into the environment that you can call like [programname]( )
.prc : This returns a function that resumes the coroutine of the file with the args input i.e [programname]( event, p1, p2, p3…. )
.bgp : This adds a process that will constantly run in the background, you can disable it from drawing to the screen, and stop it and of course vice versa
.txt : This will give a table called [filename] containing all the lines inside of the file
.img : This returns a function that will draw the image at the coords given i.e [programname]( 1, 1 ) would draw [programname] at 1, 1
.api : This loads the API like os.loadAPI( ) but only into the programs environment
.info : This will make a screen that draws the author name, program name, and program description ( not added yet )
.dwl : This will auto download from pastebin, and delete itself
.tmp : This will load like a lua file but delete itself, for example a firstrun program for a login system
.odr : This will change the order files are loaded in of a certain extension, for example you have 3 .api files, you would edit api.odr to rearange the order the API's are loaded in
The main code is in the file "code" and the program that runs it all can be called anything, although giving it an extension might mess some things up
Just call [foldername]/start if you download it as [foldername]/start and it will run "code" with all the things above done too.
This is useful because it means you don't have to clog up the start of your code with loading variables, because this does it for you, and more. I have made some more programs to go with this as well, one being a self extracting package maker and the other, a simple GUI for this that may help you create your programs.
It definitely helps organising your code and splitting it into multiple files
Screenshots will come if anyone makes a program with this, it isn't anything graphical apart from the GUI which is below:
The folder runner: http://pastebin.com/9r6gugyA
The package maker: http://pastebin.com/VDbNNz8V
The GUI: http://pastebin.com/BYxynS16
If you need any help with this, just ask, and I will make some sort of tutorial