fixed bug in vertical movement

x was being reset when no horizontal movement was happening, but y wasnt