I’m trying to put some objects onto screen and have them fall.
To do this I created a ball and converted it to a symbol “ball”, I have an instantiation of it in my project called “my_ball” so that I can duplicatemovieclip it.
question 1: Is there a way to duplicate movie clips straight from the library. I find myself forced to have a starting one on the screen
//alternative to this?
my_ball.duplicateMovieClip("my_ball_"+total_balls,_root.getNextHighestDepth());
Question 2:
how do I now get my duplicated objects to “take on their own course of action” and change their positions independantly ( a bonus if someone helps me understand how an initilization var like descent speed / descent interval could be passed in)?
My current method I am duplicating the numbered objects on an interval. I have added actionscript to the first frame of the “ball” symbol:
trace("..");
//move the ball down
function MoveMe(){
trace("MOVING" + _parent._x + " AND Y : " + this._y);
}
ID = setInterval(MoveMe, 10);
When I run my project I am able to see the different balls initialize and say they are moving. But i’m not sure how I get at their coordinates. I have tried the _this and _parent.