Separating graphical/sound assets and actual logic is a very good practice. It allows to avoid a lot of problems. For some time I’ve been using compiled SWFs with ActionScript skin classes embeding symbols from that SWF using [Embed] meta tag. But recently I came across much better solution using SWC.
So the algorithm is the following:
- Create a new AS project in Flex Builder.
- Create a new FLA at ‘assets/assets.fla’.
- In Publish Settings of that FLA set ‘Export SWC’ checkbox.
- Create and export assets via ‘linkage properties’ as something like ‘assets.MySymbol’.
- Publish SWC.
- In Flex Builder add this SWC at Project -> Properties-> ActionScript Build Path -> Library Path -> Add SWC.
- Now in Flex Builder we can import and use assets.MySymbol and IDE knows about it and its type.













Recent Comments