• New Horizons on Maelstrom
    Maelstrom New Horizons


    Visit our website www.piratehorizons.com to quickly find download links for the newest versions of our New Horizons mods Beyond New Horizons and Maelstrom New Horizons!

Flyers

Petros

Captain of "La Nao"
Storm Modder
After trying many methods of using [GEO] Palka to create flyers of a limited number, and with no success, I finally got to trying the Particles.ini "graphics" approach.

It works! <img src="style_emoticons/<#EMO_DIR#>/william.gif" style="vertical-align:middle" emoid=":will" border="0" alt="william.gif" />

<img src="http://www.pix8.net/pro/pic/7888greeb/1076239.gif" border="0" class="linked-image" />
 
that's pretty cool, but i'still going to put that mod at the maximum setting. <img src="style_emoticons/<#EMO_DIR#>/smile2.gif" style="vertical-align:middle" emoid=":))" border="0" alt="smile2.gif" /> although i have a feeling i might be regretting it. <img src="style_emoticons/<#EMO_DIR#>/rolleyes.gif" style="vertical-align:middle" emoid=":rolleyes:" border="0" alt="rolleyes.gif" />
 
Just tell me the right and working code and i'll include it in my game. <img src="style_emoticons/<#EMO_DIR#>/smile2.gif" style="vertical-align:middle" emoid=":))" border="0" alt="smile2.gif" />
 
I've toned this down so that you get 1 or 2 flyers (sometimes more) with a 13 gun broadside, and some critical hits.
For the hard core who want the effects we saw early on, just follow my directions in Splash, splash, splash topic.

In buildsettings.h
#define SHIPHIT_PARTICLES Zero and 1 won't produce flyers, while value 2 and 3 will.

This picture shows two flyers. Note that extra "palka" are turned off for this. Normally there would be extra splinters and planks and barrels as part of the explosions.
<img src="http://www.pix8.net/pro/pic/7888greeb/1076254.gif" border="0" class="linked-image" />
 
<!--quoteo(post=220460:date=Nov 7 2007, 03:23 PM:name=Cylon13)--><div class='quotetop'>QUOTE(Cylon13 @ Nov 7 2007, 03:23 PM) [snapback]220460[/snapback]</div><div class='quotemain'><!--quotec-->Just tell me the right and working code and i'll include it in my game. <img src="style_emoticons/<#EMO_DIR#>/smile2.gif" style="vertical-align:middle" emoid=":))" border="0" alt="smile2.gif" /><!--QuoteEnd--></div><!--QuoteEEnd-->
Attachment deleated: it and the swimmer stuff are on ftp.
Now for the instructions and code.

1. Add the file "flyer1.tga.tx" to the POTC\Resource\textures directory.

=======================================================================


2. Add the following to particles.ini file

<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->;Petros flying crew addition
[flyers]
technique = particles
randomdirection

texture        = flyer1.tga
particles_num    = 1

emitradius    = 0
emitter_initime    = 0

ddeviation    = 0.1
gravity        = 1.0
lifetime    = 8000
weight        = 0.01
weight_deviation = 0.0005

pscale        = 1.0

spin        = 0.0
spin_deviation    = 0.0025

speed         = 0.06
speed_deviation    = 0.01

key_alpha    = 1,0
key_alpha    = 0,8000

key_psize    = 2.1,0

key_pspeed    = 0.001,0
key_pspeed    = 0.51,150
key_pspeed    = 0.3,500
key_pspeed    = 0.01,1000

key_spin    = 10.5,0
key_spin    = 8.0,2000<!--c2--></div><!--ec2-->


===================================================================
3. To AIShip.c in this section ... <!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->// TIH --> this section adjusted to be a bit more understandable in setting, and reasonable in graphics Nov13'06
// Removal of "CreateBlastM()" function due to that function causing a CTD in battles Nov12'06
    // NK add USE_PARTICLES switch // TIH changed to own switch SHIPHIT_PARTICLES 7-7-06
    // Ball_impact and splinters by MM
    // By MM, Flames and Critical hits only present on bombs now. // changed to add a rare chance (otherwise what's the POINT of the PERKS?)
        case GOOD_BALLS:
            if (ALLOW_CRIT_FROM_BALLS && rand(1)) { bSeriousBoom = false; }// pref toggle and 50% chance a possible critical hit is allowed
            if (ALLOW_FIRE_FROM_BALLS && rand(32) == 1) { bInflame = true; }// pref toggle and 3% chance ship catches on fire from hit
            Play3DSound("ball2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                        CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0); // two small gray puffs
                break;
                case 2:
                        CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0); // two small gray puffs
                        CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0); // six medium splinters
                        CreateParticleSystem("splinters3", x, y, z, 0.0, 0.0, 0.0, 0); // five large splinters
                break;
                case 3:
                        CreateBlast(x,y,z); // excessive plume of planks and barrels, causing big water splashes
                        CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0); // two small gray puffs
                        CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0); // six medium splinters
                        CreateParticleSystem("splinters3", x, y, z, 0.0, 0.0, 0.0, 0); // five large splinters
                break;
            }
        break;
        case GOOD_GRAPES:
            bSeriousBoom = false;
            bInflame = false;
            Play3DSound("grapes2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 2:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 3:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
        case GOOD_KNIPPELS:
            bSeriousBoom = false;
            bInflame = false;
            Play3DSound("knippel2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 2:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 3:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
        case GOOD_BOMBS:
            if (rand(20) == 10) { bSeriousBoom = true; }
            if (rand(2) == 1) { bInflame = true; }
            Play3DSound("bomb2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                    CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 2:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 3:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("blast_inv", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters3", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
// TIH <-- end adjustment<!--c2--></div><!--ec2-->
in several places add ... <!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);    //Petros adds one crew flying overboard<!--c2--></div><!--ec2-->
to get this.<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->// TIH --> this section adjusted to be a bit more understandable in setting, and reasonable in graphics Nov13'06
// Removal of "CreateBlastM()" function due to that function causing a CTD in battles Nov12'06
    // NK add USE_PARTICLES switch // TIH changed to own switch SHIPHIT_PARTICLES 7-7-06
    // Ball_impact and splinters by MM
    // By MM, Flames and Critical hits only present on bombs now. // changed to add a rare chance (otherwise what's the POINT of the PERKS?)
        case GOOD_BALLS:
            if (ALLOW_CRIT_FROM_BALLS && rand(1)) { bSeriousBoom = false; }// pref toggle and 50% chance a possible critical hit is allowed
            if (ALLOW_FIRE_FROM_BALLS && rand(32) == 1) { bInflame = true; }// pref toggle and 3% chance ship catches on fire from hit
            Play3DSound("ball2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                        CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0); // two small gray puffs
                break;
                case 2:
                        CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0); // two small gray puffs
                        CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0); // six medium splinters
                        CreateParticleSystem("splinters3", x, y, z, 0.0, 0.0, 0.0, 0); // five large splinters
                        CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);    // Petros adds one crew flying overboard
                break;
                case 3:
                        CreateBlast(x,y,z); // excessive plume of planks and barrels, causing big water splashes
                        CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0); // two small gray puffs
                        CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0); // six medium splinters
                        CreateParticleSystem("splinters3", x, y, z, 0.0, 0.0, 0.0, 0); // five large splinters
                        CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
        case GOOD_GRAPES:
            bSeriousBoom = false;
            bInflame = false;
            Play3DSound("grapes2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 2:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 3:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
        case GOOD_KNIPPELS:
            bSeriousBoom = false;
            bInflame = false;
            Play3DSound("knippel2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 2:
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 3:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("ball_impact", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
        case GOOD_BOMBS:
            if (rand(20) == 10) { bSeriousBoom = true; }
            if (rand(2) == 1) { bInflame = true; }
            Play3DSound("bomb2bort", x, y, z);
            switch(SHIPHIT_PARTICLES)
            {
                case 0: CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0); break; // one orange puff // stock behavior
                case 1:
                    CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 2:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
                case 3:
                    CreateBlast(x,y,z);
                    CreateParticleSystem("blast", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("blast_inv", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters2", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("splinters3", x, y, z, 0.0, 0.0, 0.0, 0);
                    CreateParticleSystem("flyers", x, y, z, 0.0, 0.0, 0.0, 0);
                break;
            }
        break;
// TIH <-- end adjustment<!--c2--></div><!--ec2-->
 
Good thinking, Petros! So you CAN toggle it when the flyer is a texture rather than a model? Cool. Any chance of those other flyer textures working this way as well?
Judging by your screenshots: Is it just me or do these flyers seem to fly rather low to the waterline instead of flying as high as they did before? I liked them flying high; might there be something we can do about that? <img src="style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":?" border="0" alt="unsure.gif" />
 
<!--quoteo(post=220477:date=Nov 7 2007, 04:56 PM:name=Pieter Boelen)--><div class='quotetop'>QUOTE(Pieter Boelen @ Nov 7 2007, 04:56 PM) [snapback]220477[/snapback]</div><div class='quotemain'><!--quotec-->Good thinking, Petros! So you CAN toggle it when the flyer is a texture rather than a model? Cool. Any chance of those other flyer textures working this way as well?<!--QuoteEnd--></div><!--QuoteEEnd-->
Yes, all I have to do is add another code section like[flyer2] and reference another texture.
However, this would then add more of them and that migh also get out of hand.
<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec-->Judging by your screenshots: Is it just me or do these flyers seem to fly rather low to the waterline instead of flying as high as they did before? I liked them flying high; might there be something we can do about that? <img src="style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":?" border="0" alt="unsure.gif" /><!--QuoteEnd--></div><!--QuoteEEnd-->
Yes, it's more realistic ... flying low and over the edge. They do get higher than what that shot shows, about 3 to 4 times higher than that, I've seen.
There are gravity and weight setting someone can play with to see.

But for the really crazy stuff, one can just put a Lo_man reference in [Geo].
 
Sweet. <img src="style_emoticons/<#EMO_DIR#>/me.gif" style="vertical-align:middle" emoid=":onya" border="0" alt="me.gif" />

I'll mess with adding it tomorrow. <img src="style_emoticons/<#EMO_DIR#>/keith.gif" style="vertical-align:middle" emoid=":keith" border="0" alt="keith.gif" />
 
<!--quoteo(post=220482:date=Nov 7 2007, 11:07 PM:name=Petros)--><div class='quotetop'>QUOTE(Petros @ Nov 7 2007, 11:07 PM) [snapback]220482[/snapback]</div><div class='quotemain'><!--quotec-->However, this would then add more of them and that migh also get out of hand.<!--QuoteEnd--></div><!--QuoteEEnd-->That can be fixed. A rand() selecting a random model, for example. It would add some nice variation. Always the same sailor flying can get boring. Same thing for always the same sailor swimming.
 
<!--quoteo(post=220487:date=Nov 7 2007, 05:47 PM:name=Pieter Boelen)--><div class='quotetop'>QUOTE(Pieter Boelen @ Nov 7 2007, 05:47 PM) [snapback]220487[/snapback]</div><div class='quotemain'><!--quotec-->... It would add some nice variation. Always the same sailor flying can get boring. Same thing for always the same sailor swimming.<!--QuoteEnd--></div><!--QuoteEEnd-->
True, but then we spend much more time "Seeing" the swimmers and up close at that, and very little time "Seeing" the flyers and usually at small scale and from great distances.
 
That is true, of course. If it isn't too much trouble for you, it'd be nice to have, say, three different ones. If it IS too much trouble, just forget about it and we'll keep it as-is.

I was wondering if there should be differences in numbers of flyers depending on the ammunition used. Example: Many flyers on critical hits and when using knippel.
 
<!--quoteo(post=220526:date=Nov 8 2007, 07:06 AM:name=Pieter Boelen)--><div class='quotetop'>QUOTE(Pieter Boelen @ Nov 8 2007, 07:06 AM) [snapback]220526[/snapback]</div><div class='quotemain'><!--quotec-->That is true, of course. If it isn't too much trouble for you, it'd be nice to have, say, three different ones. If it IS too much trouble, just forget about it and we'll keep it as-is.<!--QuoteEnd--></div><!--QuoteEEnd-->

Perhaps this week I'll get to do one more. It will have different clothes and be from a different angle so that should provide sufficient variety.
<!--quoteo--><div class='quotetop'>QUOTE</div><div class='quotemain'><!--quotec-->I was wondering if there should be differences in numbers of flyers depending on the ammunition used. Example: Many flyers on critical hits and when using knippel.<!--QuoteEnd--></div><!--QuoteEEnd-->
Just like planks and splinters, we have them only for ball, chain, and bombs.
 
Hehe..looks like the poor bastards are rocketed out through the gunports <img src="style_emoticons/<#EMO_DIR#>/biggrin.gif" style="vertical-align:middle" emoid=":D" border="0" alt="biggrin.gif" />
 
Petros, I know I was´nt here when you were in the team the first time around, and thats why it may sound a little odd, but.."nice to have you back" <img src="style_emoticons/<#EMO_DIR#>/smile.gif" style="vertical-align:middle" emoid=":)" border="0" alt="smile.gif" />
 
I second that <img src="style_emoticons/<#EMO_DIR#>/par-ty.gif" style="vertical-align:middle" emoid=":cheers" border="0" alt="par-ty.gif" /> Thanks a lot for the Flyer code <img src="style_emoticons/<#EMO_DIR#>/me.gif" style="vertical-align:middle" emoid=":onya" border="0" alt="me.gif" />

So particle effects are basically shortlived moving textures, right? I wonder what else one could do with that.
 
I think that's a pretty accurate description. And we can add particle effects in many places, as evidenced by the smoke, fire, water, etc. found in many locations.
 
<!--quoteo(post=220971:date=Nov 11 2007, 03:29 AM:name=CouchcaptainCharles)--><div class='quotetop'>QUOTE(CouchcaptainCharles @ Nov 11 2007, 03:29 AM) [snapback]220971[/snapback]</div><div class='quotemain'><!--quotec-->I second that <img src="style_emoticons/<#EMO_DIR#>/par-ty.gif" style="vertical-align:middle" emoid=":cheers" border="0" alt="par-ty.gif" /> Thanks a lot for the Flyer code <img src="style_emoticons/<#EMO_DIR#>/me.gif" style="vertical-align:middle" emoid=":onya" border="0" alt="me.gif" />

So particle effects are basically shortlived moving textures, right? I wonder what else one could do with that.<!--QuoteEnd--></div><!--QuoteEEnd-->
CCC, I think you forgot to add this ==> <img src="style_emoticons/<#EMO_DIR#>/dev.gif" style="vertical-align:middle" emoid=":d:" border="0" alt="dev.gif" /> to the end of your statement! <img src="style_emoticons/<#EMO_DIR#>/smile2.gif" style="vertical-align:middle" emoid=":))" border="0" alt="smile2.gif" />
 
hmm.....blood? during swordfights? i've heard a few members in the past wanting that.
 
Just to let you know here, I added a second flyer, and posted the entire flyer and swimmer files to the ftp in the Petros folder.
 
Back
Top