6 lines
154 B
Lua
6 lines
154 B
Lua
|
|
|
||
|
|
--check if a file exists
|
||
|
|
function file_exists(name)
|
||
|
|
local f=io.open(name,"r")
|
||
|
|
if f~=nil then io.close(f) return true else return false end
|
||
|
|
end
|