fixed a bug where the player would get stuck in motion upon opening the pause menu