Code cleanup

Made the main menu code much cleaner.
Cleanup