Added start of basic menu, implemented tommy's memory leak fixes.