base states logic finished

need add some logic into menu state