Two questions on .createEmptyMovieClip()

Q1) The registration point of a created clip is top left - my question is how can I dynamically change it’s registration point - say to center center?

(I am trying to attach a movie clip to a created clip and I wanted it to be centered inside the container - a related sub-question, how can I find the x-y coordinates of the attached movie clip within the created movie clip?)

Q2)When I tried to create two different movie clips, I found I had to create them at different depths, else the first would load and the second would not. Why would that be so? I’m on MX 2004 Pro.

Thank you all.

soul

When I tried to create two different movie clips, I found I had to create them at different depths, else the first would load and the second would not. Why would that be so? I’m on MX 2004 Pro.

Flash dont like it when there are 2 things at the same depth. He starts killing stuff…

Thanks Nathan. Please humor me, I’ve just started studying up AS, so there is a limit as to how many instances can be created at a particular depth?

Now, how about re-assigning co-ordinates of an instance I place within the created clip through the attach method. I have been able to attach a clip to the created one, but I want it to be aligned in the center. The default registration point for a created clip is top left. Can that be changed through scripting?

Thank you.
s

Yes, the limit is one :slight_smile:

You’ll have to offset the content of the empty movie clip.

OK…you mean, I set the position by something like this -

_root.createdMovieClip.attachedMovieClip._x = someValue for x;
_root.createdMovieClip.attachedMovieClip._y = someValue for y;
?

I’ll try this.

Thank You.
s