Flux on 16/1/2008 at 23:17
Wiki says it may reduce performance but I don't see any difference for fps if I add fog or remove it. Sure it looks better with the fog and this is a test map without any ai or objects.
Will the framerate drop later on when I add more stuff to the level?
str8g8 on 17/1/2008 at 10:57
Quote:
Will the framerate drop later on when I add more stuff to the level?
Yes :cheeky: but fog or no fog will only have a marginal effect I think. The big factors are the number and type of lights, and overall level design, ie portalling etc.
Ziemanskye on 17/1/2008 at 18:37
The Really important thing with fog in TDS is that it DOESN'T affect engine visibility. In most things having fog lets you have more detail because once a certain distance is passed things stop being rendered, but that doesn't happen here, so you can't use it to *increase* performance like in UE2 or Source (or DromEd, as far as I know, or whatever).
It's something to use for artistic effect, not performance gain.
(Oh, and I think particles get rendered after the fog, hence that test map I did a while back with the windows glowing in the gloom, which I may go back to at some point and try to turn into a real level)
Judith on 24/1/2008 at 12:33
I added fog to some parts of my map (a neat trick with volumes & trigger scripts) and it didn't have any noticeable impact on the performance in areas where the lights were OmniNoShadow or AmbientVertex. But I tried to change those lights to shadow casting ones... Massive framerate drop: 1-3 fps from 75 :erm: So it's exacly as Z. said, multiple shadow-casting lights kill everything, with or without fog, actually :rolleyes:
Flux on 24/1/2008 at 12:58
Quote:
I added fog to some parts of my map (a neat trick with volumes & trigger scripts)
Wait, so you can have ground fog? The kind of fog that's only knee-level for the player?
Care to explain your neat trick?;)
Ziemanskye on 24/1/2008 at 18:19
I think he means some "rooms" were foggy and others weren't: burst steam pipes and particles at the doors with a foggy room in the middle of an otherwise non-fogged level kind of idea.
You could spam a load of particles in for low lying fog, but that's probably the best you'll manage in this engine.
Judith on 24/1/2008 at 21:56
No, this is not the fog placed near the ground level, this can be achieved with particles, yet I wouldn't advise it - when player touches multiple steam particles for example, the framerate goes down suprisingly quickly.
But you can have normal fog in any room you like, not in whole level, and you can change it's parameters as you like. basically you have to do the following:
1. First of all, enable fog in your level (in level info), and set it to very high values, going far away out of the player's view or even your map. Give it a small range, like Start: 10000, End: 10001.
2. Build a volume as big as the area where the fog should be, and create two scripts in it.
Fog_enter
When the linked volumes (MYSELF) are breached by (PLAYER)
Change level fog range settings to Start, End, over n seconds (enter desired fog values)
Change level fog color settings to R, G, B, A, over n seconds
Reset scripts conditions and actions
Fog_exit
When the linked volumes (MYSELF) are exited by (PLAYER)
Change level fog range settings to Start, End, over n seconds (enter initial fog values)
Change level fog color settings to R, G, B, A, over n seconds
Reset scripts conditions and actions
If you want to have only one fog color in your level, you don't need "change level fog color", just set the desired values in level info and then tweak the range and timing - you can have a nice transition from "no fog" to "fog" and vice versa. The speed of the "fog closing in" and "fog vanishing" depends on the difference between initial fog range values, the target values and the time given for the changes. I have 2 "types" of fog in my level so i also needed to change the color to match each environment.
Ziemanskye on 25/1/2008 at 21:25
So the fog actually "rolls" in and out?
That could be a very cool way to start my mission - roof, window, *fog rolls out* CITY!
Judith on 25/1/2008 at 22:17
Exactly, the effect is quite nice, I think you'll like it :)
Flux on 26/1/2008 at 22:24
Thanks for the tip. I thought you could adjust height of fog by volumes to give ground-fog effect, but it seems not possible?