Precipitation issues

From Valve Developer Community
Jump to: navigation, search

A func_precipitation can be very effective for your map's atmosphere. However, there are some glitches that can cause your map to lock up and crash, or at the least run slowly.

Major glitches

  1. If the precipitation is too dense, causing more then 32000 vertices visible at once, it will cause a fatal crash. Dense precipitation is possible, but in sparsely populated areas.
  2. If you have rain and water in the same map, make sure they are positioned so that the rain does not go into the water. This has not been verified as a crash-causing glitch, but by preventing this, you can avoid more serious glitches.
  3. Make sure your rain stays within your map. Rain and snow fall some ways below the end of your func_precipitation, and as such could fall out of your map. This has been noted as causing a map lock-up, yet does not create a compile glitch. So, it is worth checking if you have precipitation in your map.
  4. If you use a func_smokevolume brush under your func_precipitation, make sure that there is enough space in between, so that the precipitation, as it falls down, doesn't enter the smoke volume below. If it does, the map will stop loading at the end of the progress bar (there are no compile errors).

Minor glitches

Sometimes, when a func_precipitation is next to a thin enough wall, the rain or snow will fall through the wall and into your building. Since func_precipitation is a cosmetic entity, this has no effect on gameplay.

The density keyvalue is based on the volume of the individual func_precipitation. Because of this, having several func_precipitations of varying sizes with the same densities can create a varying rain intensity. This is not a glitch, but can be difficult to alter exactly. In this case, a good guess will have to do. You can, of course, calculate the volumes of the individual func_precipitations, by multiplying length, height and depth of each and compare the results.

If there is a point_camera entity active in a map containing rain, it will generally cause the rain to not render at all. This can be verified in game using the r_rainprofile 1 cmd. A work around for this is to of course disable any cameras when a player is to see rain, (add an I/O trigger: OnTrigger camera_name SetOff) --tehwin 17:20, 6 March 2009 (PDT)

If you are too close to the top of the rain volume the rain will stop rendering even though you are still inside of it.

Note:You can also put multiple func_precipitation brushes in the same area.

In Portal 2, if func_precipitation is used with portals, visual artifacts may occur. This is especially true if one or both open portals are visible onscreen. Performance will also take a fairly major hit.