modified controller a bit