How do I set up my resources so that they get compiled with my project and the Loader3D is able to find everything? I’ve tried putting my resources in a directory called /res in the same place as my source tree, but these aren’t being copied to my build directory and so my code fails when it tries to resolve the URL.
Parsers.enableAllBundled();
var loader:Loader3D = new Loader3D(true, null);
var token:AssetLoaderToken = loader.load(new URLRequest("res/room.dae"));
token.addEventListener(AssetEvent.ASSET_COMPLETE, onAssetComplete);
When I use a full path name the loader can find it, but I can’t use this when I publish:
var token:AssetLoaderToken = loader.load(new URLRequest("C:/dev/myProj/res/room.dae"));
I also came across an article saying I should embed it, but it relied on a class called away3d.loader.Collada which no longer seems to be part of the away3d distro
[Embed (source="../art/room.dae", mimeType="application/octet-stream")]
public static const DAEFILE:Class;
How can I organize my project so that I can find and load my Collada files both during development and after I’ve published my app?