From 840126ceb3929686a23fbe402aab82455f4ebf2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois?= Date: Sat, 5 Mar 2022 19:30:19 +0100 Subject: [PATCH 1/3] slow down the camera and space out the cubes --- examples/3d/many_cubes.rs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/examples/3d/many_cubes.rs b/examples/3d/many_cubes.rs index 8cd3630d2a5eb..04b0fbceb9ea1 100644 --- a/examples/3d/many_cubes.rs +++ b/examples/3d/many_cubes.rs @@ -32,29 +32,29 @@ fn setup( commands.spawn_bundle(PbrBundle { mesh: mesh.clone_weak(), material: material.clone_weak(), - transform: Transform::from_xyz((x as f32) * 2.0, (y as f32) * 2.0, 0.0), + transform: Transform::from_xyz((x as f32) * 2.5, (y as f32) * 2.5, 0.0), ..default() }); commands.spawn_bundle(PbrBundle { mesh: mesh.clone_weak(), material: material.clone_weak(), transform: Transform::from_xyz( - (x as f32) * 2.0, - HEIGHT as f32 * 2.0, - (y as f32) * 2.0, + (x as f32) * 2.5, + HEIGHT as f32 * 2.5, + (y as f32) * 2.5, ), ..Default::default() }); commands.spawn_bundle(PbrBundle { mesh: mesh.clone_weak(), material: material.clone_weak(), - transform: Transform::from_xyz((x as f32) * 2.0, 0.0, (y as f32) * 2.0), + transform: Transform::from_xyz((x as f32) * 2.5, 0.0, (y as f32) * 2.5), ..Default::default() }); commands.spawn_bundle(PbrBundle { mesh: mesh.clone_weak(), material: material.clone_weak(), - transform: Transform::from_xyz(0.0, (x as f32) * 2.0, (y as f32) * 2.0), + transform: Transform::from_xyz(0.0, (x as f32) * 2.5, (y as f32) * 2.5), ..Default::default() }); } @@ -66,7 +66,7 @@ fn setup( mesh, material, transform: Transform { - translation: Vec3::new(0.0, HEIGHT as f32 * 2.0, 0.0), + translation: Vec3::new(0.0, HEIGHT as f32 * 2.5, 0.0), scale: Vec3::splat(5.0), ..Default::default() }, @@ -87,8 +87,8 @@ fn setup( // System for rotating the camera fn move_camera(time: Res