Hi,

I'm creating an assets SWC in Flash (CS5.5) which I intend to use in a pure AS3 mobile application created in Flash Builder (4.5).

I've been using "Sprite" or "MovieClip" as parent classes for my assets so far (depending on timeline needed or not), but I read somewhere that if you have the option to use Shape you should do so (performance reasons etc). This uses less memory (up to 2.3x less memory on mac) and is faster in construction time.

Is there a possibility to extend have an asset in the library extend from Shape?

I tried it, but got following error:

The class 'flash.display.Shape' must subclass 'flash.display.MovieClip' since it is linked to a library symbol of that type.

Sprite doesn't subclass MovieClip either, but that works without problems. Looking at the class hiërarchy I assume that is because it's not an InteractiveObject. But is there a way around this?



Oh yeah, drawing the shape by code is not really an option (which you could do for simple shapes). Unless there is a way to generate the code for a complex shape (flattened EPS), it's not feasible.

Thanks for the advice,

With kind regards,
Jeroen