seperate rand instances for each thread
[carveJwlIkooP6JGAAIwe30JlM.git] / particle.c
index 13cc5d423c2b364da639e4a06f8d86ed077101a7..d12a87a024e3db67de24a1134810655e884775d2 100644 (file)
@@ -22,7 +22,7 @@ static void particle_spawn_cone( particle_system *sys,
    v3_tangent_basis( dir, tx, ty );
 
    v3f rand;
-   vg_rand_cone( rand, angle );
+   vg_rand_cone( &vg.rand, rand, angle );
    v3_muls(          tx,  rand[0]*speed, p->v );
    v3_muladds( p->v, ty,  rand[1]*speed, p->v );
    v3_muladds( p->v, dir, rand[2]*speed, p->v );