refactor left right movement