Computer Science Canada Help with "Christmas Animations" |
Author: | nipressure [ Tue Dec 04, 2007 11:10 am ] |
Post subject: | Help with "Christmas Animations" |
I have to make lots of animations for my school (its like a project). and the program has to relate to holidays and include a lot of animations. I chose christmas, and I've already done some animations, but I'm having difficulty making snowflakes. For example, process snowflake loop for decreasing Y:400..152 drawfilloval (225,Y-1,2,2,0) delay (3) drawfilloval (225,Y,2,3,blue) end for end loop end snowflake fork snowflake this thing only makes one snowflake, and its just one snowflake keep coming back down. I'm sure there are many other ways to do it, and make it go side ways and stuff, but it's my first year doing turing and I'm not really good at it. I need help! P.S. my snowflake keeps going through my snowman, house...etc(it erases the thing that it passes) is there a way to stop it? |
Author: | HeavenAgain [ Tue Dec 04, 2007 12:05 pm ] | ||
Post subject: | RE:Help with "Christmas Animations" | ||
LOL, i have no idea how the heck this suppose to look like, but the idea is, dont use process, because it can get really screwed up, and what you should do is use a random x and y cord. and call to it many times, and you'll get your snow flakes at random place falling down as for your snow flake earsing stuff, draw and update screen in order; draw snow flake first -->> draw snowman -->> clearn screen -->> draw snow flake (but y cord minus) -->> draw snowman (again) -->> clearn screen .... and so on |
Author: | r.m_spy [ Tue Dec 04, 2007 1:45 pm ] |
Post subject: | Re: Help with "Christmas Animations" |
nipressure @ Tue Dec 04, 2007 11:10 am wrote: I have to make lots of animations for my school (its like a project).
nice idea procedure snowflake loop for decreasing Y:400..152 drawfilloval (225,Y-1,2,2,0) delay (3) drawfilloval (225,Y,2,3,blue) end for end loop end snowflake fork snowflake this thing only makes one snowflake, and its just one snowflake keep coming back down. I'm sure there are many other ways to do it, and make it go side ways and stuff, but it's my first year doing turing and I'm not really good at it. I need help! P.S. my snowflake keeps going through my snowman, house...etc(it erases the thing that it passes) is there a way to stop it? |
Author: | Nick [ Tue Dec 04, 2007 3:14 pm ] | ||
Post subject: | RE:Help with "Christmas Animations" | ||
uhhh y did u quote that? and by the way heaven again states is the best so say u want 4 snowflakes
|
Author: | belarussian [ Wed Nov 18, 2009 6:13 pm ] |
Post subject: | Re: Help with "Christmas Animations" |
HERE IS THE REAL CODE THOSE NOOBS KNOW NOTHING THEIR SNOW SUCKS View.Set ("offscreenonly") %set up the snow const NoOfFlakes := 400 var flakeX : array 1 .. NoOfFlakes of int var flakeY : array 1 .. NoOfFlakes of int for flake : 1 .. NoOfFlakes flakeX (flake) := Rand.Int (0, maxx) flakeY (flake) := Rand.Int (0, maxy) end for loop for flake : 1 .. NoOfFlakes %Drop The Flake flakeY (flake) -= Rand.Int (1, 5) %flakeX (flake) += Rand.Int (-1, 1) if flakeY (flake) < 0 then flakeY (flake) := maxy flakeX (flake) := Rand.Int (0, maxx) end if Draw.FillOval (flakeX (flake), flakeY (flake), 1, 1, white) end for %Update the screen (because of offscreen only) View.Update delay (25) end loop |
Author: | B-Man 31 [ Wed Nov 25, 2009 9:34 pm ] |
Post subject: | Re: Help with "Christmas Animations" |
belarussian @ Wed Nov 18, 2009 6:13 pm wrote: HERE IS THE REAL CODE THOSE NOOBS KNOW NOTHING THEIR SNOW SUCKS
Have you even tried to run your code!? You might want to add a background colour! white snow on a white background doesn't show up. also, maybe next time you want to clear the snowflakes before drawing them. so before you go around calling them noobs, make sure your not one either. |