Snake's Tutorial on adding snow

Started by Snake, April 26, 2011, 01:18:42 PM

Previous topic - Next topic
Well adding snow is similar to adding rain, however there are a few differences so you can't just put snow as the texture.
I attached an .fx file with working snow for download, just change the name to your modid and put it in your World file.

-NOTE- Take off the -- in your world .req file!!

    REQN
    {
        "envfx"
   --    "modid"
    }

to:

    REQN
    {
        "envfx"
       "modid"
    }

Here is a working .fx file that makes snow:


Effect("Wind")
{
   Enable(1);
   Velocity(4.0, 0.3);
   VelocityRange(1.0);
   VelocityChangeRate(0.2);
   //Effect("rainsplash");
   //GroundEffectsPerSec(20);
   //GroundEffectSpread(10);
}

Effect("Precipitation")
{
   Enable(1);
   Type("Quads"); - I don't know what quads are but in the rain .fx file it says Streaks
   Texture("fx_snow");
   ParticleSize(0.015); - You can play around with this to change how big the snowflakes are
   Color(255, 255, 255); - This is the color of the snow, you can change this for it to look like Felucia or something.
   Range(15.0); - I think this is how far around the player can you see snow
   Velocity(2.0); - This is the speed of the snow
   VelocityRange(0.8); - This has something to do with how close it can get..not sure
   PS2()
   {
      ParticleDensity(80.0);
   }
   XBOX()
   {
      ParticleDensity(100.0);
   }
   PC()
   {
      ParticleDensity(100.0); - This is how many snowflakes are around the player at once.
   }
   ParticleDensityRange(0.0);
   CameraCrossVelocityScale(1.0);
   CameraAxialVelocityScale(1.0);
   AlphaMinMax(0.3, 0.45);
   RotationRange(2.0);
}
=AaTc= Forever

SALLY....

-Retired Modder

thank you so much for this knowledge. i will be adding this to my future release of modding encyclopedia v5.

do you know about the particle limit in bf1?

I do not know but I'm sure the higher you get the laggier it will be and eventually a crash.
=AaTc= Forever

SALLY....

-Retired Modder

Quote from: SnΛke on April 27, 2011, 05:49:07 PM
I do not know but I'm sure the higher you get the laggier it will be and eventually a crash.
Just wondering because the current betas of my larger side projects (phobos and rancorland) seem to be crashing and missing tons of particles that normally would be there such as flames, lasers, and basic elements. I wonder if native bf1 lua coding allows you to increase these limits, or maybe some trick with cheat engine.

I do know that when I made a sniperrifle that didnt fade out it only let me shoot like 30 shots. (Thats just a guess)
=AaTc= Forever

SALLY....

-Retired Modder