Jump to content




Where is fs API (or fs.complete) defined?


  • You cannot reply to this topic
6 replies to this topic

#1 Selim

  • Members
  • 189 posts
  • LocationHiding in Online Storage

Posted 24 January 2016 - 10:19 PM

Is it safe to assume that the fs API is defined the Java end of ComputerCraft? I have been looking around in the Lua files for it, but I have been unsuccessful.
I was hoping to be able to back-port the auto-complete functions of modern CC back to earlier versions, but if fs.complete is defined in Java I am not sure it is possible without re-writing it.

Edited by Selim, 24 January 2016 - 10:36 PM.


#2 H4X0RZ

  • Members
  • 1,315 posts
  • LocationGermany

Posted 24 January 2016 - 10:23 PM

the fs api is made in java. but fs.complete is just a specialized version of the "original" complete function (not sure what it was) i believe.

Edited by H4X0RZ, 24 January 2016 - 10:24 PM.


#3 Selim

  • Members
  • 189 posts
  • LocationHiding in Online Storage

Posted 24 January 2016 - 10:31 PM

Might you mean textutils.complete? That is the only one I have found so far in the Lua other than shell.complete which depends on fs.complete.

Edited by Selim, 24 January 2016 - 10:35 PM.


#4 Lupus590

  • Members
  • 2,028 posts
  • LocationUK

Posted 24 January 2016 - 10:40 PM

you may find parts of the fs api in bios.lua, but most of it will be in java

#5 Selim

  • Members
  • 189 posts
  • LocationHiding in Online Storage

Posted 24 January 2016 - 10:43 PM

View PostLupus590, on 24 January 2016 - 10:40 PM, said:

you may find parts of the fs api in bios.lua, but most of it will be in java
Ha ha! Thank you! fs.complete is defined within bios.lua!

Now I just need to make it all work as intended...

Edited by Selim, 24 January 2016 - 10:45 PM.


#6 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 24 January 2016 - 10:46 PM

FWIW, here's a clone of fs.find() I scribbled out some time ago.

#7 Selim

  • Members
  • 189 posts
  • LocationHiding in Online Storage

Posted 24 January 2016 - 11:22 PM

Ok, all is good now. The functions have been back-ported.
In case anyone wants to try it, more info here:
http://www.computerc...orage-and-more/

Edited by Bomb Bloke, 25 January 2016 - 01:12 AM.
No short URLs, thank you.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users