Not an individual file only those files for them I was using before Preloading off option and in runtime I used to get them to download. Still, I was getting errors sometimes after running exported build, So I decided to set all script preloading on In scripts there are some Texture references variable and textures preloading is off. Now what I am doing once textures are downloaded then only enabling the script component of entities.
After working on this issue I found that it’s like a Playcanvas exporting build file issue,
I have two same projects
After exporting the file from one project I get all scripts present in the _game-scripts.js file
but in another build, there are missing scripts present in the _game-scripts.js file so that’s why I am getting errors for those files
is this possible copy of the same project can produce a different _game-scripts.js file?
If the loading script order in project settings have changed then yes it could be different otherwise if it’s freshly forked, then no.
From this the ‘another build’ had preload unticked on the scripts and therefore the script.js files are in the assets folder. And the new build where you got game-script.js had the script assets preload ticked.
I’m a bit confused on your workflow as it sounds like you are combining two project exports which is not recommended unless you fully understand how the exported build is structured.
For example, GUIDs, asset ids, folder paths will all be different. The data in config.json can be very different.
If you have one build where the scripts are not preloaded and try to use another build game-scripts.js, that isn’t going to work because the config.json will have different paths for those scripts and different settings for loading on them too.
My recommendation is to not combine builds and upload a completely new, fresh build.