I’m using this falling snoweffect but I exhanged the snow with a coin so what I wanna do is have money falling but when they reach bottom I want them to stop. Instead they are looping and I dont know where to change it in the code.
Can anyone help me with this.
init = function () {
width = 200;
// pixels
height = 400;
// pixels
max_snowsize = 10;
// pixels
snowflakes = 5;
// quantity
for (i=0; i<snowflakes; i++) {
t = attachMovie(“snow”, “snow”+i, i);
t._x = -(width/2)+Math.random()(1.5width);
t._y = -(height/2)+Math.random()(1.5height);
t.k = 1+Math.random()4;
t.wind = -1.5+Math.random()(1.4*3);
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();