separated WASD movement cases into different functions