Write new JSON files within the gamefiles

0 favourites
  • 3 posts
From the Asset Store
Kids Game
$49 USD
New Sounds Added Update: 115 new sound effects added for no additional cost!
  • Hi everyone,

    so I've tried discord and the "how do I..." Forum, but can't find any help. Most likely because my problem isn't solvable with the basic Construct functions (?).

    So maybe you guys can help me.

    I'm trying to find a way to save arrays as JSON file within the game files. I found a possible way to do it with the FileSystem, but this only works when the user previously picked the file path. Since I want users to create levels and save them as JSON files within the game files, i find it very inconvenient, if they have to locate the correct file location manually first, and it also would make it unnecessary complicated to show all created levels since they are not located at the same place. So it would be great if i can write and read files in a preset folder path.

    So since it's not possible with the FileSystem (or at least i couldn't figure it out properly), i thought it might be possible with JavaScript itself?

    Any help on this would be great <3

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I'm not too familiar with the file system plugin, but it looks like it's got some browser based security restrictions.

    The old way would be to just use nw.js which also has access to the local disk, but that only applies to running as a local executable.

  • You are right, it works completely fine with nw.js.

    I was hoping for webview2 to work as well, since a desktop application. But I've just read that webview2 is running through MS Edge, so it's still treated as browser.

    Thanks for your help

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)