diff --git a/Design.md b/Design.md index 8188716..b33e27f 100644 --- a/Design.md +++ b/Design.md @@ -23,12 +23,17 @@ Multiplayer - [x] Snap back leaning too quick - [x] Issue with moving around quickly - [x] Bring Crouching back -- [ ] Inspect animation (procedural) +- [x] Inspect animation & state (procedural) + - [ ] Attachment editor system when in inspect mode +- [x] High Ready & Low Ready system with state + - [x] High ready animation (procedural) + - [x] Low ready animation (procedural) - [ ] Reload animation (procedural) - [ ] Real world magazines - [ ] Rewriting bullet physics to use raycasts & kinematic rigidbodies (logic controlled) - [ ] Low Ready & High ready (low ready == more speed | high ready == more accuracy) - [ ] Auto Low ready when gun collider hits object OR when player starts sprinting +- [ ] Create a Controls struct that holds mappings to all the game keys and replace them in all the game's code # Design diff --git a/assets/character/main_character.glb b/assets/character/main_character.glb index 986337b..50445ed 100644 Binary files a/assets/character/main_character.glb and b/assets/character/main_character.glb differ diff --git a/src/comps/core/controller.rs b/src/comps/core/controller.rs index e36e066..fd6656f 100644 --- a/src/comps/core/controller.rs +++ b/src/comps/core/controller.rs @@ -2,12 +2,12 @@ use bevy::prelude::*; use bevy_rapier3d::prelude::*; use crate::{ - logic::core::player::{ + logic::core::{player::{ player_movement::{ move_player, PlayerLinearXZState, PlayerLinearYState, PlayerMovementInput, }, player_values_state::PlayerValuesState, - }, + }, guns::player_firing::PlayerFiringInfo}, ui::game::game_ui_state::GameUiState, }; @@ -24,6 +24,7 @@ pub fn capture_input( &mut PlayerLinearXZState, &mut Transform, &mut Damping, + &mut PlayerFiringInfo, ), With, >, diff --git a/src/logic/core/guns/inspect.rs b/src/logic/core/guns/inspect.rs new file mode 100644 index 0000000..b5656ad --- /dev/null +++ b/src/logic/core/guns/inspect.rs @@ -0,0 +1,31 @@ +use bevy::prelude::*; + +use crate::comps::core::markers::{proxy::{character::in_player_hands_parent::InPlayerHandsParent, physics::utils::TransformExt}, player::Player}; + +use super::player_firing::PlayerFiringInfo; + + + +pub fn inspect_firearm( + //mut commands: Commands, + mut in_player_hands_parent_query: Query<&mut Transform, With>, + mut player_firing_info_query: Query<&mut PlayerFiringInfo, With>, + time: Res