[SIZE=3]I am working on a flash project for school with a skiing scene in it. I used the snow 3.o tutorial to make a wonderful snow scene. I am using multiple scenes and not all of them need the snow. My problem is I can’t get all of the snow to disappear when I leave the snow scene. I used the following commands. I admit to not knowing but a few commands, so I probably just don’t know the one to get rid of the snow.[/SIZE]
init = function () {
width = 550;
// pixels
height = 400;
// pixels
max_snowsize = 10;
// pixels
snowflakes = 70;
// quantity
for (i=0; i<snowflakes; i++) {
t = attachMovie(“snow”, “snow”+i, i);
t._alpha = 20+Math.random()60;
t._x = -(width/2)+Math.random()(1.5width);
t._y = -(height/2)+Math.random()(1.5height);
t._xscale = t._yscale=50+Math.random()(max_snowsize10);
t.k = 1+Math.random()2;
t.wind = -1.5+Math.random()(1.43);
t.onEnterFrame = mover;
}
};
mover = function() {
this._y += this.k;
this._x += this.wind;
if (this._y>height+10) {
this._y = -20;
}
if (this._x>width+20) {
this._x = -(width/2)+Math.random()(1.5width);
this._y = -20;
} else if (this._x<-20) {
this._x = -(width/2)+Math.random()(1.5width);
this._y = -20;
}
}
init();
[SIZE=3]I used that to make the snow and it works fine. Then I used,[/SIZE]
for (k=70; k>0; k–) {
removeMovieClip(“snow”);
removeMovieClip(“snow”+k);
removeMovieClip(k);
}
[SIZE=3]to remove the snow. It works, but it leaves one tiny snowflake behind. I’ve put variations of the top script to make it so that the single snowflake only shows up sometimes in the top corner, but I want it gone![/SIZE]