Game Development Community

Fog

by Chris Sargent · in Torque 3D Professional · 07/27/2009 (5:33 pm) · 13 replies

I was reading the post about the problem with fog and I got to looking around in my level and I realised that I have absolutely no idea how to create fog in T3D. Can I get a nudge in the right direction?

Thanks!

#1
07/27/2009 (5:39 pm)
Check the documentation, it should be in there.
#2
07/27/2009 (5:52 pm)
It's in "level info" in the object editor tree. *nudge*
#3
07/27/2009 (5:54 pm)
Thanks to you both. I read the documentation from front to back and never saw fog in there but I haven't looked lately to see if there were any new additions!
#4
07/28/2009 (3:07 am)
That's weird...

Well i found how to do some stuff by searching it on google and it lead me to the documentation, so dunno.

Look at me ramble on...
#5
07/29/2009 (1:28 pm)
The LevelInfo object has a field called fogDensity
#6
07/29/2009 (2:48 pm)
thanks for the help everyone though i'm not finding how to do what I want.

this is what I am picturing for a part of my game. A valley that is enshrouded in fog and the player can walk through this valley in the fog.

Using the levelinfo I was able to set my fog but it was always off in the distance. I changed my visible distance, but then as I move the fog rolls back away from me.

I want (if possible) to have my player walk through a fog bank.
#7
07/29/2009 (11:53 pm)
@Chris:

Sounds cool, but I do not know how to do that yet. Sounds like a local fog, may be it is possible to create a Zone with Fog, but I have not looked after this so far.
#8
07/30/2009 (1:40 pm)
Set your fogOffset to 0.0 to fix one issue, then you can use fogAtmosphereHeight to have fog fade out in positive z, move your terrain around and mess with that number till it lines up with your valley.
#9
07/30/2009 (3:18 pm)
James,

Thanks I'll give that a try tonite. One way I thought of doing it was by using clouds. I added a cloud layer which looked pretty good, but I was unable to move it. No matter what I set the position at my cloud layer stayed in the sky. I'll give what you suggested a try here in just a little bit.
#10
07/30/2009 (3:25 pm)
The clouds are really just a flat texture, so they have no volume ( even if they could be moved ). But I'm glad to see they were convincing enough to trick somebody!
#11
07/30/2009 (3:27 pm)
well i'll admit that is one great looking "flat" texture hehe.

Of coures it didn't help having a position setting for them then, but in all honesty if you hadn't told me that they were a flat texture I wouldn't have guessed.
#12
08/12/2009 (9:47 am)
can't edit fog color and alpha and fogDensity....:<
#13
08/12/2009 (12:49 pm)
@Szzg007
fogColor and fogDensity should be editable fields on the LevelInfo object. What is not working for you?