GreatProgPluto's Forum Posts

  • 4 posts
  • >

    > > But is it possible, for example, to make a text file that I can save and then access from Windows afterwards? E.G I make a text file with my game, save it to the desktop and then I can open it up in Notepad?

    > >

    >

    > I know i am answering an old question but it might help for someone in the future,

    >

    > If you add the "Browser" object to the project, there is an action you can add to the event sheet called "Invoke download of string", which is usually reserved for downloading .JSON files for all sorts of things, now im not too sure if this feature is intended, but if you want the game to download regular .TXT with the text of your choice, simply add the string you want in the "String" box, change the MIME type to "text/plain", and replace in the filename the ".json" to ".txt", hope that helps!

    >

    Hi GreatProgPluto

    I stumbled across this thread and your reply while trying to achieve this myself. Not sure if my goal is the same, but currently my project is to learn French and when I add new data , I have to open the text file from within the project via construct 2 add the new data save it back and then re-compile the project for my own use.

    Currently I had added quite a lot of data to these text files and it becomes very time consuming to do it this way. Can you use this method you have stated for this purpose and if so how, as I have tried to do as you have stated but I cannot get it to work

    my method works well on a browser (Chrome and such), but on a desktop, you have to use a different method in order to get it to work, and this method is for outputting files rather than inputting them.

    As for your project, I suggest you try to keep the text file outside the program and to access it by requesting the program to find the text file and phrase it to your liking, this way, you can update the text file, without having to recompile each time you want to change the text.

    Good luck on your French!

  • But is it possible, for example, to make a text file that I can save and then access from Windows afterwards? E.G I make a text file with my game, save it to the desktop and then I can open it up in Notepad?

    I know i am answering an old question but it might help for someone in the future,

    If you add the "Browser" object to the project, there is an action you can add to the event sheet called "Invoke download of string", which is usually reserved for downloading .JSON files for all sorts of things, now im not too sure if this feature is intended, but if you want the game to download regular .TXT with the text of your choice, simply add the string you want in the "String" box, change the MIME type to "text/plain", and replace in the filename the ".json" to ".txt", hope that helps!

  • Congratulations to everyone who was involved!

    this was a fascinating journey, and an amazing experience!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hello I am Great Progress Pluto, and i'm excited to see all the possibilities there is to have with Construct 2.

  • 4 posts