]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - cl_main.c
optimized SHOWLMP code (only used by Nehahra) to not eat any CPU time
[xonotic/darkplaces.git] / cl_main.c
index 96188f11e33c04ae8aa8c0941d45bada4da69549..79a6a1f2f87d3e97c8be8b02523cbb184c2f6784 100644 (file)
--- a/cl_main.c
+++ b/cl_main.c
@@ -134,6 +134,7 @@ void CL_ClearState(void)
        cl.max_lightstyle = MAX_LIGHTSTYLES;
        cl.max_brushmodel_entities = MAX_EDICTS;
        cl.max_particles = MAX_PARTICLES;
+       cl.max_showlmps = 0;
 
 // COMMANDLINEOPTION: Client: -particles <number> changes maximum number of particles at once, default 32768
        i = COM_CheckParm ("-particles");
@@ -158,6 +159,7 @@ void CL_ClearState(void)
        cl.lightstyle = (lightstyle_t *)Mem_Alloc(cls.levelmempool, cl.max_lightstyle * sizeof(lightstyle_t));
        cl.brushmodel_entities = (int *)Mem_Alloc(cls.levelmempool, cl.max_brushmodel_entities * sizeof(int));
        cl.particles = (particle_t *) Mem_Alloc(cls.levelmempool, cl.max_particles * sizeof(particle_t));
+       cl.showlmps = NULL;
 
        // LordHavoc: have to set up the baseline info for alpha and other stuff
        for (i = 0;i < cl.max_entities;i++)