Thanks for the help in advance…
I am new to actionscript and am trying to figure out how to do two things.
- attachMovie when the level.text is at 2.
- give that attached movie properties (movement)
this is my code. you can see what i am trying to do but it is not working. this code is on the first frame of my timeline.
thanks again.
level.text = 1;
var flake:MovieClip;
function fallAndDelete() {
this._y += 2;
if (this._y>300) {
this.removeMovieClip();
}
}
if (level.text == 2) {
flake = this.attachMovie("flake", "f", 0, {_x:100, _y:100});
}
flake.onEnterFrame = fallAndDelete;
tm = 20;
displayTime.text = tm;
function countDown() {
tm--;
displayTime.text = tm;
if (tm == 0) {
tm = 21;
level.text++;
}
}
timer = setInterval(countDown, 1000);