Updated state machine diagram