Jump to content

Photo

ffc Explosion


  • Please log in to reply
12 replies to this topic

#1 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 05 December 2017 - 08:19 PM

Hiya i do like to ask request.

 

I do want a ffc script that it create explosions depended of times before it explose likes.

 

D0 (is the time before explosion starts.)

 

D1 (is the time before the explosion restart)

 

D2 (ìs the sprite of Eweapons)

 

It could be very usefull for escaping events just after defeat the final boss.


Edited by Sans, 05 December 2017 - 08:20 PM.


#2 Orithan

Orithan

    Studying Scientist - Commission from Silvixen

  • Members
  • Location:Australia

Posted 06 December 2017 - 06:47 PM

Where do you want the explosions to occur?
Do you want them to damage? If so, how much?

How many times do you want it to happen? Do you want them to happen indefinitely?
etc

 

Before people will take on your request, you should tell them exactly what you want; giving out all the critical details.
 



#3 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 06 December 2017 - 07:11 PM

well i do want to put the explosion everywhere i do put the ffc scripts. The explosion will not take damages to Link (that would be unfair if it take damages to Link on escape moments.



#4 Timelord

Timelord

    The Timelord

  • Banned
  • Location:Prydon Academy

Posted 06 December 2017 - 08:58 PM

ffc script CreateRandomSprites
{
    void run( int start_timer, int restart_timer, int wsprite, int max_poofs, int poof_sound)
    {
        if ( max_poofs < 1 ) max_poofs = 1;
        int numpoofs;
        while(1)
        {
            while( start_timer-- > 0 ) { Waitframe(); }
            do
            {
                numpoofs = Rand(0,max_poofs);
                while(numpoofs > 0)
                {
                    lweapon boom = Screen->CreateLWeapon(LW_SPARKLE);
                    boom->X = 1;
                    boom->Y = 1;
                    boom->HitXOffset = -32768;
                    boom->DrawXOffset = Rand(-8, 264);
                    boom->DrawYOffset = Rand(-8,184);
                    boom->UseSprite(wsprite);
                    --numpoofs; continue;
                }
                Game->PlaySound(poof_sound);
                Waitframe();
            } while( restart_timer-- > 0 );    
            start_timer = this->InitD[0];
            restart_timer = this->InitD[1];
            Waitframe();
        }
    }
}
      

That might be what you want Sans.


  • judasrising likes this

#5 judasrising

judasrising

    I play guitar

  • Members
  • Location:Sweden but born in Finland

Posted 07 December 2017 - 03:54 AM

ffc script CreateRandomSprites
{
    void run( int start_timer, int restart_timer, int wsprite, int max_poofs, int poof_sound)
    {
        if ( max_poofs < 1 ) max_poofs = 1;
        int numpoofs;
        while(1)
        {
            while( start_timer-- > 0 ) { Waitframe(); }
            do
            {
                numpoofs = Rand(0,max_poofs);
                while(numpoofs > 0)
                {
                    lweapon boom = Screen->CreateLWeapon(LW_SPARKLE);
                    boom->X = 1;
                    boom->Y = 1;
                    boom->HitXOffset = -32768;
                    boom->DrawXOffset = Rand(-8, 264);
                    boom->DrawYOffset = Rand(-8,184);
                    boom->UseSprite(wsprite);
                    --numpoofs; continue;
                }
                Game->PlaySound(poof_sound);
                Waitframe();
            } while( restart_timer-- > 0 );    
            start_timer = this->InitD[0];
            restart_timer = this->InitD[1];
            Waitframe();
        }
    }
}
      

That might be what you want Sans.

 

Rfire.png

And it works good i just tested it with whatever weapon sprite i had in mind....



#6 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 07 December 2017 - 04:49 PM

I have to put it on Run Script at screen int and i have to use arguments or it's automatic ? 



#7 Timelord

Timelord

    The Timelord

  • Banned
  • Location:Prydon Academy

Posted 08 December 2017 - 03:51 AM

I have to put it on Run Script at screen int and i have to use arguments or it's automatic ? 

 

You want it to run on scren init. You will need to set the script args by hand.

 

You can copy-paste the ffc after you set it up, to other screens.



#8 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 08 December 2017 - 07:52 AM

well i did setup the arguments likes:

 

D0: 1

D1: 1

D2: 9

but somehow i don't see something happens ^^'

and i did actived the run on scren init.


Edited by Sans, 08 December 2017 - 07:53 AM.


#9 judasrising

judasrising

    I play guitar

  • Members
  • Location:Sweden but born in Finland

Posted 08 December 2017 - 09:11 AM

well i did setup the arguments likes:

 

D0: 1

D1: 1

D2: 9

but somehow i don't see something happens ^^'

and i did actived the run on scren init.

Then something is very wrong

 

Edit 1`: it seems to me that now it is time to track these things down since that script should work ..

Edit 2 : what is your weapon sprite no 9?

and you have to have an value in D3 also D1 and D2 seems to me an break try not the same value


Edited by judasrising, 08 December 2017 - 09:27 AM.


#10 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 08 December 2017 - 08:46 PM

Ok so i did likes you instructed but however the explosion sprite is ben here but when i enter inside the room the explosions disappears soundly and even if i put values.D1 for the What value you do recommend me for it works ? (except the D2 i do used for the sprite no 9. )



#11 Timelord

Timelord

    The Timelord

  • Banned
  • Location:Prydon Academy

Posted 09 December 2017 - 08:01 AM

well i did setup the arguments likes:

 

D0: 1

D1: 1

D2: 9

but somehow i don't see something happens ^^'

and i did actived the run on scren init.

 

The arguments are:

 

D0: Delay before initial explosions.

D1: Time during which explosions run, before the cycle restarts.

D2: Sprite to use from Quest->Sprites->Weapons

D3: The maximum number of sprites to create per frame. I would suggest a value of 1 or 2.

D4: The sound to play for the explosion.

 

I would also suggest using this revision, as it eliminates a potential bug:

ffc script CreateRandomSprites
{
    void run( int start_timer, int restart_timer, int wsprite, int max_poofs, int poof_sound)
    {
        if ( max_poofs < 1 ) max_poofs = 1;
        int numpoofs;
        while(1)
        {
            while( start_timer-- > 0 ) { Waitframe(); }
            do
            {
                numpoofs = Rand(0,max_poofs);
                while(numpoofs > 0)
                {
                    if ( Screen->NumLWeapons() > 200 ) { continue; }
                    lweapon boom = Screen->CreateLWeapon(LW_SPARKLE);
                    boom->X = 1;
                    boom->Y = 1;
                    boom->HitXOffset = -32768;
                    boom->DrawXOffset = Rand(-8, 264);
                    boom->DrawYOffset = Rand(-8,184);
                    boom->UseSprite(wsprite);
                    --numpoofs;
                }
                Game->PlaySound(poof_sound);
                Waitframe();
            } while( restart_timer-- > 0 );    
            start_timer = this->InitD[0];
            restart_timer = this->InitD[1];
            Waitframe();
        }
    }
}
  

FWIW, I also turned this effect into an item, for the amusement-factor:      item script StupidlyOverPoweredExplosion

 

Spoiler

 

I doubt that anyone would ever use that, as it is an infinite bombos-style effect.

 

Sans, what is your native language? I wonder if it might be easier for some of us to figure out what you want, if you post both in English, and your native language (in spoiler tags).



#12 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 09 December 2017 - 10:23 AM

well... my native language is especially the French



#13 Sans

Sans

    Hey kid wanna buy hot dogs ?

  • Members
  • Location:Judgement Hall

Posted 11 December 2017 - 02:55 PM

I wonder if we can actually add a timer functions that if the time runs out everything explode and Link die even if he have alot lifes. that could be like Metroid self-destruct sequences




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users