Action functions take event instance, introduced Initial event
Ported old StateMachine test to HSM; added resulting_state

eventbus is bad, popping events from queue logic is wrong