Copy directory from game folder to appdata

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • How do I copy a directory (folder) from the game folder to users appdata to be able to read and write back and forth.

    I have read the post on here including archived example but they are several years old and I can't make it work. I have also read Microsofts info about xCopy but can't make that work either.

    Question is - what am I missing and doing wrong here? :(

    Example of my latest try. It is the "data"-folder I am trying to copy to the "testFolder":
    Xcopy /E "E:\A_work_2019\Game\data" "C:\Users\Eva\AppData\Roaming\MMFapplications\testFolder\"

    ~Tiny~

  • Still can't figure out how to program it so it copies a whole folder.
    This is the path to the data-folder I which to copy: appPath$ +"\data"
    And this is the path to where it should be copied: appDataDirectory$ + "\MMFapplications\game\testFolder\"

    ~Tiny~

  • Hmm, I don't know. It doesn't seem like there's a way to do it with the File Object. There's another object called File-Folder Object, but I couldn't see a way there either. However I did finally find a way. It seems a little obtuse, and I feel like there must be another way, but it seems to work.

    Get the Directory Packer object from the Extension Manager. You can then pack a directory into a single file (press the "use expression" button to be able to use a dynamic source directory like appPath$ +"\data"). Then you can unpack file into a directory of your choice. I tried it - just copying a folder from desktop to another folder on desktop - and it seemed to work fine. I guess you probably will want to delete the file (using File object I guess) afterwards.

    Please login to see this picture.

    Please login to see this link.
    My Fusion Tools: Please login to see this link. | Please login to see this link. | Please login to see this link.

    Edited once, last by Volnaiskra (August 18, 2019 at 11:24 AM).

  • How are you trying to copy the folder?

    This is not how it works. You need to loop through files with the File-Folder object and copy each file. First you create the destination directory structure you want with the appDataDirectory$ + "\MMFapplications\game\testFolder\"

    Then you use File-Folder to loop through the local data folder, and then copy the files one by one. It runs its own browsing loop, so you can copy and create files on the fly. You can't simply choose a directory and copy it over, this is the route you will have to go.

    Game Launcher Creator V3 - Please login to see this link.
    Bespoke Software Development - Please login to see this link.
    Learn Clickteam Fusion 2.5 - Please login to see this link.

    Danny // Clickteam

  • This works but.....
    Seems the Directory Packer has a limit of 165 Mb because the unpacked directory never exceeds that although the directory to be moved is >700 Mb. This can of course be solved with splitting it up in parts.
    But #2, it takes a long time to pack and unpack even the 165 Mb.

    Good thing while searching for solutions is that I don't think I will need the moving of directory from within the game since it will be published through Steam. As far as I understand, I have studied their documentation only briefly, one can handle the installation of files and folders through their site. Will have to read more to be sure. :)

    Thanks a billion Volnaiskra for helping me out! And it was not a waste of time because I will need the various ideas in other projects. :)

    ~Tiny~

  • This problem has been reported/asked many time sinces 2009. It is too complex. It would be nice for Clickteam to address this issue of "copy a folder" It is a common task and for new users is hard to figure out. Just do a search on "copy directory" and you will get a list going back to 2009.

  • How are you trying to copy the folder?

    This is not how it works. You need to loop through files with the File-Folder object and copy each file. First you create the destination directory structure you want with the appDataDirectory$ + "\MMFapplications\game\testFolder\"

    Then you use File-Folder to loop through the local data folder, and then copy the files one by one. It runs its own browsing loop, so you can copy and create files on the fly. You can't simply choose a directory and copy it over, this is the route you will have to go.

    Thank you Danny for clearing it up.


    This problem has been reported/asked many time sinces 2009. It is too complex. It would be nice for Clickteam to address this issue of "copy a folder" It is a common task and for new users is hard to figure out. Just do a search on "copy directory" and you will get a list going back to 2009.

    Yes, I realised this when I searched for solutions. :)

    ~Tiny~

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!