I'm trying to have my game save data to a text file out of a list for use later: I've tried using Panther "write __ to __ file" but I can't find the txt file after I've run my scripts. I've tried specifying the location (e.g. C:\scratch programs\data.txt) and I still can't find the .txt file. Any thoughts would be appreciated.
Offline
hart20 wrote:
I'm trying to have my game save data to a text file out of a list for use later: I've tried using Panther "write __ to __ file" but I can't find the txt file after I've run my scripts. I've tried specifying the location (e.g. C:\scratch programs\data.txt) and I still can't find the .txt file. Any thoughts would be appreciated.
You can actually show a list on the stage, right click, and select import or export.
Offline
^^ Both Zparx and AtomicBawm3 are right; but unfortunately, reading and writing to a file (as is a standard function of most modern programming languages) can't be performed at runtime, only manually by the user within Scratch. It is useful if you have data stored in a list (for example, a series of numbers representing a level) and you want to move it into another project, or post it where other users can access it.
That being said, you mentioned Panther... I believe there's more flexibility involving reading/writing to files with that mod, as well as some others. If I were you, I'd ask sparks, who seems to be in charge of Panther at the moment. He'll be sure to answer your question.
Offline