Difference between revisions of "Fs.getDrive"
From ComputerCraft Wiki
(Create page) |
m (Moved to CAT:LuaCoreFunctions) |
||
| Line 13: | Line 13: | ||
}} | }} | ||
}} | }} | ||
| + | |||
| + | [[Category:Lua_Core_Functions]] | ||
Revision as of 18:46, 28 November 2012
| Returns the storage medium holding a path, or nil if the path does not exist | |
| Syntax | fs.getDrive(string path) |
| Returns | string the type of storage medium holding the path, as of ComputerCraft 1.3 one of "rom" or "hdd"[1] |
| Part of | ComputerCraft |
| API | fs |
Examples
| Checks that the standard "startup" file is stored in ROM | |
| Code |
print(fs.getDrive("rom/startup"))
|
| Output | rom |