Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function fileToTable(file)
- if fs.exists(file)~=true then
- print("file"..file.." not found")
- return(false)
- end
- fp=fs.open(file,"r")
- line={}
- i=1
- line[i]=fp.readLine()
- if line[i]==nil then return(false) end
- while line[i]~=nil do
- i=i+1
- line[i]=fp.readLine()
- end
- return(line)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement