@SideFlame If you put the contents of the "loop" function inside a for loop you can make more rain. For example: before the // make a rain drop line you could put:
for (var i=0; i<10; i++) {
and then add an extra } after the d.addEventListener line. That'd make 10 drops per frame - change the 10 for different amounts
@faye921 have you ticked "Export for ActionScript" in the properties of your drop? Is it definitely called drop? The Math line looks fine, make sure it's Math and not math, case sensitive. It'll be blue if it's right!
If you wanted to make a scene with keyframes and other things going on, how would you get the rain to start and stop depending on what part of the scene you were on??
@Tetra84 you add/remove the event listener to start and stop the rain. addEventListener(Event.ENTER_FRAME, loop); to start it or removeEventListener(Event.ENTER_FRAME, loop); to stop it. They can go on any keyframe across the timeline
Thanks!!! keep up the good work! You are geat!
Frankiieboy69 2 months ago
how do i make more rain drop
SideFlame 2 months ago
@SideFlame If you put the contents of the "loop" function inside a for loop you can make more rain. For example: before the // make a rain drop line you could put:
for (var i=0; i<10; i++) {
and then add an extra } after the d.addEventListener line. That'd make 10 drops per frame - change the 10 for different amounts
PointClickWin 2 months ago
Great tutorial, very helpful. You've got yourself another subscriber :)
mbakker2009 4 months ago
@mbakker2009 :)
PointClickWin 4 months ago
good tutorial, thank you!
mikael665 7 months ago
don't really understand code but its not working i keep getting to errors "1180 call to a possibly unidentified method drop" var d = new drop();
1120:acess of unidentifed propety math "d.x=Math.random()*550;
any ideas what im doing wrong?
faye921 8 months ago
@faye921 have you ticked "Export for ActionScript" in the properties of your drop? Is it definitely called drop? The Math line looks fine, make sure it's Math and not math, case sensitive. It'll be blue if it's right!
PointClickWin 8 months ago
If you wanted to make a scene with keyframes and other things going on, how would you get the rain to start and stop depending on what part of the scene you were on??
Tetra84 8 months ago
@Tetra84 you add/remove the event listener to start and stop the rain. addEventListener(Event.ENTER_FRAME, loop); to start it or removeEventListener(Event.ENTER_FRAME, loop); to stop it. They can go on any keyframe across the timeline
PointClickWin 8 months ago
Can you paste the code in like description or something?
ElfyNyu 9 months ago
@ElfyNyu Not without copying it all back out myself :)
I don't keep the code for these voiceless videos, since it's stuff I do all the time. There's not that much to copy ;)
PointClickWin 9 months ago