friggin fog -1 reply

Please wait...


Slightly cooler than a n00b

50 XP

16th July 2002

0 Uploads

39 Posts

0 Threads

#1 16 years ago

Hello, i thought id put a thread in here cause its not used often. anyway i had a fog and texture problem not too long ago. this had to do with brush fogs. i couldnt use a foghull because i have an effect that is corrupted when this is used (hopefully i can fix this problem due to the horrible fps). But i had the fog brush lifted off the bottom of the worldspawn because otherwise it would be cut out in about the middle (stupid problems). but if there is any visible brushes, patches, models, ect. not within the fog brush it will make that entity visible even after the distance to opaque. hopefully if any of you mappers get this problem, this thread will help the problem. if not just email me at [email][/email].

good luck mapping!


Wolfy 0.2 Admin

50 XP

17th May 2002

0 Uploads

25 Posts

0 Threads

#2 16 years ago

The path is certainly.. erm... foggy when it comes to fog...

You already have an understanding of most of the info I'm putting here, but since people may want to reference this info for their own fog maps, I'll go through it and try to answer your questions in the process.

fogparms OpaqueDistance (RED GREEN BLUE) A shader with this command is applied to a brush spanning the area you wish to fog. Opaque distance is how far in game units you want to be able to see. Color values are expressed in normalised 0 to 1 format, 1 being the equivilent of 255 in graphic editing problams, eg white would expressed as ( 1.0 1.0 1.0 )

Problem1: One edge, and only one edge, of the fog brush must be visible to the engine for it to fog the area properly. The best solution I have found is to put a "caulk chimney" which extends through the bottom of the fog brush and through the top, this will trick the engine into having one face visible all the time.

Problem2: Using this on large areas will hit fps hard and there really is no work-around to this, other than keeping the area small.

fogvars OpaqueDistance/Density ( RED GREEN BLUE ) Use this from your sky shader, it takes the same parameters as the q3 stock standard fogparms command and can also have a optional density value between 0 and 1, eg: 0.5 This type of fog is alot faster than the fogparms brush method, however it's got some very serious problems:

Problem1: Blended shaders, the engine will not fog them properly. This is an engine issue and the only solution I have found is to change them to vertex lit instead of lightmapped.

Problem2: Lightmapped terrain(using q3map2), where the blending shaders will not be fogged properly. This stems from the same cause as problem1, however the author of q3map2 may work around this problem in a later release which may or may not fix problem1 in the process. You can still use lightmapped terrain, however with no blendng stages. :(

Problem3: Brushes extending further than about half the opaque distance will not be fogged properly. The solution, yep you guessed it, is to chop your brushwork up into smaller chunks.

Well I hope that helps some.. it can be a very tricky thing to get working just right, especially in combination with some other features. Let me know if I missed something, it's late and my eyes are hanging out.

:cya: Codey