Page 1 of 1

creating avatar from scratch in flex

Posted: 06 Apr 2010, 17:13
by pengerknitter
A couple of post in this forum discuss how to create an avatar but they all refer to flash.

I'm using fb3 and I'm unclear on how to change the appearance of an avatar.

The documentation mentions that you need to add AvatarLibrary.swf, but the components panel that is mentioned in the same paragraph seems to refer to flash, not fb3.

If one extends the Avatar class in order to create a custom avatar, where does the actual graphics come from to represent it, i.e. where are the graphics stored/loaded for the crashtest dummy in the default avatar?

Posted: 07 Apr 2010, 18:47
by Bax
In our example, you will find a Flash FLA file containing the DemoAvatar and DemoGhost movieclips, linking the two classes that extend Avatar. The FLA also contains the avatar graphics and it is exported as a SWC file which is added to the Flex build path. In this way you are able to use FLash assets in Flex.

Posted: 07 Apr 2010, 18:55
by pengerknitter
bax wrote:In our example, you will find a Flash FLA file containing the DemoAvatar and DemoGhost movieclips, linking the two classes that extend Avatar. The FLA also contains the avatar graphics and it is exported as a SWC file which is added to the Flex build path. In this way you are able to use FLash assets in Flex.
How do I go about changing the avatar graphics in the swc?

Posted: 07 Apr 2010, 19:13
by Bax
You have to do it in the FLA, and then re-export the SWC.

Posted: 07 Apr 2010, 20:28
by pengerknitter
bax wrote:You have to do it in the FLA, and then re-export the SWC.
I need Flash CS3 for that don't I?

Posted: 09 Apr 2010, 17:41
by pengerknitter
I now understand the workflow - thanks for pointing me in the right direction.

Posted: 12 Apr 2010, 18:09
by pengerknitter
what are the guidelines for creating an avatar, i.e. am I restricted to the dimensions of the existing demo avatar or does the engine automatically scale to the appropriate size once the avatar loads?

Posted: 12 Apr 2010, 22:19
by Bax
OpenSpace simply instantiates your avatar class; no scaling is applied automatically.