It seems the editor disallows setting properties of a script belonging to a js file that isn’t set to Preload?
Could it be possible to associate a hash of script names (and their configured properties) to their respective JS file paths, and when a scene loads, if the script is not found to be loaded yet due to the JS file path not loaded yet, be able to then load the script paths during runtime on demand and then apply the configured properties once loaded? Of course, this means such scripts will load LATER (ala asyncrounously), and may have issues with other scripts that do require sync timings with them ,but that’s up to the developer’s consideration if they choose to defer loading of such scripts.
Playcanvas doesn’t have such a feature?
Otherwise, how to assositate only loading certain assets (or specific set of preloads only…) for each scene? It seems the Preload setting is set globally per asset rather then per scene.
I noticed that so long as any asset (or js) file is set to preload, it will always load within ANY scene, even when it’s not used in the current scene setup. (Understandably, this may be “necessary” since scripts and other assets may be dynamically added to entities…, but there may be some cases where this isn’t necessarily the case).
Perhaps, having more 3 level preload options per asset would be better. Like: Preload Always, Preload If Used In Editor Scene, Don’t Preload. Having such options makes it much easier to automatically manage what to load per scene, rather than coding the process manually per scene.