Jump to content
Search Community

Knowing if loaded swf is Timeline swf or library exported MovieClip

mrpinc test
Moderator Tag

Recommended Posts

This is not so specific to loader max but just wanted to see if anyone had any ideas about this.

 

If you create a FLA and put some content on the timeline and publish it.  When you load it in loadermax to get that MovieClip you just need to call LoaderMax.getContent("mySWF").rawContent;

 

However if you have a movieclip in your library in Flash and you right click and choose 'Export SWF..." then load that swf - in order to get the actual movieclip you are exporting you need to call

LoaderMax.getContent("myLibrarySwf").rawContent.getChildAt(0).

 

Does anyone know of any way to determine if a Loaded SWF is either a main timeline or expoted using the right-click method i described?

 

You could do a check to see if getChildAt(0) is MovieClip on the rawContent but the problem with this is that if your timeline SWF had a MovieClip as a the background it would not be accurate. 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...