]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - cl_particles.c
Add R_LightPoint which is fast version of R_CompleteLightPoint that only grabs ambien...
[xonotic/darkplaces.git] / cl_particles.c
index 328ab48a4a897eee80c483f0deff670fa3759102..12ab2bb57608a89593918ca0655d3dfb8d50e28d 100644 (file)
@@ -2537,12 +2537,7 @@ void R_DrawParticle_TransparentCallback(const entity_render_t *ent, const rtligh
                        c4f[3] = alpha;
                        // note: lighting is not cheap!
                        if (particletype[p->typeindex].lighting)
-                       {
-                               R_CompleteLightPoint(ambient, diffuse, diffusenormal, p->org, LP_LIGHTMAP | LP_RTWORLD | LP_DYNLIGHT);
-                               c4f[0] *= (ambient[0] + 0.5 * diffuse[0]);
-                               c4f[1] *= (ambient[1] + 0.5 * diffuse[1]);
-                               c4f[2] *= (ambient[2] + 0.5 * diffuse[2]);
-                       }
+                               R_LightPoint(c4f, p->org, LP_LIGHTMAP | LP_RTWORLD | LP_DYNLIGHT);
                        // mix in the fog color
                        if (r_refdef.fogenabled)
                        {