StateMachine constructor Null safety

StateMachine()