X-Git-Url: https://de.git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=gl_rsurf.c;h=27f6d6db4c2774aea025b5c3712e4d4e41e64689;hp=50d3f2db1fb0338e395c8088463d8d94619108b9;hb=5bc6231f75923291e67a4b88bedd1dd013d62e91;hpb=c32e446060df3ccfcbec6fa49ab1146ae2ba7076 diff --git a/gl_rsurf.c b/gl_rsurf.c index 50d3f2db..27f6d6db 100644 --- a/gl_rsurf.c +++ b/gl_rsurf.c @@ -792,7 +792,7 @@ void R_Q1BSP_DrawLight(entity_render_t *ent, float *lightcolor, int numsurfaces, vec3_t lightcolorpants, lightcolorshirt; // 128-224 are backwards ranges int b = (ent->colormap & 0xF) << 4;b += (b >= 128 && b < 224) ? 4 : 12; - if (texture->skin.pants && b >= 224) + if (texture->skin.pants && b < 224) { qbyte *bcolor = (qbyte *) (&palette_complete[b]); lightcolorpants[0] = lightcolor[0] * bcolor[0] * (1.0f / 255.0f); @@ -803,7 +803,7 @@ void R_Q1BSP_DrawLight(entity_render_t *ent, float *lightcolor, int numsurfaces, VectorClear(lightcolorpants); // 128-224 are backwards ranges b = (ent->colormap & 0xF0);b += (b >= 128 && b < 224) ? 4 : 12; - if (texture->skin.shirt && b >= 224) + if (texture->skin.shirt && b < 224) { qbyte *bcolor = (qbyte *) (&palette_complete[b]); lightcolorshirt[0] = lightcolor[0] * bcolor[0] * (1.0f / 255.0f);