mirror of
https://github.com/eliasstepanik/voxel-simulation.git
synced 2026-01-10 21:38:29 +00:00
Last small fixes
This commit is contained in:
parent
13a0b54364
commit
d93063a8ba
@ -29,7 +29,7 @@ pub fn setup(
|
||||
SphereMeshBuilder::new(radius, SphereKind::Ico { subdivisions: 100 })
|
||||
.build(),
|
||||
);
|
||||
let material_handle = materials.add(StandardMaterial::from(Color::rgb(0.3, 0.6, 1.0)));
|
||||
let material_handle = materials.add(StandardMaterial::from(Color::srgb(0.3, 0.6, 1.0)));
|
||||
|
||||
commands.entity(root.0).with_children(|parent| {
|
||||
parent.spawn((
|
||||
|
||||
@ -30,10 +30,10 @@ pub fn setup(
|
||||
}
|
||||
} else {
|
||||
let mut tree = SparseVoxelOctree::new(octree_depth, octree_base_size, false, false, false);
|
||||
let color = Color::rgb(0.2, 0.8, 0.2);
|
||||
let color = Color::srgb(0.2, 0.8, 0.2);
|
||||
// How many random spheres?
|
||||
/*const NUM_SPHERES: usize = 5;
|
||||
let mut rng = thread_rng();
|
||||
let mut rng = threald_rng();
|
||||
|
||||
for _ in 0..NUM_SPHERES {
|
||||
let center = Vec3::new(
|
||||
|
||||
@ -15,7 +15,7 @@ pub fn visualize_octree_system(
|
||||
gizmos.cuboid(
|
||||
Transform::from_translation(octree_tf.translation)
|
||||
.with_scale(Vec3::splat(octree.size)),
|
||||
Color::rgba(1.0, 1.0, 0.0, 0.15),
|
||||
Color::srgba(1.0, 1.0, 0.0, 0.15),
|
||||
);
|
||||
|
||||
// Recursively draw children:
|
||||
@ -62,7 +62,7 @@ fn visualize_recursive_center(
|
||||
// Draw the child bounding box
|
||||
gizmos.cuboid(
|
||||
Transform::from_translation(child_center).with_scale(Vec3::splat(child_size)),
|
||||
Color::rgba(0.5, 1.0, 0.5, 0.15), // greenish
|
||||
Color::srgba(0.5, 1.0, 0.5, 0.15), // greenish
|
||||
);
|
||||
|
||||
// Recurse
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
use crate::plugins::ui::systems::ui_system::*;
|
||||
use bevy::app::{App, FixedUpdate, Plugin, PreUpdate, Startup};
|
||||
use bevy::prelude::IntoSystemConfigs;
|
||||
|
||||
pub struct UiPlugin;
|
||||
impl Plugin for UiPlugin {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user