How do I make it snow? (FAQ)

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
User avatar
SBF_Dann_Boeing
Groove Walrus
Groove Walrus
Posts: 1529
Joined: Wed Aug 31, 2005 11:33 pm
xbox live or psn: No gamertag set
Location: An Igloo High Upon a Mountain Top

How do I make it snow? (FAQ)

Post by SBF_Dann_Boeing »

Ok how do I make it snow? There isn't anything about sky files or precipitation in the "Everything You Need" thread.
Caleb1117
2008 Most Original Avatar
Posts: 3096
Joined: Sun Aug 20, 2006 5:55 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: X-Fire: caleb1117 ಠ_ಠ

Adding snow to your map

Post by Caleb1117 »

You need to insert some code into your ABC.fx (environment effects) file located in your world1 folder, if you don't have an fx file then create one or copy one from the assets.

Insert this code into ABC.fx (replace ABC with your 3 letter modID):

Code: Select all

Effect("Precipitation")
{
	Enable(1);
	Type("Quads");
	Texture("fx_snow");
	ParticleSize(0.015);
	Color(255, 255, 255);
	Range(15.0);
	Velocity(2.0);
	VelocityRange(0.8);
	PS2()
	{
		ParticleDensity(80.0);
	}
	XBOX()
	{
		ParticleDensity(100.0);
	}
	PC()
	{
		ParticleDensity(100.0);
	}
	ParticleDensityRange(0.0);
	CameraCrossVelocityScale(1.0);
	CameraAxialVelocityScale(1.0);
	AlphaMinMax(0.3, 0.45);
	RotationRange(2.0);
}
You can safely omit the XBOX and PS2 blocks from the code above.
User avatar
SBF_Dann_Boeing
Groove Walrus
Groove Walrus
Posts: 1529
Joined: Wed Aug 31, 2005 11:33 pm
xbox live or psn: No gamertag set
Location: An Igloo High Upon a Mountain Top

Re: Let it Snow

Post by SBF_Dann_Boeing »

Then the map crashes with this error:
Message Severity: 3
c:\battlefront2\main\pebblefl\common\PblConfig.h(30)
PblConfig: invalid config; 'DATA' chunk expected
chunk.GetId() == _ID( 'D', 'A', 'T', 'A' )

Message Severity: 3
c:\battlefront2\main\pebblefl\common\PblConfig.h(35)
PblConfig: invalid config; 'DATA' chunk with invalid string table
m_uiNumArgs*4 + uiStringTableLen <= CONFIG_MAX_DATA_ARGS*4
Caleb1117
2008 Most Original Avatar
Posts: 3096
Joined: Sun Aug 20, 2006 5:55 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: X-Fire: caleb1117 ಠ_ಠ

Re: Let it Snow

Post by Caleb1117 »

SBF_Dann_Boeing wrote:Then the map crashes with this error:
Message Severity: 3
c:\battlefront2\main\pebblefl\common\PblConfig.h(30)
PblConfig: invalid config; 'DATA' chunk expected
chunk.GetId() == _ID( 'D', 'A', 'T', 'A' )

Message Severity: 3
c:\battlefront2\main\pebblefl\common\PblConfig.h(35)
PblConfig: invalid config; 'DATA' chunk with invalid string table
m_uiNumArgs*4 + uiStringTableLen <= CONFIG_MAX_DATA_ARGS*4
._O

WTH?

Ok, I have no clue how that happened, should have worked flawlessly.
Never ever seen an error like that eather.
User avatar
SBF_Dann_Boeing
Groove Walrus
Groove Walrus
Posts: 1529
Joined: Wed Aug 31, 2005 11:33 pm
xbox live or psn: No gamertag set
Location: An Igloo High Upon a Mountain Top

Re: Let it Snow

Post by SBF_Dann_Boeing »

here's my sky file
Hidden/Spoiler:
[code]SkyInfo()
{
Enable(1);

PS2()
{
NearSceneRange(1.750000, 100.000000, 150.000000);
FarSceneRange(0.0);
NearSplitScreenRange(0.5, 60.000000, 70.000000);
FarSplitScreenRange(0.0);
}
PC()
{
NearSceneRange(60.000000, 180.000000, 80.000000, 220.000000);
FarSceneRange(0.0);
}
XBOX()
{
NearSceneRange(0.5, 100.000000, 150.000000);
FarSceneRange(0.0);
NearSplitScreenRange(0.5, 80.000000, 100.000000);
FarSplitScreenRange(0.0);
}
}

DomeInfo()
{
Texture("SKY_naboo2.tga");
Angle(-90.000000);
Ambient(255.000000, 255.000000, 255.000000);
Softness(1);
SoftnessParam(60);

XBOX()
{
TerrainBumpTexture("nab2_bump_1", 1.0);
}
PC()
{
TerrainBumpTexture("nab2_bump_1", 1.0);
}
DomeModel()
{
Geometry("nab2_sky_dome");
}
DomeModel()
{
Geometry("sky_yav2_planet");
Offset(100.0);
MovementScale(0.995);
}
Stars()
{
RandomSeed(1);
TwinkleFactor(1.2);
TwinkleFrequency(0.5);
Color(255, 255, 255, 255);
XBOX()
{
NumStars(1000);
BrightStarPercent(90.0);
AlphaMin(15);
ColorSaturation(0.5);
}
PC()
{
NumStars(8000);
BrightStarPercent(90.0);
AlphaMin(30);
ColorSaturation(.75);
}
PS2()
{
NumStars(1000);
StarTexture("fx_star");
BrightStarPercent(10.0);
AlphaMin(10);
ColorSaturation(0.2);
}
}
Effect("Precipitation")
{
Enable(1);
Type("Quads");
Texture("fx_snow");
ParticleSize(0.015);
Color(255, 255, 255);
Range(15.0);
Velocity(2.0);
VelocityRange(0.8);
PS2()
{
ParticleDensity(80.0);
}
XBOX()
{
ParticleDensity(100.0);
}
PC()
{
ParticleDensity(100.0);
}
ParticleDensityRange(0.0);
CameraCrossVelocityScale(1.0);
CameraAxialVelocityScale(1.0);
AlphaMinMax(0.3, 0.45);
RotationRange(2.0);
}
}[/code]
Note that I have done absolutely nothing but edit this file and munge for this map
Caleb1117
2008 Most Original Avatar
Posts: 3096
Joined: Sun Aug 20, 2006 5:55 pm
Projects :: No Mod project currently.
xbox live or psn: No gamertag set
Location: X-Fire: caleb1117 ಠ_ಠ

Re: Let it Snow

Post by Caleb1117 »

OOOOOOOh

You should put that bit I gave you in the ABC.fx file, not sky.
User avatar
SBF_Dann_Boeing
Groove Walrus
Groove Walrus
Posts: 1529
Joined: Wed Aug 31, 2005 11:33 pm
xbox live or psn: No gamertag set
Location: An Igloo High Upon a Mountain Top

Re: Let it Snow

Post by SBF_Dann_Boeing »

OOOOOOh

that's what i get for not reading carefully

EDIT
ok thx it works now
Wolffe1138
Recruit Womprat Killer
Posts: 9
Joined: Wed Apr 12, 2017 5:57 pm
Projects :: No Mod project currently.
Games I'm Playing :: SWBF 2
xbox live or psn: No gamertag set

Re: How do I make it snow? (FAQ)

Post by Wolffe1138 »

I did as you said and here is my FX file, but there is no snow is this for only battlefront one or am I missing something here?
Hidden/Spoiler:
Effect("ColorControl")
{
PS2()
{
Enable(1);
WorldBrightness(0.46);
WorldContrast(0.48);
WorldSaturation(0.65);
}
}


Effect("Precipitation")
{
   Enable(1);
   Type("Quads");
   Texture("fx_snow");
   ParticleSize(0.015);
   Color(255, 255, 255);
   Range(15.0);
   Velocity(2.0);
   VelocityRange(0.8);
   PS2()
   {
      ParticleDensity(80.0);
   }
   XBOX()
   {
      ParticleDensity(100.0);
   }
   PC()
   {
      ParticleDensity(100.0);
   }
   ParticleDensityRange(0.0);
   CameraCrossVelocityScale(1.0);
   CameraAxialVelocityScale(1.0);
   AlphaMinMax(0.3, 0.45);
   RotationRange(2.0);
}

Effect("Lightning")
{
Enable(1);
Color(255, 255, 255);
SunlightFadeFactor(0.1);
SkyDomeDarkenFactor(0.4);
BrightnessMin(1.0);
FadeTime(0.2);
TimeBetweenFlashesMinMax(3.0, 5.0);
TimeBetweenSubFlashesMinMax(0.01, 0.5);
NumSubFlashesMinMax(2, 5);
HorizonAngleMinMax(30, 60);
SoundCrack("kam_amb_thunder");
SoundSubCrack("kam_amb_thundersub");
}


LightningBolt("skybolt")
{
Texture("lightning");
Width(30.0);
FadeTime(0.5);
BreakDistance(20.0);
TextureSize(30.0);
SpreadFactor(20.0);
MaxBranches(2.0);
BranchFactor(0.5);
BranchSpreadFactor(8);
BranchLength(80.0);
InterpolationSpeed(0.4);
NumChildren(1);
ChildBreakDistance(15.0);
ChildTextureSize(8.0);
ChildWidth(1.0);
ChildSpreadFactor(10.0);
Color(255,255,255,255);
ChildColor(255,255,255,150);
}

Effect("hdr")
{
Enable(1)
}
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: How do I make it snow? (FAQ)

Post by Marth8880 »

Did you copy over fx_snow.tga (from Hoth or another world with snow) to your world1 folder?
Wolffe1138
Recruit Womprat Killer
Posts: 9
Joined: Wed Apr 12, 2017 5:57 pm
Projects :: No Mod project currently.
Games I'm Playing :: SWBF 2
xbox live or psn: No gamertag set

Re: How do I make it snow? (FAQ)

Post by Wolffe1138 »

Marth8880 wrote:Did you copy over fx_snow.tga (from Hoth or another world with snow) to your world1 folder?
No but I will give it try, I'm not finding the fx_snow.tga in the hoth folder unless its the snow_1 in the msh folder in the assets

EDIT: Nvm found it but it still doesn't show when its in the world1 folder
Post Reply