Files
File Exists
Definition
fileExists(path: string) -> booleanUsage example
print(fileExists('my_file.lua'))
-- trueSource code
function fileExists(path)
local f = io.open(path, 'r')
return f ~= nil and io.close(f)
endGet Files Recursively
Definition
getFilesRecursive(path: string, maxDepth: integer) -> table--
-- getFilesRecursive()
--
-- @param string path The starting path: Default: '.' (mod's root folder)
-- @param integer maxDepth The maximum depth allowed. Default: -1 (unlimited)
--
getFilesRecursive('.', -1)Usage example
Source code
Get Folders Recursively
Definition
Usage example
Source code
Last updated