Jump to content

Photo

Random Falling Snow


  • Please log in to reply
11 replies to this topic

#1 Linkus

Linkus

    .

  • Members
  • Real Name:Adam

Posted 09 September 2007 - 02:04 PM

Simple, really: All I want is falling snow, but not in animated tile form and with random paths. Also, make sure speed and the number of flakes can be edited!

#2 Professor Bedwetter

Professor Bedwetter

    Strangers when we meet

  • Members
  • Real Name:Zack Zack Zack Zack Zack Zack Zack Zack Zack Zack

Posted 10 September 2007 - 07:53 PM

Do you really need a script?

#3 Plissken

Plissken

    What's with these homies dissing our girls?

  • Members

Posted 10 September 2007 - 07:59 PM

Yes he does because no matter how many different animated tiles there are on a screen it will eventually be a pattern unto itself.

#4 Professor Bedwetter

Professor Bedwetter

    Strangers when we meet

  • Members
  • Real Name:Zack Zack Zack Zack Zack Zack Zack Zack Zack Zack

Posted 10 September 2007 - 08:02 PM

Well you could make it go for hours it would be easier

#5 Plissken

Plissken

    What's with these homies dissing our girls?

  • Members

Posted 10 September 2007 - 08:09 PM

I highly doubt that...making all of those tiles that last for maybe over a second tops (with the way I think he's describing it) would take a lot longer than someone who knows what they are doing to script something up.

#6 ShadowTiger

ShadowTiger

    The Doctor Is In

  • Members

Posted 10 September 2007 - 08:20 PM

I think that all you need is to set up a series of FFC's which look like snow and all have screen wrap on. Put them at the angle you'd like, and maybe even animate them so that they fade in and out so it looks like they actually are random instead of just the same ones wrapping around and around the screen all the time.

Then, you can copy and paste the FFC's from that screen to all the other ones that you'd like. So the function of the script, based on your description, wouldn't really be necessary. Just set it up once, and copy it to all the rest of the screens.

#7 Gleeok

Gleeok

    It's dangerous to dough alone, bake this.

  • Members
  • Real Name:Pillsbury
  • Location:Magical Land of Dough

Posted 11 September 2007 - 03:21 AM

Unfortunately this would require a bit of work for something that would be much easier using animation. About 20 pages of tiles would do the trick, with around 22 combo's or so. I would recommend doing that.

Well here's why it would suck;

CODE

ffc script snow{

        void run(int speed, int bounce, int x_accell, int y_accel, int rnd){

                    int snows = 0;
                    flake = Screen->LoadFFC(32);
                    flake2 = Screen->LoadFFC(31);
                    flake3 = Screen->LoadFFC(30);
                    flake4 = Screen->LoadFFC(29);
                    while(true){
                                if (snows == 0){
                                             flake->Vy = -1
                                             flake->Vx = 0
                                              //Aarg! etc etc....just for snow....
                                             snows ++; // or  snows = snows + Rand(rnd);
                             } if (snows == 1){
                                             flake->Vy = flake->Vy + (bounce);
                                             flake->Vx = flake->Vx - (bounce);
                                             flake->Vy = +1;
                                     //etc
                            }
                //mess with accell or speed
        if (flake->Vx < - speed) { flake->Vx = - speed; }
        if (flake->Vy > speed) { flake->Vy =  speed; }
                           flake->Y + y_accell;
                           flake->X = flake->X + Rand(rnd);
                          }
             }
             if (flake->X > 260) { flake->X = this_ffc->X }
             if (flake->Y > 180) { flake->Y = this_ffc->Y }     //return to top;
//and on....
                          


Well there's some idea's for you.

Have fun! icon_lol.gif

Edited by Gleeok, 11 September 2007 - 03:23 AM.


#8 Radien

Radien

    Courage

  • Members
  • Real Name:Steve
  • Location:Oregon

Posted 11 September 2007 - 08:09 AM

Sigh. Scripting looks like such a pain in the arse. And this is coming from someone who is moderately accomplished in IRCscript, which is basically a simpler version of Javascript.

Gleeok, are you posting that to make a point? Because I don't know Zscript well enough to know what you're getting at. I'm guessing that that script is just the beginning of a large, complex script that would be necessary to handle this task. Am I on the mark?

#9 NoeL

NoeL

    Legend

  • Members
  • Real Name:Jerram

Posted 11 September 2007 - 09:37 AM

Actually, it would be relatively simple to script icon_shrug.gif

I'd suggest coding the screen to draw dots rather than using FFC's for the flake, because you can only have a handfull of FFC's on each screen, and you don't want to have to set each snowflake up individually icon_confused.gif

#10 Gleeok

Gleeok

    It's dangerous to dough alone, bake this.

  • Members
  • Real Name:Pillsbury
  • Location:Magical Land of Dough

Posted 11 September 2007 - 09:51 AM

QUOTE(Radien @ Sep 11 2007, 07:09 AM) View Post

Gleeok, are you posting that to make a point? Because I don't know Zscript well enough to know what you're getting at. I'm guessing that that script is just the beginning of a large, complex script that would be necessary to handle this task. Am I on the mark?


Well basically I put all the idea's out there; speed,accell,bounce(dancing snowflakes),randomness. I left out the waitframes though, you might want those...But yes. Something like that would be ridiculous (for me anyway) just for .........snow. *shoots milk out nose* It would contain lots of little and random increments here and there. You could spend that much effort scripting up an awesome custom boss. But as is, it's about 1/4 done.

Linkus, the easiest way would be to make tile animations about 400 to 600 tiles long. Don't worry, there'd be alot of "blank" tiles. mostly blank actually. Each combo would start at a different spot, ..say 20-60 tiles apart, and depending on where you place them on the screen, it's different every time. Random!..almost. It's not that hard, there's alot of copy/paste involved. That's how I do Custom Boss animation for special attacks and such. Give it a shot.

Oh and for future reference; If the post read "Super devestating Boss that shoot's lasers and summons enemies!!!.....and bakes cakes!" Then there might be a greater chance of a completed script. Not that your idea is not good, just that it's kinda hard to script. icon_wink.gif

-Actually, this might be reletively simple with ZASM. I no nothing about that though....




QUOTE
I'd suggest coding the screen to draw dots rather than using FFC's for the flake, because you can only have a handfull of FFC's on each screen, and you don't want to have to set each snowflake up individually


Explain please. Could you post a small mockup script perchance?

Edited by Gleeok, 11 September 2007 - 09:57 AM.


#11 Beefster

Beefster

    Human Being

  • Members
  • Real Name:Justin
  • Location:Colorado

Posted 21 September 2007 - 03:45 PM

I think the snow should use the pixel command and just keep track of the coords of each.

#12 Gleeok

Gleeok

    It's dangerous to dough alone, bake this.

  • Members
  • Real Name:Pillsbury
  • Location:Magical Land of Dough

Posted 22 September 2007 - 12:09 AM

QUOTE(Beefster @ Sep 21 2007, 02:45 PM) View Post

I think the snow should use the pixel command and just keep track of the coords of each.

There's probably a bunch of ways to make this easy to script. Problem is no one wants to explain stuff like draw and pixel or whatever, so not many people know how it works.


1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users