Removed Old code from MainState