I seek help, it is away3d related thing not Openfl!

Dear GODs of AS3.0 I hope you will hear my call!
I was trying to make an android project(apk)(AIR mobile AS3 app), using Flashdevelop (5.3.0) and AIR_SDK(28)and android sdk ( Revision 23.1.0 (December 2015)), my project uses AWAY3D + minimalcomps and it includes some .awd models ( I made two 3D models in blender then textured them and then imported them in AWAYBuilder and finally exported them as .AWD files) but I recieve the following ERROR!

Error: Error #2032: Stream Error. URL: app:/assets/mymodel.awd
at away3d.loaders::AssetLoader/onRetrievalFailed()[F:\away3d-core-fp11-4.1.6\src\away3d\loaders\AssetLoader.as:521]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at away3d.loaders.misc::SingleFileLoader/handleUrlLoaderError()[F:\away3d-core-fp11-4.1.6\src\away3d\loaders\misc\SingleFileLoader.as:411]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/onComplete()

NOTE: when I make an AS3 project(targeting flash player) everything works fine! and I don’t receive an ERROR!

I hope somebody can help me. I even considered to remake the 3D models!

Hi, I cannot help with the specifics of the error you are experiencing, I do have a suggestion you may wish to look further into which would get your air project working.

If you have a working .swf, that works in Flash Player (which it sounds like you do have), it is possible to package that .swf into an air .apk without having to recompile the project.

If you have the AIR SDK installed, the command to package that .swf into a .apk is something like this

adt -package -target apk-captive-runtime -storetype pkcs12 -keystore bin/sampleCert.p12 -storepass 1234 bin/new.apk bin/new-app.xml bin/myworking.swf -extdir bin

best to google the method for more info on it.

Perhaps the asset files you need were not packed into your APK when you used ADT, or were packed with a different name? Do you have a way to check?

7-Zip is capable of opening up an APK and checking what’s inside. (Note: it’ll break the APK if you change anything, so you’ll have to recompile.)

@player_03 Hi, I used 7-zip for opening up the APK file, in extracted folder there is an SWF file (it is not a working one though! when I clicked on it I saw error messages:

SecurityError: Error #2148: SWF file file:///test.swf cannot access local resource file:///AIR%5FAWAY3D%5FSectional%5FView/test/dist/test%2Dcaptive%2Druntime/assets/mymodel.awd. Only local-with-filesystem and trusted local SWF files may access local resources.
at flash.net::URLStream/load()
at flash.net::URLLoader/load()
at away3d.loaders.misc::SingleFileLoader/load()[F:\H.I.B.O.T.G.O.F\SFPALAS3\FLASH RELATED SOFTWARS\away3d-core-fp11-4.1.6\src\away3d\loaders\misc\SingleFileLoader.as:305]
at away3d.loaders::AssetLoader/retrieveDependency()[F:\H.I.B.O.T.G.O.F\SFPALAS3\FLASH RELATED SOFTWARS\away3d-core-fp11-4.1.6\src\away3d\loaders\AssetLoader.as:395]
at away3d.loaders::AssetLoader/load()[F:\H.I.B.O.T.G.O.F\SFPALAS3\FLASH RELATED SOFTWARS\away3d-core-fp11-4.1.6\src\away3d\loaders\AssetLoader.as:296]
at away3d.library::AssetLibraryBundle/loadResource()[F:\H.I.B.O.T.G.O.F\SFPALAS3\FLASH RELATED SOFTWARS\away3d-core-fp11-4.1.6\src\away3d\library\AssetLibraryBundle.as:578]
at away3d.library::AssetLibraryBundle/load()[F:\H.I.B.O.T.G.O.F\SFPALAS3\FLASH RELATED SOFTWARS\away3d-core-fp11-4.1.6\src\away3d\library\AssetLibraryBundle.as:354]
at away3d.loaders::Loader3D/load()[F:\H.I.B.O.T.G.O.F\SFPALAS3\FLASH RELATED SOFTWARS\away3d-core-fp11-4.1.6\src\away3d\loaders\Loader3D.as:257]
at Main/init()[F:\test\src\Main.as:77]
at Main()[F:\test\src\Main.as:59])

and there was no sign of AWD files in the asset folder.

AND TANX FOR YOUR TIP :slight_smile:

@singmajesty Hi, as “player_03” suggested, I used 7-Zip for having a look inside the APK, I described what I found there, please read my reply to “player_03” suggestion.


@Penry Tanx for your suggestion, I will try it and I will update u with the results.

Don’t bother trying to run the SWF, but you could try decompiling it to see if your AWD is inside.