Initial work on ledge & improved baking of root motion. (#90)
Reviewed-on: #90 Co-authored-by: Álex Román Núñez <eirexe@eirteam.moe>
This commit was merged in pull request #90.
This commit is contained in:
@@ -116,6 +116,7 @@ enum DebugFlag {
|
||||
AttackHitboxes,
|
||||
Hurtboxes,
|
||||
Camera,
|
||||
LedgeGrab,
|
||||
DrawThroughGeometry,
|
||||
FrameStepping,
|
||||
}
|
||||
@@ -164,6 +165,10 @@ const FIGHTER_MENU: &[DebugMenuEntry] = &[
|
||||
label: "Attack hitboxes",
|
||||
flag: DebugFlag::AttackHitboxes,
|
||||
},
|
||||
DebugMenuEntry::Toggle {
|
||||
label: "Ledge grab",
|
||||
flag: DebugFlag::LedgeGrab,
|
||||
},
|
||||
DebugMenuEntry::Toggle {
|
||||
label: "Hurtboxes",
|
||||
flag: DebugFlag::Hurtboxes,
|
||||
@@ -260,6 +265,7 @@ pub struct DebugSettings {
|
||||
pub attack_hitboxes: bool,
|
||||
pub hurtboxes: bool,
|
||||
pub camera: bool,
|
||||
pub ledge_grab: bool,
|
||||
pub draw_through_geometry: bool,
|
||||
pub motion_sampling: PresentationMotionMode,
|
||||
pub game_speed: GameSpeedDebug,
|
||||
@@ -283,6 +289,7 @@ impl Default for DebugSettings {
|
||||
attack_hitboxes: false,
|
||||
hurtboxes: false,
|
||||
camera: false,
|
||||
ledge_grab: false,
|
||||
draw_through_geometry: false,
|
||||
motion_sampling: PresentationMotionMode::default(),
|
||||
game_speed: GameSpeedDebug::Full,
|
||||
@@ -350,6 +357,7 @@ impl DebugSettings {
|
||||
DebugFlag::Hurtboxes => self.hurtboxes,
|
||||
DebugFlag::DrawThroughGeometry => self.draw_through_geometry,
|
||||
DebugFlag::Camera => self.camera,
|
||||
DebugFlag::LedgeGrab => self.ledge_grab,
|
||||
DebugFlag::FrameStepping => self.frame_stepping,
|
||||
}
|
||||
}
|
||||
@@ -368,6 +376,7 @@ impl DebugSettings {
|
||||
self.draw_through_geometry = !self.draw_through_geometry
|
||||
}
|
||||
DebugFlag::Camera => self.camera = !self.camera,
|
||||
DebugFlag::LedgeGrab => self.ledge_grab = !self.ledge_grab,
|
||||
DebugFlag::FrameStepping => self.frame_stepping = !self.frame_stepping,
|
||||
}
|
||||
}
|
||||
@@ -926,6 +935,10 @@ pub fn camera_debug_enabled(settings: Res<DebugSettings>) -> bool {
|
||||
settings.camera
|
||||
}
|
||||
|
||||
pub fn ledge_grab_enabled(settings: Res<DebugSettings>) -> bool {
|
||||
settings.ledge_grab
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
Reference in New Issue
Block a user