]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
added bounding of info->particleaccumulator so that bogus values won't cause a very...
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Wed, 14 Feb 2007 06:54:24 +0000 (06:54 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Wed, 14 Feb 2007 06:54:24 +0000 (06:54 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6838 d7cf8633-e32d-0410-b094-e92efae38249

cl_particles.c

index c0238225efcb67ac8ebae73cd229682ab2e3709e..8b80cadddc7c0127772d25ae927664270161f59d 100644 (file)
@@ -1119,6 +1119,7 @@ void CL_ParticleTrail(int effectnameindex, float pcount, const vec3_t originmins
                                                info->particleaccumulator += info->countabsolute + pcount * info->countmultiplier * cl_particles_quality.value;
                                                trailstep = 0;
                                        }
+                                       info->particleaccumulator = bound(0, info->particleaccumulator, 16384);
                                        for (;info->particleaccumulator >= 1;info->particleaccumulator--)
                                        {
                                                if (info->tex[1] > info->tex[0])