Search found 54 matches

by gl0om
29 May 2010, 09:15
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

Now I have such error:
ReferenceError: Error #1065: Variable panama is not defined

But, panama movieclip exists in DemoAvatarContainer.fla and it exported as panama. Is there any other place where I should define panama?
by gl0om
27 May 2010, 21:55
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

oops :oops:
Indeed it was string in _skin.hat
I forgot that addChild requires DisplayObject and passed it's name... Sorry :roll:
by gl0om
27 May 2010, 17:16
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

Code: Select all

      override public function set skin(data:Object):void
      {
         trace("DemoAvatar: skin set to", data)
         _skin = data;
         
         if (_skin != null)
         {
            avatarGraphics.addChild(_skin.hat);
         }
      }
by gl0om
26 May 2010, 11:50
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

What about checking the avatar example we provide? (ok, it is part of the OpenSpace Flex example, but the inner behavior of the avatar class -DemoAvatar.as- is always the same) Actually I work with your DemoAvatar.as from Flex example... Maybe I use old version of it, but there's no a single line a...
by gl0om
26 May 2010, 11:29
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

I'm trying to addChild from library in set skin function. Object which I'm trying to add has MovieClip class and this class isn't changable. On adding attempt I receive message that object myst be of DisplayObject class. Why? Avatar class is child of MovieClip... I can't understand how to work with ...
by gl0om
20 May 2010, 12:09
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

Another solution is that you declare myAvatarSymbol , avatarGraphics and what else in the DemoAvatar class, then open the actionscript properties panel of the DemoAvatarContainer.fla file and uncheck the Automatically declare stage instances flag. In this way you should be able to compile the DemoA...
by gl0om
14 May 2010, 08:29
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

You don't have to include DemoAvatar.as in your main project. It is used when you compile your avatar library swf file, so it takes those myAvatarSymbol and avatarGraphics definitions from there. And what if I use DemoVatar class in my project? Compilator will stuck on line where the reference on D...
by gl0om
12 May 2010, 14:06
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

Not sure? Did you read my earlier post in which I describe the two approaches? Anyway, as you are loading an external SWF file, you are using an external library. DemoAvatar.as doesn't contain a definition of myAvatarSymbol and avatarGraphics because those are movieclips inside the DemoAvatar movie...
by gl0om
11 May 2010, 22:33
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

There was no definision for myAvatarSymbol and avatarGraphics in DemoAvatar.as from flex.zip.

So I added these 2 lines

public var myAvatarSymbol:*;
public var avatarGraphics:*;

Now everything seems to be fine
by gl0om
11 May 2010, 13:22
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

Are you following the "external library" approach correctly, creating the application domain in which you load the swf correctly? I'm not sure. Here's my code private function init(e:Event = null):void { removeEventListener(Event.ADDED_TO_STAGE, init); swfLibrariesApp...
by gl0om
11 May 2010, 09:43
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

bax wrote:gl0om,
Are you able to compile that fla to a swf file, without errors?

Yes
by gl0om
11 May 2010, 08:14
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

In this case you probably have an issue with the application domain in which you load the avatars swf file. As the IOpenSpace.avatarAppDomain property description says in the client API reference, that application domain must have the main application domain as its parent. I made some changes and n...
by gl0om
10 May 2010, 22:39
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

I get warning when using createMyAvatar [WARNING] An error occurred while creating avatar '0': Invalid main avatar class definition for 'demo' avatar type: class must extend Avatar "demo's" mainClass is "DemoAvatar" And Yes, DemoAvatar extends Avatar class package { import c...
by gl0om
07 May 2010, 12:22
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

gl0om I don't understand. You compile the avatars container. Then you should load the swf at runtime in your application. Why should the project compilation include the avatars?? If you open main.as from Open Space Example, you should find lines: var tmp1:GhostAvatar; var tmp2:DemoAvatar; As I used...
by gl0om
07 May 2010, 10:43
Forum: OpenSpace v2 discussions and help
Topic: Avatar Creation in Flash
Replies: 43
Views: 20722

bax wrote:Do you get these errors when compiling the DemoAvatarContainer.fla file?


Nope, I get them when compiling my project. DemoAvatarContainer.fla is compiling without errors.

Go to advanced search