Water lod control: Difference between revisions
Jump to navigation
Jump to search


m (Changed parameters of {{this is a}} to comply with the updated version. This action was performed by a bot.) |
(caveats hidden needs more information what game is it about) |
||
Line 12: | Line 12: | ||
{{IO|SetCheapWaterEndDistance|Set the distance that water finishes transitioning to cheap water.|param=float}} | {{IO|SetCheapWaterEndDistance|Set the distance that water finishes transitioning to cheap water.|param=float}} | ||
{{expand|title={{elaborate}}| | |||
== Caveats == | == Caveats == | ||
{{bug|The water_lod_controller was disabled late in development. Any water with reflections enabled are always rendered expensively or with bForceExpensive always set to true.}} | {{bug|The water_lod_controller was disabled late in development. Any water with reflections enabled are always rendered expensively or with bForceExpensive always set to true.}} | ||
Line 24: | Line 26: | ||
You may also change line 2212 with brute force code. All the materials in this example were returning bForceExpensive true regardless of settings: | You may also change line 2212 with brute force code. All the materials in this example were returning bForceExpensive true regardless of settings: | ||
<source lang=cpp>bForceExpensive = false;</source> | <source lang=cpp>bForceExpensive = false;</source> | ||
}} | |||
== See also == | == See also == | ||
* [[Adding Water]] | * [[Adding Water]] | ||
[[Category:Water]] | [[Category:Water]] |
Revision as of 13:22, 17 May 2024


![]() |
---|
CWaterLODControl |
![]() |

water_lod_control
is a point entity available in all Source games. It is used to control the LOD behavior of any water in the map. If your map has water, this entity is required. VBSP will add one in if it's missing.
Keyvalues
- Start Transition to Cheap Water (cheapwaterstartdistance) <float>
- This is the distance from the camera that water will start transitioning to cheap water, in hammer units.
- End Transition to Cheap Water (cheapwaterenddistance) <float>
- This is the distance from the camera that water will finish transitioning to cheap water, in hammer units.
Inputs
- SetCheapWaterStartDistance <float >
- Set the distance that water starts transitioning to cheap water.
- SetCheapWaterEndDistance <float >
- Set the distance that water finishes transitioning to cheap water.
Caveats![]() To re-enable you will need to modify code in if( !r_WaterDrawReflection.GetBool() )
Also replace line 2256 with: if ( (fogVolumeInfo.m_flDistanceToWater >= m_flCheapWaterEndDistance) || bForceCheap )
You may also change line 2212 with brute force code. All the materials in this example were returning bForceExpensive true regardless of settings: bForceExpensive = false;
|