1 Commits

Author SHA1 Message Date
Jeremy Overesch
2d3b063df6
Add hierarchical FSM capabilities to the FSM. (#374)
In order to work properly, states with no change need to return ifsm_state::NO_CHANGE rather than their given state id.
Otherwise, when an event isn't handled, it will return the parent state rather than the active state.
Also, in this implementation, a state cannot return a different state during the on_enter_state() function. An assert has been added to check for that.
2021-04-22 08:40:53 +01:00