Adobe-Runtime-Support icon indicating copy to clipboard operation
Adobe-Runtime-Support copied to clipboard

[Feature] Allow Embed of swf files on IOS

Open bobaoapae opened this issue 6 months ago • 2 comments

On IOS the use of [Embed] for swf files will cause the embed file to keep the as3 code, causing the swf to be impossible to load due to contains bytecode.

Would be ideal to the as3 code be stripped automatically and converted to native code as already happens when adding swf as resource on the package process

bobaoapae avatar May 12 '25 18:05 bobaoapae

Whilst this is a great idea, I'm not sure how practical it is, since embedding SWF files is done just as data, by the compiler, and none of that stuff knows (a) what you'll be running on, or (b) how to do the 'strip' thing. All the stripping stuff happens later at the packaging time...

If we were to do this, we'd need to parse all the SWFs, and check whether any of their data tags contain SWF files, and then do the extraction within those, and then re-embed the changed SWF into the original one, etc .. recursively.

Not sure whether there's a simpler/better way to do this, as I can see that it would be nice to improve the workflow here.. would you always be building everything in a "compile + package" step for an IPA file, separately from building (compiling + packaging) for AAB etc?

thanks

ajwfrost avatar May 12 '25 19:05 ajwfrost

For My use case, building everything in a "compile + package". Will work perfect, as I already do this anyway. But i suppose this will be a additional overhead to others if became the default.

If the first option of parse all the swf and check data tag recursive to strip and re-embed could be done I think will be the best one, as things will work automatically across all plataforms. Currently I have to keep code separed just to IOS to not use Embed.

bobaoapae avatar May 12 '25 20:05 bobaoapae