File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -794,9 +794,9 @@ class GameGlobalShaderConstantSetter : public IShaderConstantSetter
794
794
services->setPixelShaderConstant (" skyBgColor" , bgcolorfa, 4 );
795
795
796
796
// Fog distance
797
- float fog_distance = *m_fog_range ;
798
- if (*m_force_fog_off)
799
- fog_distance = 10000 *BS ;
797
+ float fog_distance = 10000 *BS ;
798
+ if (g_settings-> getBool ( " enable_fog " ) && ! *m_force_fog_off)
799
+ fog_distance = *m_fog_range ;
800
800
services->setPixelShaderConstant (" fogDistance" , &fog_distance, 1 );
801
801
802
802
// Day-night ratio
@@ -2928,7 +2928,7 @@ void the_game(
2928
2928
Fog
2929
2929
*/
2930
2930
2931
- if (g_settings->getBool (" enable_fog" ) == true && !force_fog_off)
2931
+ if (g_settings->getBool (" enable_fog" ) && !force_fog_off)
2932
2932
{
2933
2933
driver->setFog (
2934
2934
bgcolor,
You can’t perform that action at this time.
0 commit comments