From 66e48ac3fbb921188a45a93282d999a169789898 Mon Sep 17 00:00:00 2001 From: Manuel Brea Date: Wed, 14 Feb 2024 16:12:55 +0000 Subject: [PATCH] Fixed reflection for flip configuration types --- crates/bevy_animation_graph/src/flipping/config.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/crates/bevy_animation_graph/src/flipping/config.rs b/crates/bevy_animation_graph/src/flipping/config.rs index 14e391a..8e29900 100644 --- a/crates/bevy_animation_graph/src/flipping/config.rs +++ b/crates/bevy_animation_graph/src/flipping/config.rs @@ -1,13 +1,15 @@ -use bevy::reflect::Reflect; +use bevy::reflect::{std_traits::ReflectDefault, Reflect}; use regex::{escape, Regex}; use serde::{Deserialize, Serialize}; #[derive(Debug, Default, Reflect, Clone, Serialize, Deserialize)] +#[reflect(Default)] pub struct FlipConfig { pub name_mapper: FlipNameMapper, } #[derive(Debug, Reflect, Clone)] +#[reflect(Default)] pub struct PatternMapper { key_1: String, key_2: String, @@ -118,6 +120,7 @@ impl Default for PatternMapperSerial { } #[derive(Debug, Reflect, Clone, Serialize, Deserialize)] +#[reflect(Default)] pub enum FlipNameMapper { Pattern(PatternMapper), }