Fixed a state transition bug in MenuState.