From 0238810f34ec11ac0f1d179e09a104d7d466342f Mon Sep 17 00:00:00 2001 From: SmileTheory Date: Tue, 24 Jan 2017 20:17:06 -0800 Subject: [PATCH] OpenGL2: Render dlights only when r_lightmap is 0. https://github.com/ioquake/ioq3/issues/246 --- code/renderergl2/tr_shade.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/renderergl2/tr_shade.c b/code/renderergl2/tr_shade.c index fd88191e..eeeed94b 100644 --- a/code/renderergl2/tr_shade.c +++ b/code/renderergl2/tr_shade.c @@ -1598,7 +1598,7 @@ void RB_StageIteratorGeneric( void ) // // now do any dynamic lighting needed // - if ( tess.dlightBits && tess.shader->sort <= SS_OPAQUE + if ( tess.dlightBits && tess.shader->sort <= SS_OPAQUE && r_lightmap->integer == 0 && !(tess.shader->surfaceFlags & (SURF_NODLIGHT | SURF_SKY) ) ) { if (tess.shader->numUnfoggedPasses == 1 && tess.xstages[0]->glslShaderGroup == tr.lightallShader && (tess.xstages[0]->glslShaderIndex & LIGHTDEF_LIGHTTYPE_MASK) && r_dlightMode->integer)