Refactor input handling again, and add more detailed crouching animation.