From 5bba4f019e943f002fb28aa858aea1e51a043134 Mon Sep 17 00:00:00 2001 From: Zynh0722 Date: Sat, 17 Feb 2024 02:15:33 -0800 Subject: [PATCH] comments --- src/main.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 953454e..78575de 100644 --- a/src/main.rs +++ b/src/main.rs @@ -33,8 +33,9 @@ fn random_vec(_app: &App) -> nalgebra::Vector2 { } fn fill_particles(app: &App, colliders: &mut ColliderSet, bodies: &mut RigidBodySet) { + // Keeping track of already placed balls to avoid overlap + // Need to look into a way to do this with rapier directly let mut positions: Vec> = Vec::new(); - for _ in 0..PARTICLE_COUNT { let mut xy = random_vec(app); while !positions