this.runtime.getProjectFileUrl Question

0 favourites
  • 1 posts
  • I am using this.runtime.getProjectFileUrl in my plugin to load files that are included/imported into the project. Which works great in preview mode, but I am noticing some issues in the export that I would like to know if anyone else has some suggestions.

    When exporting to android it stopped loading the files, so I decided to export to html so I could easily see what may be going wrong.

    On the Html side the imported files are just exported in the root directory of the zip file generated by construct 3, not in any subfolder.

    When stepping through this.runtime.getProjectFileUrl function it sets the path to file to media/filename, which of course it can't find the file in that location.

    If I modify the path in the debugger it works.

    So my question is, when exporting projects that have imported files, should they be put in the appropriate subfolder by construct 3 or is that something we have to manage ?

    Note: I am also assuming that something similar is going on with the android export.

    Note Note: I know I could check if I'm in preview mode and not use that function and just the filename that it'll work since it's in the root.

    Any suggestions would be appreciated. Thanks...

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)