I've started using Lua for school, and I'm wondering if it is possible to save a string to a txt file?
i.e
I have a string called shroom
and it equals mush
.
I have a file in the same folder as the .lua file called output.txt
.
I now want to save the string shroom
to output.txt
.
I then want to make a while loop and every 1 second save the string shroom
to the output.txt
file, overwriting the contents of output.txt
each time i save the string.
Is this possible in Lua? I've never used Lua before and I'm really confused at the moment..
Thanks :)