cleanup
This commit is contained in:
parent
d12585b28b
commit
5edc05df89
|
@ -7,9 +7,9 @@ use bevy::transform::TransformSystem;
|
|||
use bevy_xpbd_3d::prelude::*;
|
||||
use crate::{settings, audio, actor};
|
||||
|
||||
pub struct CameraControllerPlugin;
|
||||
pub struct CameraPlugin;
|
||||
|
||||
impl Plugin for CameraControllerPlugin {
|
||||
impl Plugin for CameraPlugin {
|
||||
fn build(&self, app: &mut App) {
|
||||
app.add_systems(Startup, setup_camera);
|
||||
app.add_systems(Update, handle_input);
|
||||
|
@ -22,7 +22,6 @@ impl Plugin for CameraControllerPlugin {
|
|||
app.add_systems(PostUpdate, apply_input_to_player
|
||||
.after(PhysicsSet::Sync)
|
||||
.before(TransformSystem::TransformPropagate));
|
||||
app.insert_resource(ClearColor(Color::rgb(0.0, 0.0, 0.0)));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -34,6 +33,7 @@ pub fn setup_camera(
|
|||
Camera3dBundle {
|
||||
camera: Camera {
|
||||
hdr: true, // HDR is required for bloom
|
||||
clear_color: ClearColorConfig::Custom(Color::BLACK),
|
||||
..default()
|
||||
},
|
||||
tonemapping: Tonemapping::TonyMcMapface,
|
||||
|
|
|
@ -51,7 +51,7 @@ impl Plugin for OutFlyPlugin {
|
|||
FrameTimeDiagnosticsPlugin,
|
||||
|
||||
world::WorldPlugin,
|
||||
camera::CameraControllerPlugin,
|
||||
camera::CameraPlugin,
|
||||
commands::CommandsPlugin,
|
||||
hud::HudPlugin,
|
||||
actor::ActorPlugin,
|
||||
|
|
Loading…
Reference in a new issue