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

Simple File Manager v1.1 - Manage your file system!

Started by Gonow32, 29 April 2015 - 03:12 PM
Gonow32 #1
Posted 29 April 2015 - 05:12 PM
Simple File Manager


This new program will let you manage your files from any PC with the press of some keys. It makes file system management very easy if you are new to ComputerCraft.


Help

Press Enter to change folder or open a file.

Press B to go to the previous folder.

Press C to create a new file.

Press D to delete a file.

Press M to make a new folder.

Press R to go back to the root directory.

Use the arrow keys to navigate.


Changelog

Version 1.0

-Released the file manager

Version 1.1

-Fixed bugs

-Added a shortcut to the root directory


The Pastebin Code

Version 1.0

pastebin get XQGER3bP <filename>

Version 1.1

pastebin get TnmDhBhp <filename>


Please reply with any comments or suggestions you may have.
Edited on 02 May 2015 - 10:09 AM
Creator #2
Posted 29 April 2015 - 05:14 PM
Nice. Why don't you use mouse input?

And maybe some more GUI
Gonow32 #3
Posted 29 April 2015 - 05:16 PM
Good idea, I was just aiming to make a simple browser as a proof of concept but it turned out pretty nice so I decided to post it here. I may add this in the future if I make another version.
Creator #4
Posted 29 April 2015 - 05:22 PM
look at filex in my signature. You may learn something
Gonow32 #5
Posted 29 April 2015 - 05:25 PM
I just took a look, it looks really good, but how do you get the rendering of the file "icons" to work? Along with the actual clicking
Creator #6
Posted 29 April 2015 - 05:26 PM
what do you mean?
Gonow32 #7
Posted 29 April 2015 - 05:29 PM
How do you calculate where the boxes with filenames appear?
Also, what does it do when it runs out of screen space?
Exerro #8
Posted 29 April 2015 - 05:30 PM
I just took a look, it looks really good, but how do you get the rendering of the file "icons" to work? Along with the actual clicking

paintutils.drawImage() allows you to draw images loaded using paintutils.loadImage() which can load images created in the default paint program. The actual clicking is just down to math… you check if the click was within the area the icon is located. (sorry for butting in)
Creator #9
Posted 29 April 2015 - 05:32 PM
no problemo. The writing is done after the drawing of the icon. I take the file/folder name, cut it if it is too long and start printing on the next line. Only two lines supported.
Gonow32 #10
Posted 29 April 2015 - 05:33 PM
Don't worry about it :)/> Thanks for the advice though. This may be implemented if and when I make an update.
Creator #11
Posted 29 April 2015 - 05:35 PM
Sure. For how long do you lua? (grammar)
Gonow32 #12
Posted 29 April 2015 - 05:37 PM
If you mean how long have I used lua, it has been since I first got the mod, but I can't remember when that was :)/>
Creator #13
Posted 29 April 2015 - 05:40 PM
Yeah, I meant that. Is this your first program?
Gonow32 #14
Posted 29 April 2015 - 05:41 PM
No, I've made a few but I've never posted them on here.
Gonow32 #15
Posted 02 May 2015 - 11:48 AM
Simple File Manager v1.1 has been released fixing a major bug that meant that the browser thought everything was in the root directory, meaning you could not navigate to anything past one folder level or run any programs inside folders. This has been fixed in the latest version with a feature letting you jump back to the root directory. To access this, press R!