Qualification-Thesis/assets/code/maze-ascension/components.rs

33 lines
668 B
Rust

#[derive(Component, Default)]
pub struct Music;
#[derive(Component, Default)]
pub struct SoundEffect;
#[derive(Component, Debug, Clone, Copy, PartialEq, Eq, Default, Reflect)]
#[reflect(Component)]
pub struct Player;
#[derive(Component, Reflect)]
#[reflect(Component)]
pub struct MovementController {
pub intent: Vec2,
pub max_speed: f32,
}
#[derive(Component, Reflect)]
#[reflect(Component)]
pub struct PlayerAnimation {
timer: Timer,
frame: usize,
state: PlayerAnimationState,
}
#[derive(Component, Debug, Reflect)]
#[reflect(Component)]
pub struct InteractionPalette {
pub none: Color,
pub hovered: Color,
pub pressed: Color,
}