bevy_gearbox 0.1.1

State machine system for the bevy game engine
Documentation
1
2
3
4
5
6
7
8
9
10
use bevy::utils::HashSet;

// StateAggregator trait for components that track multiple blocking conditions
pub trait StateAggregator {
    fn add_blocker(&mut self, blocker: &str);
    fn remove_blocker(&mut self, blocker: &str);
    fn is_blocked(&self) -> bool;
    fn is_blocked_by(&self, blocker: &str) -> bool;
    fn get_blockers(&self) -> &HashSet<String>;
}