Added basic menu state

and replaced deadloop with menuloop