• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

No more Uncompiled ActionScript warning on iOS with AIR 3?

Engaged ,
Nov 06, 2011 Nov 06, 2011

Copy link to clipboard

Copied

Hi!

With previous versions of Air on iOS, when I was loading an external SWF that was containing library symbols using linkage names, I was getting a popup message saying that uncompiled actionscript was not allowed on this system. It was really a pain, since it was not possible to use the class system of AS3 to instanciate several instances of the same object. So I had to create all the instances on my stage in the IDE, and manipulate them using GetChildByName() in my pure AS3 code.

Today I made some tests, and didn't realize that my SWF file was containing some symbols with a linkage name. And it was working fine! With previous versions of AIR, I was getting an instant warning message, and the app was stuck.

So I made further tests, and now I can load an external SWF even containing AS3 code on the timeline, and it works!! Really I don't know what to think. This is wonderful news, because now we can really implement iOS apps the same way we would on any other platform. But I also know that this previous behaviour was due to some security reasons, to prevent apps made with AIR to download some external malicious code contained in an external SWF.

So my question is: is it allowed by Apple, or will my app be rejected? Or maybe this limitation is now applied to really external SWF (like something hosted on a remote server), and AS code is accepted for SWF files that are packaged locally into the app?

I'd really like to have Adobe employee's feedback on this, please.

Thank you!

Frédéric

TOPICS
Development

Views

1.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 06, 2011 Nov 06, 2011

Copy link to clipboard

Copied

I will probably test this for myself anyway, but can you check to see what happens if you build as AIR 2.7? Which version are you currently trying?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Nov 06, 2011 Nov 06, 2011

Copy link to clipboard

Copied

Hmm good idea Colin. I reverted back to AIR 2.7 (just by renaming my Flex folder, I hope this is enough to clean previous built code), and it still works!

I can't remember when I had the "Uncompiled ActionScript" issue, maybe it was with 2.6? Unfortunately I can't go older than 2.7 myself.

Anyway I just tested again on my iPhone 3GS (my previous test was on an iPad2), and I still have my intanciated movieclip playing once, and being stopped by a stop() instruction in its timeline. So it works...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 06, 2011 Nov 06, 2011

Copy link to clipboard

Copied

I would start to doubt yourself now! Although I can imagine a change where it ignores code, I don't think they retroactively added an interpreter to the old version of AIR.

Is there any chance you're doing interpreter builds by accident?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Nov 06, 2011 Nov 06, 2011

Copy link to clipboard

Copied

Doh, you're right, I was doing interpreter builds, my apologies... I had forgotten that in interpreter mode, AIR doesn't display any warning... Which makes me think that Adobe may put that restriction on all targets by the way. Someone could develop all his game in interpreter mode, just to realize that the normal AS3 instanciation approach doesn't work when switching to final target...

As a side note though: when switching to ipa-app-store target,with AIR 2.7, my game hangs at startup, when loading the external SWF. But with AIR 3, the game seems to load fine but my movieclip is not displayed at all, as if AIR was just discarding silently all unauthorized behaviours... (actually the app behaviour looks erratic, so it must crash silently, trying to continue excecuting code). If it's the case, it might be even more confusing for people who are not aware of this restriction.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 06, 2011 Nov 06, 2011

Copy link to clipboard

Copied

Often, the much poorer performance of interpreter builds is a clue that it's not quite ready to ship!

I don't mind if AIR just ignores code, that would be fine, so long as any timeline animation continued to work. I'm trying to convince Adobe to go along with the recent change in the Apple rules, where you can have interpreted code, so long as it's in the app package and not downloaded. Look at the app "Codify" as a good example of an app loading local code modules.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Nov 07, 2011 Nov 07, 2011

Copy link to clipboard

Copied

LATEST

That would be awesome indeed!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines