cobra_tomtrein

Untitled

Jul 24th, 2016
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. print("file:")
  2. cryptfile = read()
  3. file = fs.open(cryptfile, "r")
  4. string = file.readLine()
  5. file.close()
  6. shell.run("delete", cryptfile)
  7. file = fs.open(cryptfile, "w")
  8. newstring = ""
  9. for i=1, #string do
  10. char = string.sub(text, i,i)
  11. if char = "&" then
  12. file.writeLine(newstring)
  13. newstring = ""
  14. else
  15. newstring = newstring..char
  16. end
  17. end
  18. file.writeLine(newstring)
  19. file.close()
Advertisement
Add Comment
Please, Sign In to add comment