The pawn moves aslant instead of straight

Hello there! I am working with a pawn movement, and my pawn moves aslant. I created some functions for A and D keys to have some key input. I have been trying to fix this problem, but have no thoughts how to fix it. Here is how it moves.