Horizontal and vertical movement functioning correctly