Dust, Fog, & Smoke: Difference between revisions
No edit summary |
(→Notes) |
||
(18 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
{{ | {{lang|Dust, Fog, & Smoke}} | ||
| | |||
}} | |||
{{Abstract Mapping}} | {{Abstract Mapping}} | ||
<br> | <br> | ||
Line 9: | Line 7: | ||
== Entities == | == Entities == | ||
*[[env_fog_controller]] — adds fog to the entire map | *[[env_fog_controller]] — adds fog to the entire map | ||
**[[sky_camera]] — aside from being used to add 3D Skybox, fog on 3D Skyboxes need to be adjusted through this entity. | |||
*[[env_smokestack]] — smoke emerges, is moved by wind, and dissipates | *[[env_smokestack]] — smoke emerges, is moved by wind, and dissipates | ||
*[[func_dustcloud]] — a volume of dust | *[[func_dustcloud]] — a volume of dust | ||
Line 17: | Line 16: | ||
== Materials == | == Materials == | ||
* | *{{code|effects/fog_d1_trainstation_02}} — Used only in the distance. Fit to brush face. {{hl2|1}}-content derived source games only. | ||
* | *{{code|effects/fog_d2_coast_01}} — Used only in the distance. Fit to brush face. {{hl2}} 20th Anniversary Update only. | ||
* | ** Example usage of this material can be seen on all Water Hazard (before {{code|d1_canals_13}}), Highway 17 and Sandtraps maps, which was applied to round shaped brush and displacement fog placed in far distance, combined with {{code|env_fog_controller}} with radial fog enabled. | ||
* | *{{code|effects/fog_d1_canals_13}} — (uses {{code|effects/fog_gradient}} texture, just with color changed through {{code|$color}} VMT parameters). {{hl2}} 20th Anniversary Update only. | ||
** Example usage of this material can be seen on {{code|d1_canals_13}} map, which was applied to round shaped brush and displacement fog placed in far distance, combined with {{code|env_fog_controller}} with radial fog enabled. | |||
*{{code|shadertest/volumetricfog}} — Doesn't work. | |||
*{{code|tools/toolsfog}} — Works only with func_smokevolume. | |||
*{{code|tools/toolsskyfog}} — Non-functional, use non-existent shader {{code|SkyFog}}. | |||
== Notes == | == Notes == | ||
Line 27: | Line 30: | ||
*Shafts of light must be added by hand. There is a model for this (<code>Effects/vol_light.mdl</code>) or you can create a non-solid brush with material models/effects/vol_light001 or vol_light002. | *Shafts of light must be added by hand. There is a model for this (<code>Effects/vol_light.mdl</code>) or you can create a non-solid brush with material models/effects/vol_light001 or vol_light002. | ||
*To get fog in a 3D skybox, adjust the fog settings in the [[sky_camera]]. For best results give it the same settings as the [[env_fog_controller]]. | *To get fog in a 3D skybox, adjust the fog settings in the [[sky_camera]]. For best results give it the same settings as the [[env_fog_controller]]. | ||
*In Source games, prior to {{l4d|1}}, renders fog as a plane a certain distance away from the camera. This method is bad, as rotating the camera will strengthen or weaken the apparent amount of fog in a particular spot, even though the viewer hasn't moved at all. After {{l4d|2}}, aswell as {{hl2|2}} (since 20th anniversary, enabled in some maps only), and {{tf2branch|2}} games ({{css}}, {{hldms}}, {{hl2dm}} and {{dods}}), Valve implemented a new radial method which is independent from the viewing angle. {{mapbase|1}} also has it's own implementation of radial fog. | |||
*{{l4d2}} There is a Fog Panel in Left 4 Dead 2 that allows in-game manipulation of fog parameters. It is loaded via console command <code>fogui</code>. | *{{l4d2}} There is a Fog Panel in Left 4 Dead 2 that allows in-game manipulation of fog parameters. It is loaded via console command <code>fogui</code>. | ||
{{Bug|hidetested=1|On systems with newer GPUs (since {{nvidia|3.1}} GeForce 8000 series or newer AMD/ATI GPUs) and newer drivers, fog effect on all {{src04|2}} and {{src06|2}} games will appear more foggy than usual. This has been fixed on NVIDIA systems since driver version "516.5x" (confirmed on RTX 3060),{{Cite|1}}{{Cite|2}} but is likely still present on {{amd|3.1}}/{{intel|3.1}}. This issue is not affected when using {{code|dxlevel 81}} (DirectX 8.1 level) or lower, only {{code|dxlevel 90}} (DirectX 9.0 level) or higher. | |||
Additionally, using any Direct3D 9 wrapper (D3D9 to D3D11 via {{pcgw|DgVoodoo_2|dgVoodoo 2}} for example) on this branch, even on systems with newer NVIDIA drivers that fixes this issue, will also cause this fog issues to appear. | |||
{{expand|title=Comparison| | |||
[[File:Source - Old Engine fog bug.jpg|240px]] | |||
}} | |||
}} | |||
== See also == | == See also == | ||
Line 39: | Line 49: | ||
--> | --> | ||
*[ | *[https://gamebanana.com/mods/3891 Fog prefab for Episode One and Two] Realistic, non-fps killing fog - tutorial | ||
{{references|1= | |||
{{ref2|cite id=1|access-date={{#time: F d, Y }}|[https://www.vogons.org/viewtopic.php?p{{=}}1088622#p1088622 Source DirectX9 grey fog bug]<br>'''a0divided:''' This bug basically only happens while using DX9 with games that run on pre-Orangebox versions of Source, like Sin as mentioned above or HL2 & EP1 before the 2010 engine update. | |||
But what's interesting is that this bug was fixed at some point by Nvidia, at least on their newer cards with the latest drivers. I currently have an RTX 3060 Laptop GPU with driver 516.5 and the fog actually works properly on DX9. Unfortunately, I think it's still bugged with AMD or Intel GPUs...}} | |||
{{ref2|cite id=2|Verified by [[User:Kr0tchet|leonidakarlach]] ([[User talk:Kr0tchet|talk]]) 01:36, 14 September 2024 (PDT):<br>Appeared to be fixed. Using RTX 3060 (desktop) and driver version 560.81. Using something like DgVoodoo2 would break this again.}} | |||
}} | |||
[[Category:Hubs]] | [[Category:Hubs]] | ||
[[Category:English]] |
Latest revision as of 01:29, 20 April 2025
Abstract Mapping series Discuss your thoughts - Help us develop the articles or ideas you want |
---|
Ammunition | List of HL2 Animals and Creatures | Mapping with Antlions | Beams and Lasers | Cables and Ropes | Moving Clouds | Color Theory in Level Design | Combat | Combine | Compression (Source 1) | Doors | Dust, Fog, & Smoke | Elevators | Level Transitions | Environmental Lighting, Sun, Weather, & Outdoors | Explosions | Fire | Half-Life 2 Foliage | Glass & Windows | Headcrab | Health | Ladders | Lighting | Optimization (level design) | Physics | Retinal scanners | Sound and Music | Special effects | Terrain | Trains | Turrets | Water | Weapons | Zombie |
This article is about adding smoke, dust, fog, etc, to a map. Due to their similarities, most of these effects can be achieved by variations of each other.
Entities
- env_fog_controller — adds fog to the entire map
- sky_camera — aside from being used to add 3D Skybox, fog on 3D Skyboxes need to be adjusted through this entity.
- env_smokestack — smoke emerges, is moved by wind, and dissipates
- func_dustcloud — a volume of dust
- env_steam — fast-moving version of env_smokestack, without wind
- env_dustpuff — emits puffs of dust
- env_smoketrail
- func_smokevolume
Materials
- effects/fog_d1_trainstation_02 — Used only in the distance. Fit to brush face. Half-Life 2-content derived source games only.
- effects/fog_d2_coast_01 — Used only in the distance. Fit to brush face.
20th Anniversary Update only.
- Example usage of this material can be seen on all Water Hazard (before d1_canals_13), Highway 17 and Sandtraps maps, which was applied to round shaped brush and displacement fog placed in far distance, combined with env_fog_controller with radial fog enabled.
- effects/fog_d1_canals_13 — (uses effects/fog_gradient texture, just with color changed through $color VMT parameters).
20th Anniversary Update only.
- Example usage of this material can be seen on d1_canals_13 map, which was applied to round shaped brush and displacement fog placed in far distance, combined with env_fog_controller with radial fog enabled.
- shadertest/volumetricfog — Doesn't work.
- tools/toolsfog — Works only with func_smokevolume.
- tools/toolsskyfog — Non-functional, use non-existent shader SkyFog.
Notes
- env_smokestack and func_dustcloud use numerous sprites to achieve their effect, and can therefore be very expensive to render (some settings will slow your map, especially on low-end systems).
- CS:S has some cloud props.
- Shafts of light must be added by hand. There is a model for this (
Effects/vol_light.mdl
) or you can create a non-solid brush with material models/effects/vol_light001 or vol_light002. - To get fog in a 3D skybox, adjust the fog settings in the sky_camera. For best results give it the same settings as the env_fog_controller.
- In Source games, prior to Left 4 Dead, renders fog as a plane a certain distance away from the camera. This method is bad, as rotating the camera will strengthen or weaken the apparent amount of fog in a particular spot, even though the viewer hasn't moved at all. After
Left 4 Dead, aswell as
Half-Life 2 (since 20th anniversary, enabled in some maps only), and
Team Fortress 2 branch games (
,
,
and
), Valve implemented a new radial method which is independent from the viewing angle. Mapbase also has it's own implementation of radial fog.
There is a Fog Panel in Left 4 Dead 2 that allows in-game manipulation of fog parameters. It is loaded via console command
fogui
.



Additionally, using any Direct3D 9 wrapper (D3D9 to D3D11 via dgVoodoo 2 for example) on this branch, even on systems with newer NVIDIA drivers that fixes this issue, will also cause this fog issues to appear.
See also
External links
- Fog prefab for Episode One and Two Realistic, non-fps killing fog - tutorial
References
References | ||||
---|---|---|---|---|
|