X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=cl_particles.c;fp=cl_particles.c;h=9d64080b6b87ba3d78eff7855cf3103652661e29;hp=5e873998d1e7f1ee2bf4c35a9fb4da8ba2614417;hb=4e1f3f76d5fe7befe20034a730630c314d45956b;hpb=18196a9701fcdcd17096f8ec03e5bc615e99ca12 diff --git a/cl_particles.c b/cl_particles.c index 5e873998..9d64080b 100644 --- a/cl_particles.c +++ b/cl_particles.c @@ -2723,10 +2723,14 @@ static void R_DrawParticle_TransparentCallback(const entity_render_t *ent, const // note: lighting is not cheap! if (particletype[p->typeindex].lighting) { + float a[3], c[3], dir[3]; vecorg[0] = p->org[0]; vecorg[1] = p->org[1]; vecorg[2] = p->org[2]; - R_LightPoint(c4f, vecorg, LP_LIGHTMAP | LP_RTWORLD | LP_DYNLIGHT); + R_CompleteLightPoint(a, c, dir, vecorg, LP_LIGHTMAP | LP_RTWORLD | LP_DYNLIGHT, r_refdef.scene.lightmapintensity, r_refdef.scene.ambientintensity); + c4f[0] = p->color[0] * colormultiplier[0] * (a[0] + 0.25f * c[0]); + c4f[1] = p->color[1] * colormultiplier[1] * (a[1] + 0.25f * c[1]); + c4f[2] = p->color[2] * colormultiplier[2] * (a[2] + 0.25f * c[2]); } // mix in the fog color if (r_refdef.fogenabled)