diff --git a/libs/video/renderer/gl/gl_dyn_part.c b/libs/video/renderer/gl/gl_dyn_part.c index bedaa7f37..f8e3ab923 100644 --- a/libs/video/renderer/gl/gl_dyn_part.c +++ b/libs/video/renderer/gl/gl_dyn_part.c @@ -113,11 +113,11 @@ particle_new_random (ptype_t type, int texnum, const vec3_t org, int org_fuzz, rnd = rand (); porg[0] = o_fuzz * ((rnd & 63) - 31.5) / 63.0 + org[0]; porg[1] = o_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0 + org[1]; - porg[2] = o_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0 + org[2]; + porg[2] = o_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0 + org[2]; rnd = rand (); pvel[0] = v_fuzz * ((rnd & 63) - 31.5) / 63.0; pvel[1] = v_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0; - pvel[2] = v_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0; + pvel[2] = v_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0; particle_new (type, texnum, porg, scale, pvel, die, color, alpha, ramp); } diff --git a/libs/video/renderer/glsl/glsl_particles.c b/libs/video/renderer/glsl/glsl_particles.c index 2b2517511..a74e8d2c9 100644 --- a/libs/video/renderer/glsl/glsl_particles.c +++ b/libs/video/renderer/glsl/glsl_particles.c @@ -171,11 +171,11 @@ particle_new_random (ptype_t type, int texnum, const vec3_t org, int org_fuzz, rnd = rand (); porg[0] = o_fuzz * ((rnd & 63) - 31.5) / 63.0 + org[0]; porg[1] = o_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0 + org[1]; - porg[2] = o_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0 + org[2]; + porg[2] = o_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0 + org[2]; rnd = rand (); pvel[0] = v_fuzz * ((rnd & 63) - 31.5) / 63.0; pvel[1] = v_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0; - pvel[2] = v_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0; + pvel[2] = v_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0; particle_new (type, texnum, porg, scale, pvel, die, color, alpha, ramp); } diff --git a/libs/video/renderer/sw/sw_rpart.c b/libs/video/renderer/sw/sw_rpart.c index e4ec19921..708c1181d 100644 --- a/libs/video/renderer/sw/sw_rpart.c +++ b/libs/video/renderer/sw/sw_rpart.c @@ -908,11 +908,11 @@ R_Particle_NewRandom (ptype_t type, int texnum, const vec3_t org, int org_fuzz, rnd = rand (); porg[0] = o_fuzz * ((rnd & 63) - 31.5) / 63.0 + org[0]; porg[1] = o_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0 + org[1]; - porg[2] = o_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0 + org[2]; + porg[2] = o_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0 + org[2]; rnd = rand (); pvel[0] = v_fuzz * ((rnd & 63) - 31.5) / 63.0; pvel[1] = v_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0; - pvel[2] = v_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0; + pvel[2] = v_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0; R_Particle_New (type, texnum, porg, scale, pvel, die, color, alpha, ramp); } diff --git a/libs/video/renderer/sw32/sw32_rpart.c b/libs/video/renderer/sw32/sw32_rpart.c index b64438b4b..4f2829fb2 100644 --- a/libs/video/renderer/sw32/sw32_rpart.c +++ b/libs/video/renderer/sw32/sw32_rpart.c @@ -921,11 +921,11 @@ sw32_R_Particle_NewRandom (ptype_t type, int texnum, const vec3_t org, rnd = rand (); porg[0] = o_fuzz * ((rnd & 63) - 31.5) / 63.0 + org[0]; porg[1] = o_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0 + org[1]; - porg[2] = o_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0 + org[2]; + porg[2] = o_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0 + org[2]; rnd = rand (); pvel[0] = v_fuzz * ((rnd & 63) - 31.5) / 63.0; pvel[1] = v_fuzz * (((rnd >> 5) & 63) - 31.5) / 63.0; - pvel[2] = v_fuzz * (((rnd >> 10) & 63) - 31.5) / 63.0; + pvel[2] = v_fuzz * (((rnd >> 9) & 63) - 31.5) / 63.0; sw32_R_Particle_New (type, texnum, porg, scale, pvel, die, color, alpha, ramp); }