Page 1 of 1

Snow, how?

Posted: December 18th, 2006, 3:16 am
by Pedsdude
How? :)

I've tried a few scripts from MODSonline but have been unsuccessful thus far. Please show me the light!

Posted: December 18th, 2006, 3:27 am
by Drofder2004
Check out the stock maps and looki inside the _fx gsc's.
Remember, snow only works in Dx9.

Posted: December 18th, 2006, 4:04 am
by Pedsdude
Had a look at mp_downtown gscs, and I came up with this code:

Code: Select all

main()
{
maps\mp\_load::main();
thread precacheFX();
thread ambientFX();
}

precacheFX()
{
level._effect["snow_light"] = loadfx ("fx/misc/snow_light_mp_downtown.efx");	
level._effect["cold_breath"] = loadfx ("fx/misc/cold_breath.efx");
}


ambientFX()
{
	//Snow
	maps\mp\_fx::loopfx("snow_light", (0,0,0), 0.6, (0,0,0));
}
The map loads fine, but no snow appears. I'm not sure what values the co-ords should be:

Code: Select all

	maps\mp\_fx::loopfx("snow_light", (0,0,0), 0.6, (0,0,0));
So I just put them all as zero :?

In the mp_downtown gsc it has the following:

Code: Select all

	maps\mp\_fx::loopfx("snow_light", (1635,-1393,375), 0.8, (1635,-1393,475));

Posted: December 18th, 2006, 4:07 am
by Nightmare
are you running on DX 9?

Posted: December 18th, 2006, 4:13 am
by Pedsdude
Nightmare wrote:are you running on DX 9?
Thank you for that useful response. Yes I am...

Posted: December 18th, 2006, 4:20 am
by Pedsdude
OK, I used the ones for mp_downtown and it worked! It was everywhere! :)

Code: Select all

	maps\mp\_fx::loopfx("snow_light", (465, 2, 144), 0.6, (-11246,-7164,530));
	maps\mp\_fx::loopfx("snow_light", (468, 3, 261), 0.6, (-7352,-7369,530));
Do I need both lines? Can I change the co-ords and if so what would they need to be changed to (if they need to be changed at all?) What do they represent? Is it an area in which the snow appears or something else?

So many questions, so little time! :P

Posted: December 18th, 2006, 9:41 pm
by Drofder2004
All zeros wouldn't work. the coordinates are used to work out direction, if a - b = 0 then a direction of zero is applied to the FX (i.e No direction, meaning no FX)... following?

Anyway, there are several problems with snow and I am not 100% sur how they are dealt with, but snow goes through obejcts, like buildings and such, but there is a way to stop it (i think).

you need to play with the coordinates to get the perfect FX.