Provide a mechanism to copy user supllied files to program folders (Windows)


  • *
  • Posts: 230
So, I am creating a program where a user can choose certain sound to play during certain event. What I would like to add is the option for user to supply his own sound file and add that to the selection list. Now, I look around in several different software for reference and I found one that I believe would fit with how Stencyl works the most.

In AGK 2, users are only allowed file access in two places: the readable folder and writable folder. The readable folder is basically the game folder and any folder in it. Writable folder is where you can write files and it is also included as one of the readable folder. Typically, write folder would be located in "c:\users\<your username>\App Data\Local\AGK Apps\<your game name>". This, I feel, is similar to how Stencyl's Windows app work.

Now, AGK 2 has a function called 'ChooseRawFile', which would display an 'Open  File' dialog where you can choose a file. The file you choose would then be copied to the writable folder and the function will return the file name. The file will then be available to your program just like any pre-existing resources.

I would love to see similar mechanism incorporated into Stencyl and I believe it would not violate the rule by which Stencyl works.
::: It's never too late, unless you're dead. Maybe not even then. :::