Advertisement
9551

Untitled

Jun 22nd, 2021
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.31 KB | None | 0 0
  1. ----BFS API by elektrobom1/9551----
  2. local function getLine(file, line)
  3.     local l = 1
  4.     local out = {}
  5.     local file = fs.open(file, "r")
  6.     repeat
  7.         out[l] = file.readLine()
  8.         l = l + 1
  9.     until not out[l - 1]
  10.     file.close()
  11.     return out[line]
  12. end
  13.  
  14. return {getLine = getLine}
  15.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement