From b5ee08279706bac8cb70102aa4a29992d3e8d078 Mon Sep 17 00:00:00 2001 From: myT Date: Tue, 11 Apr 2017 17:47:21 +0200 Subject: [PATCH] the blood decals on pukka3tourney2 were broken because of code adding lightmap stages --- code/renderer/tr_shader.cpp | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/code/renderer/tr_shader.cpp b/code/renderer/tr_shader.cpp index e9fcc8f..0b2184c 100644 --- a/code/renderer/tr_shader.cpp +++ b/code/renderer/tr_shader.cpp @@ -1758,20 +1758,6 @@ static void FindLightingStages() shader.lightingStages[ type ] = i; } - - // having to add lightmap stages to every shader by hand is beyond retarded - if ( (shader.lightmapIndex >= 0) && (shader.lightingStages[ST_LIGHTMAP] == -1) ) { - if (i >= MAX_SHADER_STAGES) - ri.Error( ERR_DROP, "too many stages in shader %s\n", shader.name ); - shader.lightingStages[ST_LIGHTMAP] = i; - stages[i].active = qtrue; - stages[i].type = ST_LIGHTMAP; - stages[i].tcGen = TCGEN_LIGHTMAP; - stages[i].bundle.image[0] = tr.lightmaps[shader.lightmapIndex]; - stages[i].rgbGen = CGEN_IDENTITY; // lightmaps are scaled on creation for identitylight - stages[i].stateBits = GLS_DEFAULT | GLS_SRCBLEND_DST_COLOR | GLS_DSTBLEND_ZERO; - ++shader.numStages; - } }