Page 1 of 1

please help

Posted: Tue May 04, 2004 7:26 am
by Guest
hi there .. iv used an action script , which is just rain falling, but i need it to stop half way through my flash story. so on the frame i where i want it to stop, i deleted the action, but the rain still keeps goin. does anyone know how i can stop it?? :? please help

Posted: Tue May 04, 2004 12:54 pm
by Spaced Ape
have you tried a human sacrifice?

Posted: Tue May 04, 2004 1:49 pm
by bartard
what was your script?

Posted: Tue May 04, 2004 2:43 pm
by HeRetiK
show us the script, without it it's a little hard to tell :?

Posted: Wed May 05, 2004 12:40 pm
by Guest
heres the script :

while (i<40) {
duplicateMovieClip("rain", i, i);
setProperty(i, _x, random(1000)-100);
setProperty(i, _y, 0);
setProperty(i, _alpha, 500-random(50));
scale = random(100);
setProperty(i, _xscale, scale);
setProperty(i, _yscale, scale);
i = i+1;
}

Posted: Thu May 06, 2004 4:50 am
by HeRetiK
Anonymous wrote:heres the script :

while (i<40) {
duplicateMovieClip("rain", i, i);
setProperty(i, _x, random(1000)-100);
setProperty(i, _y, 0);
setProperty(i, _alpha, 500-random(50));
scale = random(100);
setProperty(i, _xscale, scale);
setProperty(i, _yscale, scale);
i = i+1;
}


hmmm... you could enter an if loop.


if (raining) {
while (i<40) {
duplicateMovieClip("rain", i, i);
setProperty(i, _x, random(1000)-100);
setProperty(i, _y, 0);
setProperty(i, _alpha, 500-random(50));
scale = random(100);
setProperty(i, _xscale, scale);
setProperty(i, _yscale, scale);
i = i+1;
}
}

in the first frame where the rain starts you have to set raining to true:

raining = true;

at the frame where you want it to stop you set it to false and the script stops generating rain:

raining = false;

got any other scripts in your rain movieclips?

Posted: Thu May 06, 2004 12:57 pm
by Guest
nah thats the only script i used. thanx heaps for all ur help :)

Posted: Thu May 06, 2004 4:21 pm
by HeRetiK
no problem, I hope it works. :wink: