Consolidate imports

main
Elijah Voigt 4 months ago
parent 4460944455
commit 1e9e16931f

@ -3,11 +3,6 @@
mod mono; mod mono;
use bevy::{
asset::LoadedFolder,
color::palettes::css::{DARK_GREY, DARK_ORANGE, GREY, ORANGE, PINK},
window::WindowResized,
};
use games::*; use games::*;
use mono::*; use mono::*;
@ -336,7 +331,9 @@ fn dialog_engine(
debug!("Dialog ended"); debug!("Dialog ended");
// Remove the TreeMonologue component from the tree we just "spoke to" // Remove the TreeMonologue component from the tree we just "spoke to"
commands.entity(tree_entity.unwrap()).remove::<TreeMonologue>(); commands
.entity(tree_entity.unwrap())
.remove::<TreeMonologue>();
// Remove lines from dialog box // Remove lines from dialog box
lines.iter().for_each(|e| { lines.iter().for_each(|e| {
@ -656,13 +653,7 @@ fn spawn_monologue_tree(
let mesh = Mesh3d(meshes.add(Plane3d::new(Vec3::Y, Vec2::splat(1.0)))); let mesh = Mesh3d(meshes.add(Plane3d::new(Vec3::Y, Vec2::splat(1.0))));
commands commands
.spawn(( .spawn((Tree, mesh, material, tree_monologue.clone(), transform))
Tree,
mesh,
material,
tree_monologue.clone(),
transform
))
.observe(delete_tree); .observe(delete_tree);
} }
} }

@ -1,11 +1,3 @@
use bevy::{
asset::{AssetLoader, LoadContext, io::Reader},
prelude::*,
reflect::TypePath,
};
use serde::Deserialize;
use thiserror::Error;
#[derive(Asset, TypePath, Debug, Deserialize, Default, Clone)] #[derive(Asset, TypePath, Debug, Deserialize, Default, Clone)]
pub(crate) struct Monologue { pub(crate) struct Monologue {
value: Vec<Vec<String>>, value: Vec<Vec<String>>,

@ -1,10 +1,3 @@
use bevy::{
color::palettes::css::{GREY, MAGENTA},
gizmos::{aabb::AabbGizmoPlugin, light::LightGizmoPlugin},
pbr::wireframe::{WireframeConfig, WireframePlugin},
platform::collections::HashMap,
};
use super::*; use super::*;
/// Debugging systems, resources, events, etc. /// Debugging systems, resources, events, etc.

@ -11,8 +11,9 @@ mod version;
pub use std::fmt::Display; pub use std::fmt::Display;
pub use bevy::{ pub use bevy::{
asset::LoadState, asset::{AssetLoader, LoadContext, LoadState, LoadedFolder, io::Reader},
color::palettes::css::{BLACK, BLUE, GREEN, RED, WHITE}, color::palettes::css::*,
gizmos::{aabb::AabbGizmoPlugin, light::LightGizmoPlugin},
input::{ input::{
ButtonState, ButtonState,
common_conditions::{input_just_pressed, input_pressed}, common_conditions::{input_just_pressed, input_pressed},
@ -20,9 +21,15 @@ pub use bevy::{
mouse::MouseMotion, mouse::MouseMotion,
mouse::{MouseScrollUnit, MouseWheel}, mouse::{MouseScrollUnit, MouseWheel},
}, },
pbr::wireframe::{WireframeConfig, WireframePlugin},
platform::collections::HashMap,
prelude::*, prelude::*,
reflect::TypePath,
window::WindowResized,
}; };
pub use bevy_rapier3d::prelude::*; pub use bevy_rapier3d::prelude::*;
pub use serde::Deserialize;
pub use thiserror::Error;
pub use base_game::*; pub use base_game::*;
pub use debug::*; pub use debug::*;

Loading…
Cancel
Save