Set hardcoded fog density to render fog under the latest GoldSrc version.

This commit is contained in:
Andrey Akhmichin 2024-02-24 03:12:42 +05:00
parent 65a1492b12
commit 53e9c36f27
1 changed files with 4 additions and 0 deletions

View File

@ -188,6 +188,10 @@ void BlackFog ( void )
//Not in water and we want fog.
static float fColorBlack[3] = {0,0,0};
bool bFog = g_iWaterLevel < 2 && g_fStartDist > 0 && g_fEndDist > 0;
if( g_fEndDist > 0 )
gEngfuncs.pTriAPI->FogParams( 0.0005f, true );
if (bFog)
gEngfuncs.pTriAPI->Fog ( fColorBlack, g_fStartDist, g_fEndDist, bFog );
else