Implemented moving state and improved main loop